This example shows how to use the Aggregation pipeline with material casting.