Merge branch 'master' into soc-2020-io-performance
This commit is contained in:
@@ -30,7 +30,7 @@ if(${CMAKE_SOURCE_DIR} STREQUAL ${CMAKE_BINARY_DIR})
|
||||
"CMake generation for blender is not allowed within the source directory!"
|
||||
"\n Remove \"${CMAKE_SOURCE_DIR}/CMakeCache.txt\" and try again from another folder, e.g.:"
|
||||
"\n "
|
||||
"\n rm CMakeCache.txt"
|
||||
"\n rm -rf CMakeCache.txt CMakeFiles"
|
||||
"\n cd .."
|
||||
"\n mkdir cmake-make"
|
||||
"\n cd cmake-make"
|
||||
@@ -160,8 +160,7 @@ if(APPLE)
|
||||
# Currently this causes a build error linking, disable.
|
||||
set(WITH_BLENDER_THUMBNAILER OFF)
|
||||
elseif(WIN32)
|
||||
# Building the thumbnail extraction DLL could be made optional.
|
||||
set(WITH_BLENDER_THUMBNAILER ON)
|
||||
option(WITH_BLENDER_THUMBNAILER "Build \"BlendThumb.dll\" helper for Windows explorer integration" ON)
|
||||
else()
|
||||
option(WITH_BLENDER_THUMBNAILER "Build \"blender-thumbnailer\" thumbnail extraction utility" ON)
|
||||
endif()
|
||||
|
||||
@@ -116,6 +116,9 @@ if NOT "%1" == "" (
|
||||
) else if "%1" == "doc_py" (
|
||||
set DOC_PY=1
|
||||
goto EOF
|
||||
) else if "%1" == "svnfix" (
|
||||
set SVN_FIX=1
|
||||
goto EOF
|
||||
) else (
|
||||
echo Command "%1" unknown, aborting!
|
||||
goto ERR
|
||||
|
||||
26
build_files/windows/svn_fix.cmd
Normal file
26
build_files/windows/svn_fix.cmd
Normal file
@@ -0,0 +1,26 @@
|
||||
if "%BUILD_VS_YEAR%"=="2017" set BUILD_VS_LIBDIRPOST=vc15
|
||||
if "%BUILD_VS_YEAR%"=="2019" set BUILD_VS_LIBDIRPOST=vc15
|
||||
if "%BUILD_VS_YEAR%"=="2022" set BUILD_VS_LIBDIRPOST=vc15
|
||||
|
||||
set BUILD_VS_SVNDIR=win64_%BUILD_VS_LIBDIRPOST%
|
||||
set BUILD_VS_LIBDIR="%BLENDER_DIR%..\lib\%BUILD_VS_SVNDIR%"
|
||||
|
||||
echo Starting cleanup in %BUILD_VS_LIBDIR%.
|
||||
cd %BUILD_VS_LIBDIR%
|
||||
:RETRY
|
||||
"%SVN%" cleanup
|
||||
"%SVN%" update
|
||||
if errorlevel 1 (
|
||||
set /p LibRetry= "Error during update, retry? y/n"
|
||||
if /I "!LibRetry!"=="Y" (
|
||||
goto RETRY
|
||||
)
|
||||
echo.
|
||||
echo Error: Download of external libraries failed.
|
||||
echo This is needed for building, please manually run 'svn cleanup' and 'svn update' in
|
||||
echo %BUILD_VS_LIBDIR% , until this is resolved you CANNOT make a successful blender build
|
||||
echo.
|
||||
exit /b 1
|
||||
)
|
||||
echo Cleanup complete
|
||||
|
||||
@@ -38,7 +38,7 @@ PROJECT_NAME = Blender
|
||||
# could be handy for archiving the generated documentation or if some version
|
||||
# control system is used.
|
||||
|
||||
PROJECT_NUMBER = V3.0
|
||||
PROJECT_NUMBER = V3.1
|
||||
|
||||
# Using the PROJECT_BRIEF tag one can provide an optional one line description
|
||||
# for a project that appears at the top of each page and should give viewer a
|
||||
|
||||
@@ -1108,7 +1108,9 @@ context_type_map = {
|
||||
"selected_editable_keyframes": ("Keyframe", True),
|
||||
"selected_editable_objects": ("Object", True),
|
||||
"selected_editable_sequences": ("Sequence", True),
|
||||
"selected_ids": ("ID", True),
|
||||
"selected_files": ("FileSelectEntry", True),
|
||||
"selected_ids": ("ID", True),
|
||||
"selected_nla_strips": ("NlaStrip", True),
|
||||
"selected_movieclip_tracks": ("MovieTrackingTrack", True),
|
||||
"selected_nodes": ("Node", True),
|
||||
@@ -1222,7 +1224,10 @@ def pycontext2sphinx(basepath):
|
||||
while char_array[i] is not None:
|
||||
member = ctypes.string_at(char_array[i]).decode(encoding="ascii")
|
||||
fw(".. data:: %s\n\n" % member)
|
||||
member_type, is_seq = context_type_map[member]
|
||||
try:
|
||||
member_type, is_seq = context_type_map[member]
|
||||
except KeyError:
|
||||
raise SystemExit("Error: context key %r not found in context_type_map; update %s" % (member, __file__)) from None
|
||||
fw(" :type: %s :class:`bpy.types.%s`\n\n" % ("sequence of " if is_seq else "", member_type))
|
||||
unique.add(member)
|
||||
i += 1
|
||||
|
||||
@@ -295,13 +295,6 @@ if(WITH_OPENIMAGEDENOISE)
|
||||
)
|
||||
endif()
|
||||
|
||||
if(WITH_CYCLES_STANDALONE)
|
||||
set(WITH_CYCLES_DEVICE_CUDA TRUE)
|
||||
set(WITH_CYCLES_DEVICE_HIP TRUE)
|
||||
endif()
|
||||
# TODO(sergey): Consider removing it, only causes confusion in interface.
|
||||
set(WITH_CYCLES_DEVICE_MULTI TRUE)
|
||||
|
||||
# Logging capabilities using GLog library.
|
||||
if(WITH_CYCLES_LOGGING)
|
||||
add_definitions(-DWITH_CYCLES_LOGGING)
|
||||
@@ -400,7 +393,8 @@ add_subdirectory(doc)
|
||||
add_subdirectory(graph)
|
||||
add_subdirectory(integrator)
|
||||
add_subdirectory(kernel)
|
||||
add_subdirectory(render)
|
||||
add_subdirectory(scene)
|
||||
add_subdirectory(session)
|
||||
add_subdirectory(subd)
|
||||
add_subdirectory(util)
|
||||
|
||||
|
||||
@@ -25,7 +25,8 @@ set(INC_SYS
|
||||
set(LIBRARIES
|
||||
cycles_device
|
||||
cycles_kernel
|
||||
cycles_render
|
||||
cycles_scene
|
||||
cycles_session
|
||||
cycles_bvh
|
||||
cycles_subd
|
||||
cycles_graph
|
||||
|
||||
@@ -18,13 +18,13 @@
|
||||
|
||||
#include "device/device.h"
|
||||
|
||||
#include "util/util_args.h"
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/util_path.h"
|
||||
#include "util/util_stats.h"
|
||||
#include "util/util_string.h"
|
||||
#include "util/util_task.h"
|
||||
#include "util/args.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/log.h"
|
||||
#include "util/path.h"
|
||||
#include "util/stats.h"
|
||||
#include "util/string.h"
|
||||
#include "util/task.h"
|
||||
|
||||
using namespace ccl;
|
||||
|
||||
|
||||
@@ -17,30 +17,30 @@
|
||||
#include <stdio.h>
|
||||
|
||||
#include "device/device.h"
|
||||
#include "render/buffers.h"
|
||||
#include "render/camera.h"
|
||||
#include "render/integrator.h"
|
||||
#include "render/scene.h"
|
||||
#include "render/session.h"
|
||||
#include "scene/camera.h"
|
||||
#include "scene/integrator.h"
|
||||
#include "scene/scene.h"
|
||||
#include "session/buffers.h"
|
||||
#include "session/session.h"
|
||||
|
||||
#include "util/util_args.h"
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_function.h"
|
||||
#include "util/util_image.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/util_path.h"
|
||||
#include "util/util_progress.h"
|
||||
#include "util/util_string.h"
|
||||
#include "util/util_time.h"
|
||||
#include "util/util_transform.h"
|
||||
#include "util/util_unique_ptr.h"
|
||||
#include "util/util_version.h"
|
||||
#include "util/args.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/function.h"
|
||||
#include "util/image.h"
|
||||
#include "util/log.h"
|
||||
#include "util/path.h"
|
||||
#include "util/progress.h"
|
||||
#include "util/string.h"
|
||||
#include "util/time.h"
|
||||
#include "util/transform.h"
|
||||
#include "util/unique_ptr.h"
|
||||
#include "util/version.h"
|
||||
|
||||
#include "app/cycles_xml.h"
|
||||
#include "app/oiio_output_driver.h"
|
||||
|
||||
#ifdef WITH_CYCLES_STANDALONE_GUI
|
||||
# include "util/util_view.h"
|
||||
# include "util/view.h"
|
||||
#endif
|
||||
|
||||
#include "app/cycles_xml.h"
|
||||
|
||||
@@ -22,27 +22,27 @@
|
||||
|
||||
#include "graph/node_xml.h"
|
||||
|
||||
#include "render/background.h"
|
||||
#include "render/camera.h"
|
||||
#include "render/film.h"
|
||||
#include "render/graph.h"
|
||||
#include "render/integrator.h"
|
||||
#include "render/light.h"
|
||||
#include "render/mesh.h"
|
||||
#include "render/nodes.h"
|
||||
#include "render/object.h"
|
||||
#include "render/osl.h"
|
||||
#include "render/scene.h"
|
||||
#include "render/shader.h"
|
||||
#include "scene/background.h"
|
||||
#include "scene/camera.h"
|
||||
#include "scene/film.h"
|
||||
#include "scene/integrator.h"
|
||||
#include "scene/light.h"
|
||||
#include "scene/mesh.h"
|
||||
#include "scene/object.h"
|
||||
#include "scene/osl.h"
|
||||
#include "scene/scene.h"
|
||||
#include "scene/shader.h"
|
||||
#include "scene/shader_graph.h"
|
||||
#include "scene/shader_nodes.h"
|
||||
|
||||
#include "subd/subd_patch.h"
|
||||
#include "subd/subd_split.h"
|
||||
#include "subd/patch.h"
|
||||
#include "subd/split.h"
|
||||
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_path.h"
|
||||
#include "util/util_projection.h"
|
||||
#include "util/util_transform.h"
|
||||
#include "util/util_xml.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/path.h"
|
||||
#include "util/projection.h"
|
||||
#include "util/transform.h"
|
||||
#include "util/xml.h"
|
||||
|
||||
#include "app/cycles_xml.h"
|
||||
|
||||
|
||||
@@ -14,13 +14,13 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "render/output_driver.h"
|
||||
#include "session/output_driver.h"
|
||||
|
||||
#include "util/util_function.h"
|
||||
#include "util/util_image.h"
|
||||
#include "util/util_string.h"
|
||||
#include "util/util_unique_ptr.h"
|
||||
#include "util/util_vector.h"
|
||||
#include "util/function.h"
|
||||
#include "util/image.h"
|
||||
#include "util/string.h"
|
||||
#include "util/unique_ptr.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -29,39 +29,39 @@ set(INC_SYS
|
||||
)
|
||||
|
||||
set(SRC
|
||||
blender_camera.cpp
|
||||
blender_device.cpp
|
||||
blender_display_driver.cpp
|
||||
blender_image.cpp
|
||||
blender_geometry.cpp
|
||||
blender_light.cpp
|
||||
blender_mesh.cpp
|
||||
blender_object.cpp
|
||||
blender_object_cull.cpp
|
||||
blender_output_driver.cpp
|
||||
blender_particles.cpp
|
||||
blender_curves.cpp
|
||||
blender_logging.cpp
|
||||
blender_python.cpp
|
||||
blender_session.cpp
|
||||
blender_shader.cpp
|
||||
blender_sync.cpp
|
||||
blender_texture.cpp
|
||||
blender_viewport.cpp
|
||||
blender_volume.cpp
|
||||
camera.cpp
|
||||
device.cpp
|
||||
display_driver.cpp
|
||||
image.cpp
|
||||
geometry.cpp
|
||||
light.cpp
|
||||
mesh.cpp
|
||||
object.cpp
|
||||
object_cull.cpp
|
||||
output_driver.cpp
|
||||
particles.cpp
|
||||
curves.cpp
|
||||
logging.cpp
|
||||
python.cpp
|
||||
session.cpp
|
||||
shader.cpp
|
||||
sync.cpp
|
||||
texture.cpp
|
||||
viewport.cpp
|
||||
volume.cpp
|
||||
|
||||
CCL_api.h
|
||||
blender_device.h
|
||||
blender_display_driver.h
|
||||
blender_id_map.h
|
||||
blender_image.h
|
||||
blender_object_cull.h
|
||||
blender_output_driver.h
|
||||
blender_sync.h
|
||||
blender_session.h
|
||||
blender_texture.h
|
||||
blender_util.h
|
||||
blender_viewport.h
|
||||
device.h
|
||||
display_driver.h
|
||||
id_map.h
|
||||
image.h
|
||||
object_cull.h
|
||||
output_driver.h
|
||||
sync.h
|
||||
session.h
|
||||
texture.h
|
||||
util.h
|
||||
viewport.h
|
||||
)
|
||||
|
||||
set(LIB
|
||||
@@ -69,7 +69,8 @@ set(LIB
|
||||
cycles_device
|
||||
cycles_graph
|
||||
cycles_kernel
|
||||
cycles_render
|
||||
cycles_scene
|
||||
cycles_session
|
||||
cycles_subd
|
||||
cycles_util
|
||||
|
||||
|
||||
@@ -125,6 +125,11 @@ enum_texture_limit = (
|
||||
('8192', "8192", "Limit texture size to 8192 pixels", 7),
|
||||
)
|
||||
|
||||
enum_fast_gi_method = (
|
||||
('REPLACE', "Replace", "Replace global illumination with ambient occlusion after a specified number of bounces"),
|
||||
('ADD', "Add", "Add ambient occlusion to diffuse surfaces"),
|
||||
)
|
||||
|
||||
# NOTE: Identifiers are expected to be an upper case version of identifiers from `Pass::get_type_enum()`
|
||||
enum_view3d_shading_render_pass = (
|
||||
('', "General", ""),
|
||||
@@ -337,6 +342,24 @@ class CyclesRenderSettings(bpy.types.PropertyGroup):
|
||||
default='PROGRESSIVE_MUTI_JITTER',
|
||||
)
|
||||
|
||||
scrambling_distance: FloatProperty(
|
||||
name="Scrambling Distance",
|
||||
default=1.0,
|
||||
min=0.0, max=1.0,
|
||||
description="Lower values give faster rendering with GPU rendering and less noise with all devices at the cost of possible artifacts if set too low. Only works when not using adaptive sampling",
|
||||
)
|
||||
preview_scrambling_distance: BoolProperty(
|
||||
name="Scrambling Distance viewport",
|
||||
default=False,
|
||||
description="Uses the Scrambling Distance value for the viewport. Faster but may flicker",
|
||||
)
|
||||
|
||||
adaptive_scrambling_distance: BoolProperty(
|
||||
name="Adaptive Scrambling Distance",
|
||||
default=False,
|
||||
description="Uses a formula to adapt the scrambling distance strength based on the sample count",
|
||||
)
|
||||
|
||||
use_layer_samples: EnumProperty(
|
||||
name="Layer Samples",
|
||||
description="How to use per view layer sample settings",
|
||||
@@ -724,6 +747,14 @@ class CyclesRenderSettings(bpy.types.PropertyGroup):
|
||||
description="Approximate diffuse indirect light with background tinted ambient occlusion. This provides fast alternative to full global illumination, for interactive viewport rendering or final renders with reduced quality",
|
||||
default=False,
|
||||
)
|
||||
|
||||
fast_gi_method: EnumProperty(
|
||||
name="Fast GI Method",
|
||||
default='REPLACE',
|
||||
description="Fast GI approximation method",
|
||||
items=enum_fast_gi_method
|
||||
)
|
||||
|
||||
ao_bounces: IntProperty(
|
||||
name="AO Bounces",
|
||||
default=1,
|
||||
|
||||
@@ -287,11 +287,21 @@ class CYCLES_RENDER_PT_sampling_advanced(CyclesButtonsPanel, Panel):
|
||||
row.prop(cscene, "use_animated_seed", text="", icon='TIME')
|
||||
|
||||
col = layout.column(align=True)
|
||||
col.active = not(cscene.use_adaptive_sampling)
|
||||
col.active = not (cscene.use_adaptive_sampling and cscene.use_preview_adaptive_sampling)
|
||||
col.prop(cscene, "sampling_pattern", text="Pattern")
|
||||
|
||||
layout.separator()
|
||||
|
||||
col = layout.column(align=True)
|
||||
col.active = not (cscene.use_adaptive_sampling and cscene.use_preview_adaptive_sampling)
|
||||
col.prop(cscene, "scrambling_distance", text="Scrambling Distance")
|
||||
col.prop(cscene, "adaptive_scrambling_distance", text="Adaptive")
|
||||
sub = col.row(align=True)
|
||||
sub.active = not cscene.use_preview_adaptive_sampling
|
||||
sub.prop(cscene, "preview_scrambling_distance", text="Viewport")
|
||||
|
||||
layout.separator()
|
||||
|
||||
col = layout.column(align=True)
|
||||
col.prop(cscene, "min_light_bounces")
|
||||
col.prop(cscene, "min_transparent_bounces")
|
||||
@@ -465,8 +475,7 @@ class CYCLES_RENDER_PT_light_paths_fast_gi(CyclesButtonsPanel, Panel):
|
||||
layout.active = cscene.use_fast_gi
|
||||
|
||||
col = layout.column(align=True)
|
||||
col.prop(cscene, "ao_bounces", text="Viewport Bounces")
|
||||
col.prop(cscene, "ao_bounces_render", text="Render Bounces")
|
||||
col.prop(cscene, "fast_gi_method", text="Method")
|
||||
|
||||
if world:
|
||||
light = world.light_settings
|
||||
@@ -474,6 +483,11 @@ class CYCLES_RENDER_PT_light_paths_fast_gi(CyclesButtonsPanel, Panel):
|
||||
col.prop(light, "ao_factor", text="AO Factor")
|
||||
col.prop(light, "distance", text="AO Distance")
|
||||
|
||||
if cscene.fast_gi_method == 'REPLACE':
|
||||
col = layout.column(align=True)
|
||||
col.prop(cscene, "ao_bounces", text="Viewport Bounces")
|
||||
col.prop(cscene, "ao_bounces_render", text="Render Bounces")
|
||||
|
||||
|
||||
class CYCLES_RENDER_PT_motion_blur(CyclesButtonsPanel, Panel):
|
||||
bl_label = "Motion Blur"
|
||||
|
||||
@@ -14,13 +14,13 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "render/camera.h"
|
||||
#include "render/scene.h"
|
||||
#include "scene/camera.h"
|
||||
#include "scene/scene.h"
|
||||
|
||||
#include "blender/blender_sync.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "blender/sync.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
#include "util/util_logging.h"
|
||||
#include "util/log.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -14,19 +14,20 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "render/attribute.h"
|
||||
#include "render/camera.h"
|
||||
#include "render/curves.h"
|
||||
#include "render/hair.h"
|
||||
#include "render/object.h"
|
||||
#include "render/scene.h"
|
||||
#include "blender/sync.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
#include "blender/blender_sync.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "scene/attribute.h"
|
||||
#include "scene/camera.h"
|
||||
#include "scene/curves.h"
|
||||
#include "scene/hair.h"
|
||||
#include "scene/object.h"
|
||||
#include "scene/scene.h"
|
||||
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_hash.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/color.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/hash.h"
|
||||
#include "util/log.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -14,11 +14,11 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "blender/blender_device.h"
|
||||
#include "blender/blender_session.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "blender/device.h"
|
||||
#include "blender/session.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/foreach.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -14,11 +14,11 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "blender/blender_display_driver.h"
|
||||
#include "blender/display_driver.h"
|
||||
|
||||
#include "device/device.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/util_opengl.h"
|
||||
#include "util/log.h"
|
||||
#include "util/opengl.h"
|
||||
|
||||
extern "C" {
|
||||
struct RenderEngine;
|
||||
@@ -357,6 +357,8 @@ bool BlenderDisplayDriver::update_begin(const Params ¶ms,
|
||||
* centralized place. */
|
||||
texture_.need_update = true;
|
||||
|
||||
texture_.params = params;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -717,8 +719,23 @@ void BlenderDisplayDriver::texture_update_if_needed()
|
||||
texture_.need_update = false;
|
||||
}
|
||||
|
||||
void BlenderDisplayDriver::vertex_buffer_update(const Params ¶ms)
|
||||
void BlenderDisplayDriver::vertex_buffer_update(const Params & /*params*/)
|
||||
{
|
||||
/* Draw at the parameters for which the texture has been updated for. This allows to always draw
|
||||
* texture during bordered-rendered camera view without flickering. The validness of the display
|
||||
* parameters for a texture is guaranteed by the initial "clear" state which makes drawing to
|
||||
* have an early output.
|
||||
*
|
||||
* Such approach can cause some extra "jelly" effect during panning, but it is not more jelly
|
||||
* than overlay of selected objects. Also, it's possible to redraw texture at an intersection of
|
||||
* the texture draw parameters and the latest updated draw parameters (although, complexity of
|
||||
* doing it might not worth it. */
|
||||
const int x = texture_.params.full_offset.x;
|
||||
const int y = texture_.params.full_offset.y;
|
||||
|
||||
const int width = texture_.params.size.x;
|
||||
const int height = texture_.params.size.y;
|
||||
|
||||
/* Invalidate old contents - avoids stalling if the buffer is still waiting in queue to be
|
||||
* rendered. */
|
||||
glBufferData(GL_ARRAY_BUFFER, 16 * sizeof(float), NULL, GL_STREAM_DRAW);
|
||||
@@ -730,23 +747,23 @@ void BlenderDisplayDriver::vertex_buffer_update(const Params ¶ms)
|
||||
|
||||
vpointer[0] = 0.0f;
|
||||
vpointer[1] = 0.0f;
|
||||
vpointer[2] = params.full_offset.x;
|
||||
vpointer[3] = params.full_offset.y;
|
||||
vpointer[2] = x;
|
||||
vpointer[3] = y;
|
||||
|
||||
vpointer[4] = 1.0f;
|
||||
vpointer[5] = 0.0f;
|
||||
vpointer[6] = (float)params.size.x + params.full_offset.x;
|
||||
vpointer[7] = params.full_offset.y;
|
||||
vpointer[6] = x + width;
|
||||
vpointer[7] = y;
|
||||
|
||||
vpointer[8] = 1.0f;
|
||||
vpointer[9] = 1.0f;
|
||||
vpointer[10] = (float)params.size.x + params.full_offset.x;
|
||||
vpointer[11] = (float)params.size.y + params.full_offset.y;
|
||||
vpointer[10] = x + width;
|
||||
vpointer[11] = y + height;
|
||||
|
||||
vpointer[12] = 0.0f;
|
||||
vpointer[13] = 1.0f;
|
||||
vpointer[14] = params.full_offset.x;
|
||||
vpointer[15] = (float)params.size.y + params.full_offset.y;
|
||||
vpointer[14] = x;
|
||||
vpointer[15] = y + height;
|
||||
|
||||
glUnmapBuffer(GL_ARRAY_BUFFER);
|
||||
}
|
||||
@@ -22,10 +22,10 @@
|
||||
|
||||
#include "RNA_blender_cpp.h"
|
||||
|
||||
#include "render/display_driver.h"
|
||||
#include "session/display_driver.h"
|
||||
|
||||
#include "util/util_thread.h"
|
||||
#include "util/util_unique_ptr.h"
|
||||
#include "util/thread.h"
|
||||
#include "util/unique_ptr.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -188,6 +188,9 @@ class BlenderDisplayDriver : public DisplayDriver {
|
||||
/* Dimensions of the underlying PBO. */
|
||||
int buffer_width = 0;
|
||||
int buffer_height = 0;
|
||||
|
||||
/* Display parameters the texture has been updated for. */
|
||||
Params params;
|
||||
} texture_;
|
||||
|
||||
unique_ptr<BlenderDisplayShader> display_shader_;
|
||||
@@ -15,17 +15,17 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "render/curves.h"
|
||||
#include "render/hair.h"
|
||||
#include "render/mesh.h"
|
||||
#include "render/object.h"
|
||||
#include "render/volume.h"
|
||||
#include "scene/curves.h"
|
||||
#include "scene/hair.h"
|
||||
#include "scene/mesh.h"
|
||||
#include "scene/object.h"
|
||||
#include "scene/volume.h"
|
||||
|
||||
#include "blender/blender_sync.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "blender/sync.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_task.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/task.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -19,12 +19,12 @@
|
||||
|
||||
#include <string.h>
|
||||
|
||||
#include "render/geometry.h"
|
||||
#include "render/scene.h"
|
||||
#include "scene/geometry.h"
|
||||
#include "scene/scene.h"
|
||||
|
||||
#include "util/util_map.h"
|
||||
#include "util/util_set.h"
|
||||
#include "util/util_vector.h"
|
||||
#include "util/map.h"
|
||||
#include "util/set.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -16,9 +16,9 @@
|
||||
|
||||
#include "MEM_guardedalloc.h"
|
||||
|
||||
#include "blender/blender_image.h"
|
||||
#include "blender/blender_session.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "blender/image.h"
|
||||
#include "blender/session.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
#include "RNA_blender_cpp.h"
|
||||
|
||||
#include "render/image.h"
|
||||
#include "scene/image.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -16,12 +16,12 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "render/light.h"
|
||||
#include "scene/light.h"
|
||||
|
||||
#include "blender/blender_sync.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "blender/sync.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
#include "util/util_hash.h"
|
||||
#include "util/hash.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
*/
|
||||
|
||||
#include "blender/CCL_api.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/log.h"
|
||||
|
||||
void CCL_init_logging(const char *argv0)
|
||||
{
|
||||
@@ -14,25 +14,26 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "render/camera.h"
|
||||
#include "render/colorspace.h"
|
||||
#include "render/mesh.h"
|
||||
#include "render/object.h"
|
||||
#include "render/scene.h"
|
||||
#include "blender/session.h"
|
||||
#include "blender/sync.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
#include "blender/blender_session.h"
|
||||
#include "blender/blender_sync.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "scene/camera.h"
|
||||
#include "scene/colorspace.h"
|
||||
#include "scene/mesh.h"
|
||||
#include "scene/object.h"
|
||||
#include "scene/scene.h"
|
||||
|
||||
#include "subd/subd_patch.h"
|
||||
#include "subd/subd_split.h"
|
||||
#include "subd/patch.h"
|
||||
#include "subd/split.h"
|
||||
|
||||
#include "util/util_algorithm.h"
|
||||
#include "util/util_disjoint_set.h"
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_hash.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/util_math.h"
|
||||
#include "util/algorithm.h"
|
||||
#include "util/color.h"
|
||||
#include "util/disjoint_set.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/hash.h"
|
||||
#include "util/log.h"
|
||||
#include "util/math.h"
|
||||
|
||||
#include "mikktspace.h"
|
||||
|
||||
@@ -14,26 +14,26 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "render/alembic.h"
|
||||
#include "render/camera.h"
|
||||
#include "render/graph.h"
|
||||
#include "render/integrator.h"
|
||||
#include "render/light.h"
|
||||
#include "render/mesh.h"
|
||||
#include "render/nodes.h"
|
||||
#include "render/object.h"
|
||||
#include "render/particles.h"
|
||||
#include "render/scene.h"
|
||||
#include "render/shader.h"
|
||||
#include "blender/object_cull.h"
|
||||
#include "blender/sync.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
#include "blender/blender_object_cull.h"
|
||||
#include "blender/blender_sync.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "scene/alembic.h"
|
||||
#include "scene/camera.h"
|
||||
#include "scene/integrator.h"
|
||||
#include "scene/light.h"
|
||||
#include "scene/mesh.h"
|
||||
#include "scene/object.h"
|
||||
#include "scene/particles.h"
|
||||
#include "scene/scene.h"
|
||||
#include "scene/shader.h"
|
||||
#include "scene/shader_graph.h"
|
||||
#include "scene/shader_nodes.h"
|
||||
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_hash.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/util_task.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/hash.h"
|
||||
#include "util/log.h"
|
||||
#include "util/task.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -16,10 +16,10 @@
|
||||
|
||||
#include <cstdlib>
|
||||
|
||||
#include "render/camera.h"
|
||||
#include "scene/camera.h"
|
||||
|
||||
#include "blender/blender_object_cull.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "blender/object_cull.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -17,8 +17,8 @@
|
||||
#ifndef __BLENDER_OBJECT_CULL_H__
|
||||
#define __BLENDER_OBJECT_CULL_H__
|
||||
|
||||
#include "blender/blender_sync.h"
|
||||
#include "util/util_types.h"
|
||||
#include "blender/sync.h"
|
||||
#include "util/types.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "blender/blender_output_driver.h"
|
||||
#include "blender/output_driver.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
|
||||
#include "RNA_blender_cpp.h"
|
||||
|
||||
#include "render/output_driver.h"
|
||||
#include "session/output_driver.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -14,14 +14,14 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "render/mesh.h"
|
||||
#include "render/object.h"
|
||||
#include "render/particles.h"
|
||||
#include "scene/particles.h"
|
||||
#include "scene/mesh.h"
|
||||
#include "scene/object.h"
|
||||
|
||||
#include "blender/blender_sync.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "blender/sync.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/foreach.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -18,28 +18,28 @@
|
||||
|
||||
#include "blender/CCL_api.h"
|
||||
|
||||
#include "blender/blender_device.h"
|
||||
#include "blender/blender_session.h"
|
||||
#include "blender/blender_sync.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "blender/device.h"
|
||||
#include "blender/session.h"
|
||||
#include "blender/sync.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
#include "render/denoising.h"
|
||||
#include "render/merge.h"
|
||||
#include "session/denoising.h"
|
||||
#include "session/merge.h"
|
||||
|
||||
#include "util/util_debug.h"
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/util_md5.h"
|
||||
#include "util/util_opengl.h"
|
||||
#include "util/util_openimagedenoise.h"
|
||||
#include "util/util_path.h"
|
||||
#include "util/util_string.h"
|
||||
#include "util/util_task.h"
|
||||
#include "util/util_tbb.h"
|
||||
#include "util/util_types.h"
|
||||
#include "util/debug.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/log.h"
|
||||
#include "util/md5.h"
|
||||
#include "util/opengl.h"
|
||||
#include "util/openimagedenoise.h"
|
||||
#include "util/path.h"
|
||||
#include "util/string.h"
|
||||
#include "util/task.h"
|
||||
#include "util/tbb.h"
|
||||
#include "util/types.h"
|
||||
|
||||
#ifdef WITH_OSL
|
||||
# include "render/osl.h"
|
||||
# include "scene/osl.h"
|
||||
|
||||
# include <OSL/oslconfig.h>
|
||||
# include <OSL/oslquery.h>
|
||||
@@ -17,36 +17,36 @@
|
||||
#include <stdlib.h>
|
||||
|
||||
#include "device/device.h"
|
||||
#include "render/background.h"
|
||||
#include "render/buffers.h"
|
||||
#include "render/camera.h"
|
||||
#include "render/colorspace.h"
|
||||
#include "render/film.h"
|
||||
#include "render/integrator.h"
|
||||
#include "render/light.h"
|
||||
#include "render/mesh.h"
|
||||
#include "render/object.h"
|
||||
#include "render/scene.h"
|
||||
#include "render/session.h"
|
||||
#include "render/shader.h"
|
||||
#include "render/stats.h"
|
||||
#include "scene/background.h"
|
||||
#include "scene/camera.h"
|
||||
#include "scene/colorspace.h"
|
||||
#include "scene/film.h"
|
||||
#include "scene/integrator.h"
|
||||
#include "scene/light.h"
|
||||
#include "scene/mesh.h"
|
||||
#include "scene/object.h"
|
||||
#include "scene/scene.h"
|
||||
#include "scene/shader.h"
|
||||
#include "scene/stats.h"
|
||||
#include "session/buffers.h"
|
||||
#include "session/session.h"
|
||||
|
||||
#include "util/util_algorithm.h"
|
||||
#include "util/util_color.h"
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_function.h"
|
||||
#include "util/util_hash.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/util_murmurhash.h"
|
||||
#include "util/util_path.h"
|
||||
#include "util/util_progress.h"
|
||||
#include "util/util_time.h"
|
||||
#include "util/algorithm.h"
|
||||
#include "util/color.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/function.h"
|
||||
#include "util/hash.h"
|
||||
#include "util/log.h"
|
||||
#include "util/murmurhash.h"
|
||||
#include "util/path.h"
|
||||
#include "util/progress.h"
|
||||
#include "util/time.h"
|
||||
|
||||
#include "blender/blender_display_driver.h"
|
||||
#include "blender/blender_output_driver.h"
|
||||
#include "blender/blender_session.h"
|
||||
#include "blender/blender_sync.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "blender/display_driver.h"
|
||||
#include "blender/output_driver.h"
|
||||
#include "blender/session.h"
|
||||
#include "blender/sync.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -17,15 +17,17 @@
|
||||
#ifndef __BLENDER_SESSION_H__
|
||||
#define __BLENDER_SESSION_H__
|
||||
|
||||
#include "MEM_guardedalloc.h"
|
||||
|
||||
#include "RNA_blender_cpp.h"
|
||||
|
||||
#include "device/device.h"
|
||||
|
||||
#include "render/bake.h"
|
||||
#include "render/scene.h"
|
||||
#include "render/session.h"
|
||||
#include "scene/bake.h"
|
||||
#include "scene/scene.h"
|
||||
#include "session/session.h"
|
||||
|
||||
#include "util/util_vector.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -14,26 +14,26 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "render/background.h"
|
||||
#include "render/colorspace.h"
|
||||
#include "render/graph.h"
|
||||
#include "render/integrator.h"
|
||||
#include "render/light.h"
|
||||
#include "render/nodes.h"
|
||||
#include "render/osl.h"
|
||||
#include "render/scene.h"
|
||||
#include "render/shader.h"
|
||||
#include "scene/shader.h"
|
||||
#include "scene/background.h"
|
||||
#include "scene/colorspace.h"
|
||||
#include "scene/integrator.h"
|
||||
#include "scene/light.h"
|
||||
#include "scene/osl.h"
|
||||
#include "scene/scene.h"
|
||||
#include "scene/shader_graph.h"
|
||||
#include "scene/shader_nodes.h"
|
||||
|
||||
#include "blender/blender_image.h"
|
||||
#include "blender/blender_sync.h"
|
||||
#include "blender/blender_texture.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "blender/image.h"
|
||||
#include "blender/sync.h"
|
||||
#include "blender/texture.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
#include "util/util_debug.h"
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_set.h"
|
||||
#include "util/util_string.h"
|
||||
#include "util/util_task.h"
|
||||
#include "util/debug.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/set.h"
|
||||
#include "util/string.h"
|
||||
#include "util/task.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -1375,6 +1375,7 @@ void BlenderSync::sync_world(BL::Depsgraph &b_depsgraph, BL::SpaceView3D &b_v3d,
|
||||
{
|
||||
Background *background = scene->background;
|
||||
Integrator *integrator = scene->integrator;
|
||||
PointerRNA cscene = RNA_pointer_get(&b_scene.ptr, "cycles");
|
||||
|
||||
BL::World b_world = b_scene.world();
|
||||
|
||||
@@ -1466,14 +1467,8 @@ void BlenderSync::sync_world(BL::Depsgraph &b_depsgraph, BL::SpaceView3D &b_v3d,
|
||||
graph->connect(background->output("Background"), out->input("Surface"));
|
||||
}
|
||||
|
||||
/* Visibility */
|
||||
if (b_world) {
|
||||
/* AO */
|
||||
BL::WorldLighting b_light = b_world.light_settings();
|
||||
|
||||
integrator->set_ao_factor(b_light.ao_factor());
|
||||
integrator->set_ao_distance(b_light.distance());
|
||||
|
||||
/* visibility */
|
||||
PointerRNA cvisibility = RNA_pointer_get(&b_world.ptr, "cycles_visibility");
|
||||
uint visibility = 0;
|
||||
|
||||
@@ -1485,16 +1480,38 @@ void BlenderSync::sync_world(BL::Depsgraph &b_depsgraph, BL::SpaceView3D &b_v3d,
|
||||
|
||||
background->set_visibility(visibility);
|
||||
}
|
||||
else {
|
||||
integrator->set_ao_factor(1.0f);
|
||||
integrator->set_ao_distance(10.0f);
|
||||
}
|
||||
|
||||
shader->set_graph(graph);
|
||||
shader->tag_update(scene);
|
||||
}
|
||||
|
||||
PointerRNA cscene = RNA_pointer_get(&b_scene.ptr, "cycles");
|
||||
/* Fast GI */
|
||||
if (b_world) {
|
||||
BL::WorldLighting b_light = b_world.light_settings();
|
||||
enum { FAST_GI_METHOD_REPLACE = 0, FAST_GI_METHOD_ADD = 1, FAST_GI_METHOD_NUM };
|
||||
|
||||
const bool use_fast_gi = get_boolean(cscene, "use_fast_gi");
|
||||
if (use_fast_gi) {
|
||||
const int fast_gi_method = get_enum(
|
||||
cscene, "fast_gi_method", FAST_GI_METHOD_NUM, FAST_GI_METHOD_REPLACE);
|
||||
integrator->set_ao_factor((fast_gi_method == FAST_GI_METHOD_REPLACE) ? b_light.ao_factor() :
|
||||
0.0f);
|
||||
integrator->set_ao_additive_factor(
|
||||
(fast_gi_method == FAST_GI_METHOD_ADD) ? b_light.ao_factor() : 0.0f);
|
||||
}
|
||||
else {
|
||||
integrator->set_ao_factor(0.0f);
|
||||
integrator->set_ao_additive_factor(0.0f);
|
||||
}
|
||||
|
||||
integrator->set_ao_distance(b_light.distance());
|
||||
}
|
||||
else {
|
||||
integrator->set_ao_factor(0.0f);
|
||||
integrator->set_ao_additive_factor(0.0f);
|
||||
integrator->set_ao_distance(10.0f);
|
||||
}
|
||||
|
||||
background->set_transparent(b_scene.render().film_transparent());
|
||||
|
||||
if (background->get_transparent()) {
|
||||
@@ -14,33 +14,33 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "render/background.h"
|
||||
#include "render/camera.h"
|
||||
#include "render/curves.h"
|
||||
#include "render/film.h"
|
||||
#include "render/graph.h"
|
||||
#include "render/integrator.h"
|
||||
#include "render/light.h"
|
||||
#include "render/mesh.h"
|
||||
#include "render/nodes.h"
|
||||
#include "render/object.h"
|
||||
#include "render/procedural.h"
|
||||
#include "render/scene.h"
|
||||
#include "render/shader.h"
|
||||
#include "scene/background.h"
|
||||
#include "scene/camera.h"
|
||||
#include "scene/curves.h"
|
||||
#include "scene/film.h"
|
||||
#include "scene/integrator.h"
|
||||
#include "scene/light.h"
|
||||
#include "scene/mesh.h"
|
||||
#include "scene/object.h"
|
||||
#include "scene/procedural.h"
|
||||
#include "scene/scene.h"
|
||||
#include "scene/shader.h"
|
||||
#include "scene/shader_graph.h"
|
||||
#include "scene/shader_nodes.h"
|
||||
|
||||
#include "device/device.h"
|
||||
|
||||
#include "blender/blender_device.h"
|
||||
#include "blender/blender_session.h"
|
||||
#include "blender/blender_sync.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "blender/device.h"
|
||||
#include "blender/session.h"
|
||||
#include "blender/sync.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
#include "util/util_debug.h"
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_hash.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/util_opengl.h"
|
||||
#include "util/util_openimagedenoise.h"
|
||||
#include "util/debug.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/hash.h"
|
||||
#include "util/log.h"
|
||||
#include "util/opengl.h"
|
||||
#include "util/openimagedenoise.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -340,18 +340,35 @@ void BlenderSync::sync_integrator(BL::ViewLayer &b_view_layer, bool background)
|
||||
cscene, "sampling_pattern", SAMPLING_NUM_PATTERNS, SAMPLING_PATTERN_SOBOL);
|
||||
integrator->set_sampling_pattern(sampling_pattern);
|
||||
|
||||
bool use_adaptive_sampling = false;
|
||||
if (preview) {
|
||||
integrator->set_use_adaptive_sampling(
|
||||
RNA_boolean_get(&cscene, "use_preview_adaptive_sampling"));
|
||||
use_adaptive_sampling = RNA_boolean_get(&cscene, "use_preview_adaptive_sampling");
|
||||
integrator->set_use_adaptive_sampling(use_adaptive_sampling);
|
||||
integrator->set_adaptive_threshold(get_float(cscene, "preview_adaptive_threshold"));
|
||||
integrator->set_adaptive_min_samples(get_int(cscene, "preview_adaptive_min_samples"));
|
||||
}
|
||||
else {
|
||||
integrator->set_use_adaptive_sampling(RNA_boolean_get(&cscene, "use_adaptive_sampling"));
|
||||
use_adaptive_sampling = RNA_boolean_get(&cscene, "use_adaptive_sampling");
|
||||
integrator->set_use_adaptive_sampling(use_adaptive_sampling);
|
||||
integrator->set_adaptive_threshold(get_float(cscene, "adaptive_threshold"));
|
||||
integrator->set_adaptive_min_samples(get_int(cscene, "adaptive_min_samples"));
|
||||
}
|
||||
|
||||
int samples = get_int(cscene, "samples");
|
||||
float scrambling_distance = get_float(cscene, "scrambling_distance");
|
||||
bool adaptive_scrambling_distance = get_boolean(cscene, "adaptive_scrambling_distance");
|
||||
if (adaptive_scrambling_distance) {
|
||||
scrambling_distance *= 4.0f / sqrtf(samples);
|
||||
}
|
||||
|
||||
/* only use scrambling distance in the viewport if user wants to and disable with AS */
|
||||
bool preview_scrambling_distance = get_boolean(cscene, "preview_scrambling_distance");
|
||||
if ((preview && !preview_scrambling_distance) || use_adaptive_sampling)
|
||||
scrambling_distance = 1.0f;
|
||||
|
||||
VLOG(1) << "Used Scrambling Distance: " << scrambling_distance;
|
||||
integrator->set_scrambling_distance(scrambling_distance);
|
||||
|
||||
if (get_boolean(cscene, "use_fast_gi")) {
|
||||
if (preview) {
|
||||
integrator->set_ao_bounces(get_int(cscene, "ao_bounces"));
|
||||
@@ -541,6 +558,7 @@ static PassType get_blender_pass_type(BL::RenderPass &b_pass)
|
||||
|
||||
MAP_PASS("Denoising Normal", PASS_DENOISING_NORMAL);
|
||||
MAP_PASS("Denoising Albedo", PASS_DENOISING_ALBEDO);
|
||||
MAP_PASS("Denoising Depth", PASS_DENOISING_DEPTH);
|
||||
|
||||
MAP_PASS("Shadow Catcher", PASS_SHADOW_CATCHER);
|
||||
MAP_PASS("Noisy Shadow Catcher", PASS_SHADOW_CATCHER);
|
||||
@@ -670,6 +688,9 @@ void BlenderSync::sync_render_passes(BL::RenderLayer &b_rlay, BL::ViewLayer &b_v
|
||||
|
||||
b_engine.add_pass("Denoising Albedo", 3, "RGB", b_view_layer.name().c_str());
|
||||
pass_add(scene, PASS_DENOISING_ALBEDO, "Denoising Albedo", PassMode::NOISY);
|
||||
|
||||
b_engine.add_pass("Denoising Depth", 1, "Z", b_view_layer.name().c_str());
|
||||
pass_add(scene, PASS_DENOISING_DEPTH, "Denoising Depth", PassMode::NOISY);
|
||||
}
|
||||
|
||||
/* Custom AOV passes. */
|
||||
@@ -22,17 +22,17 @@
|
||||
#include "RNA_blender_cpp.h"
|
||||
#include "RNA_types.h"
|
||||
|
||||
#include "blender/blender_id_map.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "blender/blender_viewport.h"
|
||||
#include "blender/id_map.h"
|
||||
#include "blender/util.h"
|
||||
#include "blender/viewport.h"
|
||||
|
||||
#include "render/scene.h"
|
||||
#include "render/session.h"
|
||||
#include "scene/scene.h"
|
||||
#include "session/session.h"
|
||||
|
||||
#include "util/util_map.h"
|
||||
#include "util/util_set.h"
|
||||
#include "util/util_transform.h"
|
||||
#include "util/util_vector.h"
|
||||
#include "util/map.h"
|
||||
#include "util/set.h"
|
||||
#include "util/transform.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "blender/blender_texture.h"
|
||||
#include "blender/texture.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
#ifndef __BLENDER_TEXTURE_H__
|
||||
#define __BLENDER_TEXTURE_H__
|
||||
|
||||
#include "blender/blender_sync.h"
|
||||
#include "blender/sync.h"
|
||||
#include <stdlib.h>
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
@@ -17,16 +17,16 @@
|
||||
#ifndef __BLENDER_UTIL_H__
|
||||
#define __BLENDER_UTIL_H__
|
||||
|
||||
#include "render/mesh.h"
|
||||
#include "scene/mesh.h"
|
||||
|
||||
#include "util/util_algorithm.h"
|
||||
#include "util/util_array.h"
|
||||
#include "util/util_map.h"
|
||||
#include "util/util_path.h"
|
||||
#include "util/util_set.h"
|
||||
#include "util/util_transform.h"
|
||||
#include "util/util_types.h"
|
||||
#include "util/util_vector.h"
|
||||
#include "util/algorithm.h"
|
||||
#include "util/array.h"
|
||||
#include "util/map.h"
|
||||
#include "util/path.h"
|
||||
#include "util/set.h"
|
||||
#include "util/transform.h"
|
||||
#include "util/types.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
/* Hacks to hook into Blender API
|
||||
* todo: clean this up ... */
|
||||
@@ -14,11 +14,12 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "blender_viewport.h"
|
||||
#include "blender/viewport.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
#include "blender_util.h"
|
||||
#include "render/pass.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "scene/pass.h"
|
||||
|
||||
#include "util/log.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
#include "RNA_blender_cpp.h"
|
||||
#include "RNA_types.h"
|
||||
|
||||
#include "render/film.h"
|
||||
#include "scene/film.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -14,14 +14,14 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "render/colorspace.h"
|
||||
#include "render/image.h"
|
||||
#include "render/image_vdb.h"
|
||||
#include "render/object.h"
|
||||
#include "render/volume.h"
|
||||
#include "scene/volume.h"
|
||||
#include "scene/colorspace.h"
|
||||
#include "scene/image.h"
|
||||
#include "scene/image_vdb.h"
|
||||
#include "scene/object.h"
|
||||
|
||||
#include "blender/blender_sync.h"
|
||||
#include "blender/blender_util.h"
|
||||
#include "blender/sync.h"
|
||||
#include "blender/util.h"
|
||||
|
||||
#ifdef WITH_OPENVDB
|
||||
# include <openvdb/openvdb.h>
|
||||
@@ -22,34 +22,34 @@ set(INC_SYS
|
||||
set(SRC
|
||||
bvh.cpp
|
||||
bvh2.cpp
|
||||
bvh_binning.cpp
|
||||
bvh_build.cpp
|
||||
bvh_embree.cpp
|
||||
bvh_multi.cpp
|
||||
bvh_node.cpp
|
||||
bvh_optix.cpp
|
||||
bvh_sort.cpp
|
||||
bvh_split.cpp
|
||||
bvh_unaligned.cpp
|
||||
binning.cpp
|
||||
build.cpp
|
||||
embree.cpp
|
||||
multi.cpp
|
||||
node.cpp
|
||||
optix.cpp
|
||||
sort.cpp
|
||||
split.cpp
|
||||
unaligned.cpp
|
||||
)
|
||||
|
||||
set(SRC_HEADERS
|
||||
bvh.h
|
||||
bvh2.h
|
||||
bvh_binning.h
|
||||
bvh_build.h
|
||||
bvh_embree.h
|
||||
bvh_multi.h
|
||||
bvh_node.h
|
||||
bvh_optix.h
|
||||
bvh_params.h
|
||||
bvh_sort.h
|
||||
bvh_split.h
|
||||
bvh_unaligned.h
|
||||
binning.h
|
||||
build.h
|
||||
embree.h
|
||||
multi.h
|
||||
node.h
|
||||
optix.h
|
||||
params.h
|
||||
sort.h
|
||||
split.h
|
||||
unaligned.h
|
||||
)
|
||||
|
||||
set(LIB
|
||||
cycles_render
|
||||
cycles_scene
|
||||
cycles_util
|
||||
)
|
||||
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
|
||||
//#define __KERNEL_SSE__
|
||||
|
||||
#include "bvh/bvh_binning.h"
|
||||
#include "bvh/binning.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#include "util/util_algorithm.h"
|
||||
#include "util/util_boundbox.h"
|
||||
#include "util/util_types.h"
|
||||
#include "util/algorithm.h"
|
||||
#include "util/boundbox.h"
|
||||
#include "util/types.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -18,10 +18,10 @@
|
||||
#ifndef __BVH_BINNING_H__
|
||||
#define __BVH_BINNING_H__
|
||||
|
||||
#include "bvh/bvh_params.h"
|
||||
#include "bvh/bvh_unaligned.h"
|
||||
#include "bvh/params.h"
|
||||
#include "bvh/unaligned.h"
|
||||
|
||||
#include "util/util_types.h"
|
||||
#include "util/types.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -15,27 +15,27 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "bvh/bvh_build.h"
|
||||
#include "bvh/build.h"
|
||||
|
||||
#include "bvh/bvh_binning.h"
|
||||
#include "bvh/bvh_node.h"
|
||||
#include "bvh/bvh_params.h"
|
||||
#include "bvh_split.h"
|
||||
#include "bvh/binning.h"
|
||||
#include "bvh/node.h"
|
||||
#include "bvh/params.h"
|
||||
#include "bvh/split.h"
|
||||
|
||||
#include "render/curves.h"
|
||||
#include "render/hair.h"
|
||||
#include "render/mesh.h"
|
||||
#include "render/object.h"
|
||||
#include "render/scene.h"
|
||||
#include "scene/curves.h"
|
||||
#include "scene/hair.h"
|
||||
#include "scene/mesh.h"
|
||||
#include "scene/object.h"
|
||||
#include "scene/scene.h"
|
||||
|
||||
#include "util/util_algorithm.h"
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/util_progress.h"
|
||||
#include "util/util_queue.h"
|
||||
#include "util/util_simd.h"
|
||||
#include "util/util_stack_allocator.h"
|
||||
#include "util/util_time.h"
|
||||
#include "util/algorithm.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/log.h"
|
||||
#include "util/progress.h"
|
||||
#include "util/queue.h"
|
||||
#include "util/simd.h"
|
||||
#include "util/stack_allocator.h"
|
||||
#include "util/time.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -20,12 +20,12 @@
|
||||
|
||||
#include <float.h>
|
||||
|
||||
#include "bvh/bvh_params.h"
|
||||
#include "bvh/bvh_unaligned.h"
|
||||
#include "bvh/params.h"
|
||||
#include "bvh/unaligned.h"
|
||||
|
||||
#include "util/util_array.h"
|
||||
#include "util/util_task.h"
|
||||
#include "util/util_vector.h"
|
||||
#include "util/array.h"
|
||||
#include "util/task.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -18,12 +18,12 @@
|
||||
#include "bvh/bvh.h"
|
||||
|
||||
#include "bvh/bvh2.h"
|
||||
#include "bvh/bvh_embree.h"
|
||||
#include "bvh/bvh_multi.h"
|
||||
#include "bvh/bvh_optix.h"
|
||||
#include "bvh/embree.h"
|
||||
#include "bvh/multi.h"
|
||||
#include "bvh/optix.h"
|
||||
|
||||
#include "util/util_logging.h"
|
||||
#include "util/util_progress.h"
|
||||
#include "util/log.h"
|
||||
#include "util/progress.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -18,10 +18,10 @@
|
||||
#ifndef __BVH_H__
|
||||
#define __BVH_H__
|
||||
|
||||
#include "bvh/bvh_params.h"
|
||||
#include "util/util_array.h"
|
||||
#include "util/util_types.h"
|
||||
#include "util/util_vector.h"
|
||||
#include "bvh/params.h"
|
||||
#include "util/array.h"
|
||||
#include "util/types.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -17,16 +17,16 @@
|
||||
|
||||
#include "bvh/bvh2.h"
|
||||
|
||||
#include "render/hair.h"
|
||||
#include "render/mesh.h"
|
||||
#include "render/object.h"
|
||||
#include "scene/hair.h"
|
||||
#include "scene/mesh.h"
|
||||
#include "scene/object.h"
|
||||
|
||||
#include "bvh/bvh_build.h"
|
||||
#include "bvh/bvh_node.h"
|
||||
#include "bvh/bvh_unaligned.h"
|
||||
#include "bvh/build.h"
|
||||
#include "bvh/node.h"
|
||||
#include "bvh/unaligned.h"
|
||||
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_progress.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/progress.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -19,10 +19,10 @@
|
||||
#define __BVH2_H__
|
||||
|
||||
#include "bvh/bvh.h"
|
||||
#include "bvh/bvh_params.h"
|
||||
#include "bvh/params.h"
|
||||
|
||||
#include "util/util_types.h"
|
||||
#include "util/util_vector.h"
|
||||
#include "util/types.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -32,24 +32,24 @@
|
||||
|
||||
# include <embree3/rtcore_geometry.h>
|
||||
|
||||
# include "bvh/bvh_embree.h"
|
||||
# include "bvh/embree.h"
|
||||
|
||||
/* Kernel includes are necessary so that the filter function for Embree can access the packed BVH.
|
||||
*/
|
||||
# include "kernel/bvh/bvh_embree.h"
|
||||
# include "kernel/bvh/bvh_util.h"
|
||||
# include "kernel/bvh/embree.h"
|
||||
# include "kernel/bvh/util.h"
|
||||
# include "kernel/device/cpu/compat.h"
|
||||
# include "kernel/device/cpu/globals.h"
|
||||
# include "kernel/kernel_random.h"
|
||||
# include "kernel/sample/lcg.h"
|
||||
|
||||
# include "render/hair.h"
|
||||
# include "render/mesh.h"
|
||||
# include "render/object.h"
|
||||
# include "scene/hair.h"
|
||||
# include "scene/mesh.h"
|
||||
# include "scene/object.h"
|
||||
|
||||
# include "util/util_foreach.h"
|
||||
# include "util/util_logging.h"
|
||||
# include "util/util_progress.h"
|
||||
# include "util/util_stats.h"
|
||||
# include "util/foreach.h"
|
||||
# include "util/log.h"
|
||||
# include "util/progress.h"
|
||||
# include "util/stats.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -23,11 +23,11 @@
|
||||
# include <embree3/rtcore_scene.h>
|
||||
|
||||
# include "bvh/bvh.h"
|
||||
# include "bvh/bvh_params.h"
|
||||
# include "bvh/params.h"
|
||||
|
||||
# include "util/util_thread.h"
|
||||
# include "util/util_types.h"
|
||||
# include "util/util_vector.h"
|
||||
# include "util/thread.h"
|
||||
# include "util/types.h"
|
||||
# include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -14,9 +14,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "bvh/bvh_multi.h"
|
||||
#include "bvh/multi.h"
|
||||
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/foreach.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
#define __BVH_MULTI_H__
|
||||
|
||||
#include "bvh/bvh.h"
|
||||
#include "bvh/bvh_params.h"
|
||||
#include "bvh/params.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -15,12 +15,12 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "bvh/bvh_node.h"
|
||||
#include "bvh/node.h"
|
||||
|
||||
#include "bvh/build.h"
|
||||
#include "bvh/bvh.h"
|
||||
#include "bvh/bvh_build.h"
|
||||
|
||||
#include "util/util_vector.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -18,8 +18,8 @@
|
||||
#ifndef __BVH_NODE_H__
|
||||
#define __BVH_NODE_H__
|
||||
|
||||
#include "util/util_boundbox.h"
|
||||
#include "util/util_types.h"
|
||||
#include "util/boundbox.h"
|
||||
#include "util/types.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
# include "device/device.h"
|
||||
|
||||
# include "bvh/bvh_optix.h"
|
||||
# include "bvh/optix.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -21,8 +21,9 @@
|
||||
#ifdef WITH_OPTIX
|
||||
|
||||
# include "bvh/bvh.h"
|
||||
# include "bvh/bvh_params.h"
|
||||
# include "device/device_memory.h"
|
||||
# include "bvh/params.h"
|
||||
|
||||
# include "device/memory.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -18,9 +18,9 @@
|
||||
#ifndef __BVH_PARAMS_H__
|
||||
#define __BVH_PARAMS_H__
|
||||
|
||||
#include "util/util_boundbox.h"
|
||||
#include "util/boundbox.h"
|
||||
|
||||
#include "kernel/kernel_types.h"
|
||||
#include "kernel/types.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -15,12 +15,12 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "bvh/bvh_sort.h"
|
||||
#include "bvh/sort.h"
|
||||
|
||||
#include "bvh/bvh_build.h"
|
||||
#include "bvh/build.h"
|
||||
|
||||
#include "util/util_algorithm.h"
|
||||
#include "util/util_task.h"
|
||||
#include "util/algorithm.h"
|
||||
#include "util/task.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -15,16 +15,16 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "bvh/bvh_split.h"
|
||||
#include "bvh/split.h"
|
||||
|
||||
#include "bvh/bvh_build.h"
|
||||
#include "bvh/bvh_sort.h"
|
||||
#include "bvh/build.h"
|
||||
#include "bvh/sort.h"
|
||||
|
||||
#include "render/hair.h"
|
||||
#include "render/mesh.h"
|
||||
#include "render/object.h"
|
||||
#include "scene/hair.h"
|
||||
#include "scene/mesh.h"
|
||||
#include "scene/object.h"
|
||||
|
||||
#include "util/util_algorithm.h"
|
||||
#include "util/algorithm.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -18,8 +18,8 @@
|
||||
#ifndef __BVH_SPLIT_H__
|
||||
#define __BVH_SPLIT_H__
|
||||
|
||||
#include "bvh/bvh_build.h"
|
||||
#include "bvh/bvh_params.h"
|
||||
#include "bvh/build.h"
|
||||
#include "bvh/params.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -14,16 +14,16 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "bvh/bvh_unaligned.h"
|
||||
#include "bvh/unaligned.h"
|
||||
|
||||
#include "render/hair.h"
|
||||
#include "render/object.h"
|
||||
#include "scene/hair.h"
|
||||
#include "scene/object.h"
|
||||
|
||||
#include "bvh/bvh_binning.h"
|
||||
#include "bvh_params.h"
|
||||
#include "bvh/binning.h"
|
||||
#include "bvh/params.h"
|
||||
|
||||
#include "util/util_boundbox.h"
|
||||
#include "util/util_transform.h"
|
||||
#include "util/boundbox.h"
|
||||
#include "util/transform.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
#ifndef __BVH_UNALIGNED_H__
|
||||
#define __BVH_UNALIGNED_H__
|
||||
|
||||
#include "util/util_vector.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -45,11 +45,11 @@ endif()
|
||||
|
||||
set(SRC
|
||||
device.cpp
|
||||
device_denoise.cpp
|
||||
device_graphics_interop.cpp
|
||||
device_kernel.cpp
|
||||
device_memory.cpp
|
||||
device_queue.cpp
|
||||
denoise.cpp
|
||||
graphics_interop.cpp
|
||||
kernel.cpp
|
||||
memory.cpp
|
||||
queue.cpp
|
||||
)
|
||||
|
||||
set(SRC_CPU
|
||||
@@ -116,11 +116,11 @@ set(SRC_OPTIX
|
||||
|
||||
set(SRC_HEADERS
|
||||
device.h
|
||||
device_denoise.h
|
||||
device_graphics_interop.h
|
||||
device_memory.h
|
||||
device_kernel.h
|
||||
device_queue.h
|
||||
denoise.h
|
||||
graphics_interop.h
|
||||
memory.h
|
||||
kernel.h
|
||||
queue.h
|
||||
)
|
||||
|
||||
set(LIB
|
||||
@@ -158,9 +158,6 @@ endif()
|
||||
if(WITH_CYCLES_DEVICE_OPTIX)
|
||||
add_definitions(-DWITH_OPTIX)
|
||||
endif()
|
||||
if(WITH_CYCLES_DEVICE_MULTI)
|
||||
add_definitions(-DWITH_MULTI)
|
||||
endif()
|
||||
|
||||
if(WITH_OPENIMAGEDENOISE)
|
||||
list(APPEND LIB
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
/* Used for `info.denoisers`. */
|
||||
/* TODO(sergey): The denoisers are probably to be moved completely out of the device into their
|
||||
* own class. But until then keep API consistent with how it used to work before. */
|
||||
#include "util/util_openimagedenoise.h"
|
||||
#include "util/openimagedenoise.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -16,8 +16,8 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "util/util_string.h"
|
||||
#include "util/util_vector.h"
|
||||
#include "util/string.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
/* So ImathMath is included before our kernel_cpu_compat. */
|
||||
#ifdef WITH_OSL
|
||||
/* So no context pollution happens from indirectly included windows.h */
|
||||
# include "util/util_windows.h"
|
||||
# include "util/windows.h"
|
||||
# include <OSL/oslexec.h>
|
||||
#endif
|
||||
|
||||
@@ -39,27 +39,27 @@
|
||||
#include "kernel/device/cpu/compat.h"
|
||||
#include "kernel/device/cpu/globals.h"
|
||||
#include "kernel/device/cpu/kernel.h"
|
||||
#include "kernel/kernel_types.h"
|
||||
#include "kernel/types.h"
|
||||
|
||||
#include "kernel/osl/osl_shader.h"
|
||||
#include "kernel/osl/osl_globals.h"
|
||||
#include "kernel/osl/shader.h"
|
||||
#include "kernel/osl/globals.h"
|
||||
// clang-format on
|
||||
|
||||
#include "bvh/bvh_embree.h"
|
||||
#include "bvh/embree.h"
|
||||
|
||||
#include "render/buffers.h"
|
||||
#include "session/buffers.h"
|
||||
|
||||
#include "util/util_debug.h"
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_function.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/util_map.h"
|
||||
#include "util/util_openimagedenoise.h"
|
||||
#include "util/util_optimization.h"
|
||||
#include "util/util_progress.h"
|
||||
#include "util/util_system.h"
|
||||
#include "util/util_task.h"
|
||||
#include "util/util_thread.h"
|
||||
#include "util/debug.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/function.h"
|
||||
#include "util/log.h"
|
||||
#include "util/map.h"
|
||||
#include "util/openimagedenoise.h"
|
||||
#include "util/optimization.h"
|
||||
#include "util/progress.h"
|
||||
#include "util/system.h"
|
||||
#include "util/task.h"
|
||||
#include "util/thread.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
/* So ImathMath is included before our kernel_cpu_compat. */
|
||||
#ifdef WITH_OSL
|
||||
/* So no context pollution happens from indirectly included windows.h */
|
||||
# include "util/util_windows.h"
|
||||
# include "util/windows.h"
|
||||
# include <OSL/oslexec.h>
|
||||
#endif
|
||||
|
||||
@@ -29,15 +29,15 @@
|
||||
|
||||
#include "device/cpu/kernel.h"
|
||||
#include "device/device.h"
|
||||
#include "device/device_memory.h"
|
||||
#include "device/memory.h"
|
||||
|
||||
// clang-format off
|
||||
#include "kernel/device/cpu/compat.h"
|
||||
#include "kernel/device/cpu/kernel.h"
|
||||
#include "kernel/device/cpu/globals.h"
|
||||
|
||||
#include "kernel/osl/osl_shader.h"
|
||||
#include "kernel/osl/osl_globals.h"
|
||||
#include "kernel/osl/shader.h"
|
||||
#include "kernel/osl/globals.h"
|
||||
// clang-format on
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "device/cpu/kernel_function.h"
|
||||
#include "util/util_types.h"
|
||||
#include "util/types.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -16,8 +16,8 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "util/util_debug.h"
|
||||
#include "util/util_system.h"
|
||||
#include "util/debug.h"
|
||||
#include "util/system.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -17,11 +17,11 @@
|
||||
#include "device/cpu/kernel_thread_globals.h"
|
||||
|
||||
// clang-format off
|
||||
#include "kernel/osl/osl_shader.h"
|
||||
#include "kernel/osl/osl_globals.h"
|
||||
#include "kernel/osl/shader.h"
|
||||
#include "kernel/osl/globals.h"
|
||||
// clang-format on
|
||||
|
||||
#include "util/util_profiling.h"
|
||||
#include "util/profiling.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -16,14 +16,14 @@
|
||||
|
||||
#include "device/cuda/device.h"
|
||||
|
||||
#include "util/util_logging.h"
|
||||
#include "util/log.h"
|
||||
|
||||
#ifdef WITH_CUDA
|
||||
# include "device/cuda/device_impl.h"
|
||||
# include "device/device.h"
|
||||
|
||||
# include "util/util_string.h"
|
||||
# include "util/util_windows.h"
|
||||
# include "util/string.h"
|
||||
# include "util/windows.h"
|
||||
#endif /* WITH_CUDA */
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -16,8 +16,8 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "util/util_string.h"
|
||||
#include "util/util_vector.h"
|
||||
#include "util/string.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -24,19 +24,17 @@
|
||||
|
||||
# include "device/cuda/device_impl.h"
|
||||
|
||||
# include "render/buffers.h"
|
||||
|
||||
# include "util/util_debug.h"
|
||||
# include "util/util_foreach.h"
|
||||
# include "util/util_logging.h"
|
||||
# include "util/util_map.h"
|
||||
# include "util/util_md5.h"
|
||||
# include "util/util_path.h"
|
||||
# include "util/util_string.h"
|
||||
# include "util/util_system.h"
|
||||
# include "util/util_time.h"
|
||||
# include "util/util_types.h"
|
||||
# include "util/util_windows.h"
|
||||
# include "util/debug.h"
|
||||
# include "util/foreach.h"
|
||||
# include "util/log.h"
|
||||
# include "util/map.h"
|
||||
# include "util/md5.h"
|
||||
# include "util/path.h"
|
||||
# include "util/string.h"
|
||||
# include "util/system.h"
|
||||
# include "util/time.h"
|
||||
# include "util/types.h"
|
||||
# include "util/windows.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
# include "device/cuda/util.h"
|
||||
# include "device/device.h"
|
||||
|
||||
# include "util/util_map.h"
|
||||
# include "util/map.h"
|
||||
|
||||
# ifdef WITH_CUDA_DYNLOAD
|
||||
# include "cuew.h"
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
|
||||
#ifdef WITH_CUDA
|
||||
|
||||
# include "device/device_graphics_interop.h"
|
||||
# include "device/graphics_interop.h"
|
||||
|
||||
# ifdef WITH_CUDA_DYNLOAD
|
||||
# include "cuew.h"
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
#ifdef WITH_CUDA
|
||||
|
||||
# include "device/device_kernel.h"
|
||||
# include "device/kernel.h"
|
||||
|
||||
# ifdef WITH_CUDA_DYNLOAD
|
||||
# include "cuew.h"
|
||||
|
||||
@@ -18,9 +18,9 @@
|
||||
|
||||
#ifdef WITH_CUDA
|
||||
|
||||
# include "device/device_kernel.h"
|
||||
# include "device/device_memory.h"
|
||||
# include "device/device_queue.h"
|
||||
# include "device/kernel.h"
|
||||
# include "device/memory.h"
|
||||
# include "device/queue.h"
|
||||
|
||||
# include "device/cuda/util.h"
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "device/device_denoise.h"
|
||||
#include "device/denoise.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -16,9 +16,9 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "device/device_memory.h"
|
||||
#include "device/memory.h"
|
||||
#include "graph/node.h"
|
||||
#include "render/buffers.h"
|
||||
#include "session/buffers.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
#include "bvh/bvh2.h"
|
||||
|
||||
#include "device/device.h"
|
||||
#include "device/device_queue.h"
|
||||
#include "device/queue.h"
|
||||
|
||||
#include "device/cpu/device.h"
|
||||
#include "device/cuda/device.h"
|
||||
@@ -29,15 +29,15 @@
|
||||
#include "device/multi/device.h"
|
||||
#include "device/optix/device.h"
|
||||
|
||||
#include "util/util_foreach.h"
|
||||
#include "util/util_half.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/util_math.h"
|
||||
#include "util/util_string.h"
|
||||
#include "util/util_system.h"
|
||||
#include "util/util_time.h"
|
||||
#include "util/util_types.h"
|
||||
#include "util/util_vector.h"
|
||||
#include "util/foreach.h"
|
||||
#include "util/half.h"
|
||||
#include "util/log.h"
|
||||
#include "util/math.h"
|
||||
#include "util/string.h"
|
||||
#include "util/system.h"
|
||||
#include "util/time.h"
|
||||
#include "util/types.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -71,14 +71,12 @@ void Device::build_bvh(BVH *bvh, Progress &progress, bool refit)
|
||||
|
||||
Device *Device::create(const DeviceInfo &info, Stats &stats, Profiler &profiler)
|
||||
{
|
||||
#ifdef WITH_MULTI
|
||||
if (!info.multi_devices.empty()) {
|
||||
/* Always create a multi device when info contains multiple devices.
|
||||
* This is done so that the type can still be e.g. DEVICE_CPU to indicate
|
||||
* that it is a homogeneous collection of devices, which simplifies checks. */
|
||||
return device_multi_create(info, stats, profiler);
|
||||
}
|
||||
#endif
|
||||
|
||||
Device *device = NULL;
|
||||
|
||||
|
||||
@@ -19,21 +19,21 @@
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#include "bvh/bvh_params.h"
|
||||
#include "bvh/params.h"
|
||||
|
||||
#include "device/device_denoise.h"
|
||||
#include "device/device_memory.h"
|
||||
#include "device/denoise.h"
|
||||
#include "device/memory.h"
|
||||
|
||||
#include "util/util_function.h"
|
||||
#include "util/util_list.h"
|
||||
#include "util/util_logging.h"
|
||||
#include "util/util_stats.h"
|
||||
#include "util/util_string.h"
|
||||
#include "util/util_texture.h"
|
||||
#include "util/util_thread.h"
|
||||
#include "util/util_types.h"
|
||||
#include "util/util_unique_ptr.h"
|
||||
#include "util/util_vector.h"
|
||||
#include "util/function.h"
|
||||
#include "util/list.h"
|
||||
#include "util/log.h"
|
||||
#include "util/stats.h"
|
||||
#include "util/string.h"
|
||||
#include "util/texture.h"
|
||||
#include "util/thread.h"
|
||||
#include "util/types.h"
|
||||
#include "util/unique_ptr.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
#include "device/dummy/device.h"
|
||||
|
||||
#include "device/device.h"
|
||||
#include "device/device_queue.h"
|
||||
#include "device/queue.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -16,8 +16,8 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "util/util_string.h"
|
||||
#include "util/util_vector.h"
|
||||
#include "util/string.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "device/device_graphics_interop.h"
|
||||
#include "device/graphics_interop.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -16,9 +16,9 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "render/display_driver.h"
|
||||
#include "session/display_driver.h"
|
||||
|
||||
#include "util/util_types.h"
|
||||
#include "util/types.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -16,14 +16,14 @@
|
||||
|
||||
#include "device/hip/device.h"
|
||||
|
||||
#include "util/util_logging.h"
|
||||
#include "util/log.h"
|
||||
|
||||
#ifdef WITH_HIP
|
||||
# include "device/device.h"
|
||||
# include "device/hip/device_impl.h"
|
||||
|
||||
# include "util/util_string.h"
|
||||
# include "util/util_windows.h"
|
||||
# include "util/string.h"
|
||||
# include "util/windows.h"
|
||||
#endif /* WITH_HIP */
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -16,8 +16,8 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "util/util_string.h"
|
||||
#include "util/util_vector.h"
|
||||
#include "util/string.h"
|
||||
#include "util/vector.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -24,20 +24,18 @@
|
||||
|
||||
# include "device/hip/device_impl.h"
|
||||
|
||||
# include "render/buffers.h"
|
||||
|
||||
# include "util/util_debug.h"
|
||||
# include "util/util_foreach.h"
|
||||
# include "util/util_logging.h"
|
||||
# include "util/util_map.h"
|
||||
# include "util/util_md5.h"
|
||||
# include "util/util_opengl.h"
|
||||
# include "util/util_path.h"
|
||||
# include "util/util_string.h"
|
||||
# include "util/util_system.h"
|
||||
# include "util/util_time.h"
|
||||
# include "util/util_types.h"
|
||||
# include "util/util_windows.h"
|
||||
# include "util/debug.h"
|
||||
# include "util/foreach.h"
|
||||
# include "util/log.h"
|
||||
# include "util/map.h"
|
||||
# include "util/md5.h"
|
||||
# include "util/opengl.h"
|
||||
# include "util/path.h"
|
||||
# include "util/string.h"
|
||||
# include "util/system.h"
|
||||
# include "util/time.h"
|
||||
# include "util/types.h"
|
||||
# include "util/windows.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
|
||||
@@ -21,12 +21,12 @@
|
||||
# include "device/hip/queue.h"
|
||||
# include "device/hip/util.h"
|
||||
|
||||
# include "util/util_map.h"
|
||||
# include "util/map.h"
|
||||
|
||||
# ifdef WITH_HIP_DYNLOAD
|
||||
# include "hipew.h"
|
||||
# else
|
||||
# include "util/util_opengl.h"
|
||||
# include "util/opengl.h"
|
||||
# endif
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
|
||||
#ifdef WITH_HIP
|
||||
|
||||
# include "device/device_graphics_interop.h"
|
||||
# include "device/graphics_interop.h"
|
||||
|
||||
# ifdef WITH_HIP_DYNLOAD
|
||||
# include "hipew.h"
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
#ifdef WITH_HIP
|
||||
|
||||
# include "device/device_kernel.h"
|
||||
# include "device/kernel.h"
|
||||
|
||||
# ifdef WITH_HIP_DYNLOAD
|
||||
# include "hipew.h"
|
||||
|
||||
@@ -18,9 +18,9 @@
|
||||
|
||||
#ifdef WITH_HIP
|
||||
|
||||
# include "device/device_kernel.h"
|
||||
# include "device/device_memory.h"
|
||||
# include "device/device_queue.h"
|
||||
# include "device/kernel.h"
|
||||
# include "device/memory.h"
|
||||
# include "device/queue.h"
|
||||
|
||||
# include "device/hip/util.h"
|
||||
|
||||
|
||||
@@ -14,9 +14,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "device/device_kernel.h"
|
||||
#include "device/kernel.h"
|
||||
|
||||
#include "util/util_logging.h"
|
||||
#include "util/log.h"
|
||||
|
||||
CCL_NAMESPACE_BEGIN
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user