Commit Graph

3476 Commits

Author SHA1 Message Date
Lukas Toenne
795fa1f199 Fix #36437 Cycles no longer rendering Emitter object (Particle Systems). The change r58999 was ignoring the "show_emitter" setting by particles (the result would be the same as long as hair was not
used). If particle emitters are forced to show all other of the usual duplicator hiding should be disabled.
2013-08-12 06:53:17 +00:00
Thomas Dinges
9dfd2823c4 Code cleanup / Cycles:
* Remove unused "PathThroughput" variable.
* Don't compile unused voronoi code, we only use Distance Squared atm. 
* Various typo and comment fixes.
2013-08-11 16:55:24 +00:00
Thomas Dinges
48ae40ccdf Code cleanup / Cycles:
* Rename "curve_kernel_data" to just "curve", to avoid redundant naming.
2013-08-11 15:27:04 +00:00
Thomas Dinges
30f279be26 Code cleanup / Cycles:
* Remove code for the unused Wave texture variations. 

We have quite some unused code in the texture area, I guess it doesn't harm to clean a bit up here. 
We can always get the code back from SVN if we need something.
2013-08-10 00:52:57 +00:00
Thomas Dinges
743a7a4a4b Cycles:
* GPU kernel can now be compiled without __NON_PROGRESSIVE__ again, was broken after my last commit. Also add a check for have_error(), in case the GPU kernel comes without Non-Progressive, to avoid a crash.

* Don't compile progressive kernel twice on CPU, if __NON_PROGRESSIVE__ would be disabled there.
2013-08-09 20:03:49 +00:00
Brecht Van Lommel
be7b4e26b1 Fix cycles not rendering with 1x1 resolution anymore, not so common for users
but nice for debugging.
2013-08-09 19:55:46 +00:00
Brecht Van Lommel
fd263bf725 Fix cycles passes UI panel to line up better. 2013-08-09 19:55:45 +00:00
Thomas Dinges
a18112249d Cycles / Non-Progressive integrator:
* Non-Progressive integrator is now available on the GPU (CUDA, sm_20 and above). 

Implementation details:
* kernel_path_trace() has been split up into two functions:
kernel_path_trace_non_progressive() and kernel_path_trace_progressive().

* We compile two CUDA kernel entry functions (in kernel.cu) for the two integrators, they are still inside one .cubin file but due to the kernel separation there should be no performance problem. I tested with the BMW file on my Geforce 540M and the render times were the same for 100 samples (1.57 min in my case).

This is part of my GSoC project, SVN merge of r59032 + manual merge of UI changes for this from my branch.
2013-08-09 18:47:25 +00:00
Brecht Van Lommel
9d9c64582b Fix #36355: cycles render of objects with both duplis and hair would not render
the hair in some cases.
2013-08-07 19:02:15 +00:00
Campbell Barton
4f29aeeff2 code cleanup: some structs were declaring data when only typedef's were intended, make local vars and functions static. 2013-08-07 03:44:05 +00:00
Thomas Dinges
da4679f6d8 * Make MSVC happy. 2013-08-06 23:47:47 +00:00
Campbell Barton
d58a385084 minor edits to float/double conversion suggested by DingTo 2013-08-06 23:34:47 +00:00
Campbell Barton
81acaf5f15 quiet double-promotion warnings, change octree.cpp to use a float (vector accumulated into a float anyway) 2013-08-06 06:38:52 +00:00
Campbell Barton
34c64b8ea3 cycles builds with -Wdouble-promotion again. 2013-08-06 06:36:34 +00:00
Campbell Barton
ce2e2b141e use gcc malloc attribute for low level allocation functions, prevents gcc from checking if resulting pointers alias existing pointers, also use sentinel attribute for uiButGetStrInfo so incorrect usage gives a warning. 2013-08-05 20:57:13 +00:00
Brecht Van Lommel
d01fbce3bb Fix #36380: cycles render error with sun lamp that has object scale 0,0,0. 2013-08-05 14:22:07 +00:00
Brecht Van Lommel
3bf175f270 Cycles OSL: image texture lookup optimization, acquire the per thread handle
for texture system in advance. Patch by Martijn Berger, with some tweaks.

There was about a 10% performance improvement on OS X in my tests with the
images.blend test file. This may be less on other platforms because OS X has
particularly slow mutex locks.
2013-08-05 12:49:15 +00:00
Brecht Van Lommel
28f893f23a Fix wrong cycles cmake + msvc build flags with relwithdebinfo and minsizerel.
Patch by Karsten Schwenk.
2013-08-05 12:02:43 +00:00
Thomas Dinges
d06fa3ba2b Code cleanup / Cycles:
* Various string and comment fixes.
2013-08-05 01:24:41 +00:00
Campbell Barton
41721e11fb fix for 2 memory leaks in dualcon library, quite bad since they leaked on every evaluation. 2013-08-04 18:05:29 +00:00
Campbell Barton
35db9c5e70 Support WITH_CXX_GUARDEDALLOC for dualcon library 2013-08-04 17:58:17 +00:00
Thomas Dinges
c26754fe9d Cycles / OpenCL:
* Was broken after Blackbody merge, forgot to rename a struct...
2013-08-04 12:40:46 +00:00
Campbell Barton
a270481239 add missing NULL check in RB_dworld_export if fopen fails. 2013-08-04 04:30:14 +00:00
Campbell Barton
bd89bd9e1c avoid using MEM_reallocN_id directly, add utility macro for freeing. 2013-08-04 03:00:04 +00:00
Thomas Dinges
02ec0b9431 Cycles:
* Forgot to rename some SSS pass strings.
* Some typo fixes.
2013-08-03 21:45:57 +00:00
Campbell Barton
2a8d76d734 add versions of MEM_reallocN, MEM_recallocN which take a string arg so new allocs have an ID, changing existing functions signatures would be too disruptive at the moment. 2013-08-03 17:53:41 +00:00
Thomas Dinges
5fc6f04fc8 Cycles / SSS:
* Render Passes are now available for Subsurface Scattering (Direct, Indirect and Color pass). 

This is part of my GSoC project, SVN merge of r58587, r58828 and r58835.
2013-08-03 13:12:09 +00:00
Thomas Dinges
702bf77b34 Cycles / Squared Samples:
* After some feedback decided to remove this option from the Progressive integrator, it only makes sense for Non-Progressive where we have different values for the sample types.
2013-07-31 22:51:48 +00:00
Antony Riakiotakis
ac8e379a87 Fix linking issue, we use bundled static glew so we should define static glew in ghost as well. 2013-07-31 22:39:17 +00:00
Thomas Dinges
e48acb7dec Code cleanup, use bools here. Forgot to change that. 2013-07-31 21:40:52 +00:00
Thomas Dinges
2a2f0319bc Cycles / HSV Separator and Combine node:
* Added nodes to separate and combine hsv colors.

Part of my GSoC 2013 project, SVN merge of r57981.
2013-07-31 21:27:48 +00:00
Thomas Dinges
34009da32e Cycles / Vector Transform node:
* Add a note to convert a Vector, Point or Normal between World <=> Camera <=> Object coordinate space. 

Documentation: http://wiki.blender.org/index.php/Doc:2.6/Manual/Render/Cycles/Nodes/More#Vector_Transform

Part of my GSoC 2013 project, SVN merge of r57599, r57670, r57918, r57919, r58245 and r58775.
2013-07-31 21:18:23 +00:00
Thomas Dinges
6d9720ef63 Cycles / Blackbody to RGB node:
* Added a node to convert a temperature in Kelvin to an RGB color. This can be used e.g. for lights, to easily find the right color temperature. 
= Some common temperatures =
Candle light: 1500 Kelvin
Sunset/Sunrise: 1850 Kelvin
Studio lamps: 3200 Kelvin
Horizon daylight: 5000 Kelvin

Documentation: http://wiki.blender.org/index.php/Doc:2.6/Manual/Render/Cycles/Nodes/More#Blackbody

Thanks to Philipp Oeser (lichtwerk), who essentially contributed to this with a patch! :)

This is part of my GSoC 2013 project. SVN merge of r57424, r57487, r57507, r57525, r58253 and r58774
2013-07-31 20:56:32 +00:00
Thomas Dinges
3840e0b234 Cycles / Ray Depth:
* Added a Ray Depth output to the Light Path node, which gives the user access to the current bounce.
This can be used to limit the maximum ray bounce on a per shader basis. Another use case is to restrict light influence with this, to have a lamp only contribute to the direct lighting. 

http://wiki.blender.org/index.php/Doc:2.6/Manual/Render/Cycles/Nodes/More#Light_Path

This is part of my GSoC 2013 project. SVN merge of r58091 and r58772 from soc-2013-dingto.
2013-07-31 20:30:37 +00:00
Thomas Dinges
3d57740a38 Cycles / Non-Progressive integrator:
* Avoid check for !LABEL_TRANSPARENT in "kernel_path_non_progressive_lighting", transparency is either handled in the outer loop or in the "kernel_path_indirect" function, but not here.
2013-07-30 12:56:39 +00:00
Thomas Dinges
5ce3588c6c Cycles:
* Increase the maximum amount of closures per shader from 16 to 64, so more complex closure trees can be rendered.

I measured performance on CPU and GPU (Geforce 540M) and couldn't find a performance impact, but if someone encounters a noticeable impact on his system, please report.
2013-07-30 09:26:45 +00:00
Mitchell Stokes
29f8dfd37a BGE: Adding vsync control. Users can enable vsync, disable vsync, or use adaptive vsync via UI options in the render properties, or by using the new Python method bge.render.setVsync(). Win32 and X11 support are done via EXT_swap_control. Support for using EXT_swap_control on OS X still needs to be added to Ghost. 2013-07-29 22:31:32 +00:00
Brecht Van Lommel
c0875290bc Fix #36290: cycles generated texture coordinates were not sticking to the
surface again, got lost in an unrelated optimization.
2013-07-29 19:39:23 +00:00
Brecht Van Lommel
6135a7adc8 Fix #36235: cycles crash deactivating render layer during rendering. 2013-07-29 15:32:24 +00:00
Thomas Dinges
965e0aeb59 Cycles / CMJ:
* path_rng_2D() was missing an else branch for the sobol case after fix in r57383.
2013-07-23 16:23:30 +00:00
Campbell Barton
b8c3efc8c3 code cleanup: compiler warnings 2013-07-21 16:40:34 +00:00
Thomas Dinges
636b314677 Code cleanup / Cycles:
* Remove useless else branch, after recent changes.
2013-07-21 10:30:22 +00:00
Thomas Dinges
9732c6283e Cycles / CPU Rendering:
* "Auto Detect" now again uses the umber of cores, instead number of cores + 1.

This was added before we had Tile rendering and benchmarks on several systems showed that there is no gain with this now. There might be some slight difference (0.5% or so) slower/faster depending on the scene, but this is negligible.
2013-07-20 00:40:03 +00:00
Campbell Barton
a2a99bbc17 edit to r58425, BLI_math is available here, better not copy,paste from linearrgb_to_srgb.
also remove redundant check in AUD_FFMPEGReader::seek.
2013-07-20 00:35:41 +00:00
Thomas Dinges
ac1d58d962 Cycles / Sampling Presets:
* Add Presets for Sampling. This comes with a simple Preview and Final preset, but as this is varying a lot depending on the scene, they should just be a starting point. The user can add own presets here.

* Some UI layout changes to match the settings a bit better.
2013-07-19 23:59:40 +00:00
Thomas Dinges
51a3371d87 Code cleanup / Cycles:
* Use USHRT_MAX rather than manual value, suggested by Campbell.
2013-07-19 22:56:54 +00:00
Thomas Dinges
d336ae8992 Cycles / Sampling UI:
* Add a "Squared Samples" option to the UI, to use squared values for ease of use. This can make it easier from an artist point of view, to weak settings. 

With this enabled, all Sample values will be squared. So 10 Samples become 100 Samples.
For the Non-Progressive integrator: 4 AA Samples * 5 Diffuse Samples would become 16 AA Samples * 25 Diffuse = 400 in total.

Patch by Matt Heimlich, with some minor edits by myself. Thanks!
2013-07-19 22:51:48 +00:00
Thomas Dinges
fd1d4151f1 Fix for [#36216] Viewport render with CMJ sampler and unlimited passes freezes
* If Preview Samples are set to 0 (unlimited) it now assumes 65536 instead of INT_MAX. 

This doesn't affect regular sampling, you can still enter fixed values of 100k or whatever.
2013-07-19 14:00:53 +00:00
Campbell Barton
824ec5a388 code cleanup: case & brace placement 2013-07-19 10:40:43 +00:00
Campbell Barton
cbe43fd385 code cleanup: pass event by pointer to getClipboard_xcout 2013-07-19 10:40:27 +00:00