Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(514)

Issue 10096043: Multiview Branch

Can't Edit
Can't Publish+Mail
Start Review
Created:
10 years, 11 months ago by dfelinto
Modified:
10 years, 11 months ago
Reviewers:
bf-codereview
Base URL:
https://svn.blender.org/svnroot/bf-blender/trunk/blender/
Visibility:
Public.

Description

Multiview Code Review ================= This feature touches mainly the following areas of Blender: (0) scene (1) render (2) cycles (3) compositing (4) window manager (5) image editor (6) viewport (7) saving (8) sequencer Official repo: https://github.com/dfelinto/blender/tree/multiview (with images) Repo mirrored: https://svn.blender.org/svnroot/bf-blender/branches/multiview/ Official issues list: https://github.com/dfelinto/blender/issues?state=open [0] Scene ======= A new panel (currently as a panel on its own, though this is negotiable) allows you to select views to use for rendering a scene. For new scenes and old files, two views are created: Left and Right. They are both deactivated, so things-should-work-as-before™. They also have the option “Name as Label” disabled by default, and the default labels: “_L” and “_R” respectively. See how this is used in [7] Saving. [1] Render ======== If there is no view active in the “Render Views” panel, Blender will render the scene camera, just like before. If there is even one active view, pipeline.c will loop over the views, setting the current view in Render->actview, which is used by RE_GetViewCamera to return the correct camera. * RenderLayer->rr no longer exists (now every renderlayer has a combined pass per view) * RenderResult->rectf / rectz / rect32 still exist to temporarily store the output from RE_AcquireResultImage. But the data is now stored in RenderView->rectf / rectz / rect32. * RenderResult->views stores the views names and buffers (rectf, rectz, rect32), not but the render passes. * RenderPass is used just like before, but we will have Combined.left.R, UV.center.U, ... [2] Cycles ======= Cycles first finishes a view entirely, and then go to the next one. The new loop is in: blender_session.cpp:: void BlenderSession::render() ** Not Implemented: ** It would be nice to have it done in parallel, so when in Rendered mode and with 3-D turned for the window, you can preview the result in 3-D. This could also benefit when you do the final render and see in Image Editor. [3] Compositor =========== In the compositor the current scene is the queen. Just like the compositor output size is capped to the current scene output settings, the number of views to render comes from the current scene. Image Node: If the image has more than one view, we have a drop-down where you can pick the current view. An option “All” makes the view to automatically match the current rendered view. View Switch Node: This node will reflect the active Render Views for the current scene. ** Not Implemented: ** View Node: Unfortunately the view node is still not 3-D friendly. It has to do with the way its data is (not) stored. It’s probably doable, but I haven’t tackled it yet. [4] Window Manager =============== Window manager provides support for 3-D displays when the drawing mode is Triple Buffer. The mode is set per user, but the enable/disable capability is per window (shortcut “D”) at the moment. See the changes on wm_draw.c::wm_draw_update(), the new wm_draw.c::wm_method_draw_triple_stereo() and the new file wm_stereo.c for more details. [5] Image Editor =========== If the image has more than one view a new dropdown button allows the user to pick the view to see. If the image (or render) has a “left” and a “right” views an extra view “3-D” is offered. Because the passes list has one pass of each kind for each view, the interface will show only one of each, and the user is actually selecting the pass type (actually actually it’s selecting the id of the first pass of a given kind, but I could change that to store the pass type instead). image_buttons.c::get_pass_id(), pass_menu() and view_menu() I’m tempted to change that to recalculate the pass multi_index in image_draw.c::draw_image_main() That would also fix a bug I have now that I have to manually select a view after turning 3-D on and opening an image in some cases (otherwise the passes are not initialized). [6] Viewport ========= View3D.eye (set in windows manager [4]) is used to pick which camera to use. Only works when 3-D is enabled for the window. ** Not Implemented: ** * OpenGL Render [7] Saving ======= There is a new format “OpenEXR Multiview”, which will save the file as EXR 2.0 Multipart file, one view per part. If any other format is chosen, Blender will save each view as an individual file. There is a new char “%” used to specify where you want the view name to be in the filepath: e.g., Render_%_Test.jpg will produce Render_myviewname_Test.jpg. If there is no “%” the view name will be placed in the end: e.g., RenderTest.jpg → RenderTest_L.jpg | RenderTest_R.jpg There is an option to replace the view name by a label for the file output. This way the scene view name doesn’t have to be used in the filename. ** Not Implemented: ** Currently there is no option to save side-by-side, top-bottom, anaglyph, ... [8] Sequencer ========== ** Not Implemented: ** EVERYTHING. There is a Google Summer of code on Sequencer refactoring, so it may make more sense to skip Sequencer support for now, and handle that with Alex in his GSoC. The design can be discussed here: https://github.com/dfelinto/blender/issues/30 [9] Have fun reviewing ============== Thanks for Francesco Siddi for collaborating with the original proposal and tests. Thanks for Alexey Akishin for contributing with code for the 3-D display functionality. Thanks for Ton Roosendaal, Brecht van Lommel, Jeroen Bakker and Sergey Sharybin for helping with code discussion and design decisions. Thanks for Blender users and devs for all the feedback and testing. Feel free to send pull request to the github branch. Binary files that mat not be in the patch: release/datafiles/blender_icons32.png release/datafiles/blender_icons16.png (though you can find them in svn or github repository)

Patch Set 1 #

Patch Set 2 : Fix for windows (+ image editor revert over cleanup) #

Unified diffs Side-by-side diffs Delta from patch set Stats (+6232 lines, -1004 lines) Patch
intern/cycles/blender/addon/ui.py View 1 chunk +2 lines, -0 lines 0 comments Download
intern/cycles/blender/blender_session.h View 1 chunk +1 line, -0 lines 0 comments Download
intern/cycles/blender/blender_session.cpp View 7 chunks +67 lines, -55 lines 0 comments Download
release/datafiles/blender_icons.svg View 3 chunks +937 lines, -0 lines 0 comments Download
release/datafiles/blender_icons16.png View 0 chunks +-1 lines, --1 lines 0 comments Download
release/datafiles/blender_icons32.png View 0 chunks +-1 lines, --1 lines 0 comments Download
release/scripts/startup/bl_ui/__init__.py View 1 chunk +1 line, -0 lines 0 comments Download
release/scripts/startup/bl_ui/properties_render_view.py View 1 chunk +100 lines, -0 lines 0 comments Download
release/scripts/startup/bl_ui/space_userpref.py View 1 chunk +19 lines, -0 lines 0 comments Download
release/scripts/startup/nodeitems_builtins.py View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/blenkernel/BKE_image.h View 2 chunks +5 lines, -2 lines 0 comments Download
source/blender/blenkernel/BKE_node.h View 2 chunks +3 lines, -1 line 0 comments Download
source/blender/blenkernel/BKE_scene.h View 1 chunk +3 lines, -0 lines 0 comments Download
source/blender/blenkernel/intern/image.c View 13 chunks +32 lines, -22 lines 0 comments Download
source/blender/blenkernel/intern/node.c View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/blenkernel/intern/ocean.c View 1 chunk +1 line, -1 line 0 comments Download
source/blender/blenkernel/intern/scene.c View 6 chunks +62 lines, -4 lines 0 comments Download
source/blender/blenkernel/intern/sequencer.c View 1 chunk +2 lines, -1 line 0 comments Download
source/blender/blenlib/BLI_path_util.h View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/blenlib/intern/path_util.c View 2 chunks +128 lines, -0 lines 0 comments Download
source/blender/blenloader/intern/readfile.c View 8 chunks +35 lines, -0 lines 0 comments Download
source/blender/blenloader/intern/writefile.c View 2 chunks +5 lines, -0 lines 0 comments Download
source/blender/compositor/CMakeLists.txt View 2 chunks +4 lines, -0 lines 0 comments Download
source/blender/compositor/COM_compositor.h View 1 chunk +1 line, -1 line 0 comments Download
source/blender/compositor/intern/COM_CompositorContext.h View 2 chunks +19 lines, -1 line 0 comments Download
source/blender/compositor/intern/COM_Converter.cpp View 2 chunks +4 lines, -0 lines 0 comments Download
source/blender/compositor/intern/COM_ExecutionSystem.h View 1 chunk +2 lines, -1 line 0 comments Download
source/blender/compositor/intern/COM_ExecutionSystem.cpp View 1 chunk +3 lines, -1 line 0 comments Download
source/blender/compositor/intern/COM_Node.h View 1 chunk +2 lines, -0 lines 0 comments Download
source/blender/compositor/intern/COM_Node.cpp View 1 chunk +19 lines, -0 lines 0 comments Download
source/blender/compositor/intern/COM_compositor.cpp View 3 chunks +6 lines, -3 lines 0 comments Download
source/blender/compositor/nodes/COM_CompositorNode.cpp View 1 chunk +1 line, -1 line 0 comments Download
source/blender/compositor/nodes/COM_ImageNode.h View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/compositor/nodes/COM_ImageNode.cpp View 2 chunks +38 lines, -2 lines 0 comments Download
source/blender/compositor/nodes/COM_OutputFileNode.cpp View 3 chunks +14 lines, -5 lines 0 comments Download
source/blender/compositor/nodes/COM_RenderLayersNode.cpp View 1 chunk +5 lines, -0 lines 0 comments Download
source/blender/compositor/nodes/COM_SwitchViewNode.h View 1 chunk +37 lines, -0 lines 0 comments Download
source/blender/compositor/nodes/COM_SwitchViewNode.cpp View 1 chunk +55 lines, -0 lines 0 comments Download
source/blender/compositor/operations/COM_CompositorOperation.h View 1 chunk +6 lines, -1 line 0 comments Download
source/blender/compositor/operations/COM_CompositorOperation.cpp View 3 chunks +11 lines, -7 lines 0 comments Download
source/blender/compositor/operations/COM_OutputFileMultiViewOperation.h View 1 chunk +46 lines, -0 lines 0 comments Download
source/blender/compositor/operations/COM_OutputFileMultiViewOperation.cpp View 1 chunk +204 lines, -0 lines 0 comments Download
source/blender/compositor/operations/COM_OutputFileOperation.h View 3 chunks +8 lines, -3 lines 0 comments Download
source/blender/compositor/operations/COM_OutputFileOperation.cpp View 7 chunks +47 lines, -12 lines 0 comments Download
source/blender/compositor/operations/COM_RenderLayersBaseProg.h View 2 chunks +8 lines, -1 line 0 comments Download
source/blender/compositor/operations/COM_RenderLayersBaseProg.cpp View 3 chunks +4 lines, -7 lines 0 comments Download
source/blender/editors/include/ED_screen.h View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/editors/include/UI_icons.h View 1 chunk +1 line, -3 lines 0 comments Download
source/blender/editors/interface/interface_ops.c View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/editors/render/render_intern.h View 2 chunks +4 lines, -1 line 0 comments Download
source/blender/editors/render/render_internal.c View 8 chunks +35 lines, -18 lines 0 comments Download
source/blender/editors/render/render_opengl.c View 2 chunks +2 lines, -2 lines 0 comments Download
source/blender/editors/render/render_ops.c View 1 chunk +3 lines, -0 lines 0 comments Download
source/blender/editors/render/render_preview.c View 1 chunk +2 lines, -1 line 0 comments Download
source/blender/editors/render/render_shading.c View 1 chunk +64 lines, -0 lines 0 comments Download
source/blender/editors/screen/area.c View 4 chunks +10 lines, -8 lines 0 comments Download
source/blender/editors/screen/screen_edit.c View 3 chunks +97 lines, -3 lines 0 comments Download
source/blender/editors/screen/screen_ops.c View 3 chunks +39 lines, -1 line 0 comments Download
source/blender/editors/screen/screendump.c View 1 chunk +1 line, -1 line 0 comments Download
source/blender/editors/space_buttons/buttons_context.c View 2 chunks +2 lines, -1 line 0 comments Download
source/blender/editors/space_buttons/buttons_header.c View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/editors/space_buttons/space_buttons.c View 2 chunks +3 lines, -0 lines 0 comments Download
source/blender/editors/space_image/image_buttons.c View 8 chunks +155 lines, -19 lines 0 comments Download
source/blender/editors/space_image/image_draw.c View 1 1 chunk +13 lines, -0 lines 0 comments Download
source/blender/editors/space_image/image_ops.c View 2 chunks +182 lines, -51 lines 0 comments Download
source/blender/editors/space_node/drawnode.c View 8 chunks +40 lines, -4 lines 0 comments Download
source/blender/editors/space_node/node_edit.c View 2 chunks +51 lines, -1 line 0 comments Download
source/blender/editors/space_node/node_intern.h View 1 chunk +2 lines, -0 lines 0 comments Download
source/blender/editors/space_node/node_ops.c View 1 chunk +2 lines, -0 lines 0 comments Download
source/blender/editors/space_view3d/view3d_draw.c View 2 chunks +43 lines, -0 lines 0 comments Download
source/blender/freestyle/intern/blender_interface/FRS_freestyle.cpp View 2 chunks +5 lines, -4 lines 0 comments Download
source/blender/imbuf/IMB_imbuf_types.h View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/imbuf/intern/openexr/openexr_api.cpp View 1 27 chunks +600 lines, -97 lines 0 comments Download
source/blender/imbuf/intern/openexr/openexr_multi.h View 2 chunks +17 lines, -5 lines 0 comments Download
source/blender/imbuf/intern/openexr/openexr_stub.cpp View 1 chunk +9 lines, -3 lines 0 comments Download
source/blender/imbuf/intern/thumbs.c View 1 chunk +1 line, -1 line 0 comments Download
source/blender/makesdna/DNA_image_types.h View 2 chunks +9 lines, -4 lines 0 comments Download
source/blender/makesdna/DNA_node_types.h View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/makesdna/DNA_scene_types.h View 5 chunks +34 lines, -0 lines 0 comments Download
source/blender/makesdna/DNA_screen_types.h View 4 chunks +7 lines, -1 line 0 comments Download
source/blender/makesdna/DNA_space_types.h View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/makesdna/DNA_userdef_types.h View 2 chunks +40 lines, -1 line 0 comments Download
source/blender/makesdna/DNA_view3d_types.h View 1 chunk +3 lines, -1 line 0 comments Download
source/blender/makesdna/DNA_windowmanager_types.h View 3 chunks +9 lines, -2 lines 0 comments Download
source/blender/makesrna/RNA_access.h View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/makesrna/intern/rna_image.c View 1 chunk +5 lines, -0 lines 0 comments Download
source/blender/makesrna/intern/rna_nodetree.c View 1 4 chunks +116 lines, -0 lines 0 comments Download
source/blender/makesrna/intern/rna_render.c View 8 chunks +46 lines, -2 lines 0 comments Download
source/blender/makesrna/intern/rna_scene.c View 9 chunks +185 lines, -5 lines 0 comments Download
source/blender/makesrna/intern/rna_scene_api.c View 2 chunks +4 lines, -2 lines 0 comments Download
source/blender/makesrna/intern/rna_space.c View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/makesrna/intern/rna_userdef.c View 2 chunks +58 lines, -0 lines 0 comments Download
source/blender/nodes/CMakeLists.txt View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/nodes/NOD_composite.h View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/nodes/NOD_static_types.h View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/nodes/composite/node_composite_tree.c View 1 chunk +4 lines, -3 lines 0 comments Download
source/blender/nodes/composite/nodes/node_composite_image.c View 1 chunk +9 lines, -2 lines 0 comments Download
source/blender/nodes/composite/nodes/node_composite_outputFile.c View 2 chunks +2 lines, -2 lines 0 comments Download
source/blender/nodes/composite/nodes/node_composite_switchview.c View 1 chunk +145 lines, -0 lines 0 comments Download
source/blender/render/extern/include/RE_engine.h View 1 chunk +3 lines, -1 line 0 comments Download
source/blender/render/extern/include/RE_pipeline.h View 12 chunks +52 lines, -9 lines 0 comments Download
source/blender/render/intern/include/render_result.h View 3 chunks +7 lines, -3 lines 0 comments Download
source/blender/render/intern/include/render_types.h View 2 chunks +3 lines, -1 line 0 comments Download
source/blender/render/intern/source/convertblender.c View 4 chunks +4 lines, -4 lines 0 comments Download
source/blender/render/intern/source/envmap.c View 1 chunk +4 lines, -2 lines 0 comments Download
source/blender/render/intern/source/external_engine.c View 6 chunks +12 lines, -6 lines 0 comments Download
source/blender/render/intern/source/initrender.c View 1 chunk +13 lines, -0 lines 0 comments Download
source/blender/render/intern/source/pipeline.c View 52 chunks +648 lines, -203 lines 0 comments Download
source/blender/render/intern/source/render_result.c View 23 chunks +558 lines, -314 lines 0 comments Download
source/blender/render/intern/source/rendercore.c View 28 chunks +77 lines, -40 lines 0 comments Download
source/blender/render/intern/source/zbuf.c View 3 chunks +9 lines, -6 lines 0 comments Download
source/blender/windowmanager/CMakeLists.txt View 2 chunks +2 lines, -0 lines 0 comments Download
source/blender/windowmanager/intern/wm_draw.c View 21 chunks +256 lines, -31 lines 0 comments Download
source/blender/windowmanager/intern/wm_operators.c View 6 chunks +20 lines, -1 line 0 comments Download
source/blender/windowmanager/intern/wm_stereo.c View 1 chunk +444 lines, -0 lines 0 comments Download
source/blender/windowmanager/intern/wm_subwindow.c View 1 chunk +1 line, -0 lines 0 comments Download
source/blender/windowmanager/intern/wm_window.c View 6 chunks +22 lines, -2 lines 0 comments Download
source/blender/windowmanager/wm.h View 1 chunk +3 lines, -0 lines 0 comments Download
source/blender/windowmanager/wm_draw.h View 2 chunks +14 lines, -0 lines 0 comments Download
source/blender/windowmanager/wm_stereo.h View 1 chunk +43 lines, -0 lines 0 comments Download
source/blenderplayer/bad_level_call_stubs/stubs.c View 1 chunk +6 lines, -0 lines 0 comments Download
source/creator/creator.c View 2 chunks +12 lines, -2 lines 0 comments Download

Messages

Total messages: 2
dfelinto
10 years, 11 months ago (2013-06-06 19:43:22 UTC) #1
dfelinto
10 years, 11 months ago (2013-06-07 08:07:12 UTC) #2
Fix for windows (+ image editor revert over cleanup)
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b