Blender Git Loki
Git Commits -> Revision 506e8aa
Revision 506e8aa by Janne Karhu (master) February 28, 2011, 15:42 (GMT) |
Bug fix: Render and 3d view conflict over ob->imat * For rendering every object's inverse matrix "ob->imat" needs to be in render view coordinates, but for drawing in 3d view it needs to be in global coordinates. Originally (way back in historical times) ob->imat was only used for rendering, but over the years other uses came up too. Before 2.5 this wasn't a problem as rendering was a totally blocking operation, but with the new "interactive ui while rendering" the problems started. Basically any update that redrew the 3d view while rendering (like rotating the scene with mouse) updated the inverse matrix into global coordinates thus invalidating it for the render, leading to all kinds of strange discontinuities with textures and volumetrics. * Problems were very easy to achieve using orco/object coordinates for pretty much any textures (bump, point density, volume, sky), for examples see bug reports 24906 and 25229. Render baking normals in object coordinates was wrong most of the time too. * Now there is a separate inverse matrix ob->imat_ren that's calculated at the beginning of rendering and is used in all places inside render code where it's needed. This way the original ob->imat can change at will during rendering without causing problems. |
Commit Details:
Full Hash: 506e8aa43786f80c60979fb53ba38288cfe193ad
SVN Revision: 35266
Parent Commit: 13b617c
Lines Changed: +26, -38
5 Modified Paths:
/source/blender/makesdna/DNA_object_types.h (+7, -1) (Diff)
/source/blender/render/intern/source/convertblender.c (+3, -13) (Diff)
/source/blender/render/intern/source/rendercore.c (+1, -1) (Diff)
/source/blender/render/intern/source/renderdatabase.c (+2, -10) (Diff)
/source/blender/render/intern/source/render_texture.c (+13, -13) (Diff)
/source/blender/render/intern/source/convertblender.c (+3, -13) (Diff)
/source/blender/render/intern/source/rendercore.c (+1, -1) (Diff)
/source/blender/render/intern/source/renderdatabase.c (+2, -10) (Diff)
/source/blender/render/intern/source/render_texture.c (+13, -13) (Diff)