Fix #31168: cycles mask layer should only affect objects for camera rays.

Fix: texture coordinate normal output was not correct, still changed under
object transform.
This commit is contained in:
Brecht Van Lommel
2012-05-02 09:33:45 +00:00
parent 5d4fd04f05
commit 1e2afcddd3
16 changed files with 99 additions and 55 deletions

View File

@@ -149,6 +149,7 @@ void Camera::device_update(Device *device, DeviceScene *dscene, Scene *scene)
/* camera motion */
Scene::MotionType need_motion = scene->need_motion();
kcam->have_motion = 0;
if(need_motion == Scene::MOTION_PASS) {
if(use_motion) {
@@ -162,7 +163,10 @@ void Camera::device_update(Device *device, DeviceScene *dscene, Scene *scene)
}
else if(need_motion == Scene::MOTION_BLUR) {
/* todo: exact camera position will not be hit this way */
transform_motion_decompose(&kcam->motion, &motion);
if(use_motion) {
transform_motion_decompose(&kcam->motion, &motion);
kcam->have_motion = 1;
}
}
/* depth of field */