Applying camera and layer matrices