Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2017-02-15Cycles: Fix wrong hair render results when using BVH motion stepsSergey Sharybin
The issue here was mainly coming from minimal pixel width feature which is quite commonly enabled in production shots. This feature will use some probabilistic heuristic in the curve intersection function to check whether we need to return intersection or not. This probability is calculated for every intersection check. Now, when we use multiple BVH nodes for curve primitives we increase probability of that primitive to be considered a good intersection for us. This is similar to increasing minimal width of curve. What is worst here is that change in the intersection probability fully depends on exact layout of BVH, meaning probability might change differently depending on a view angle, the way how builder binned the primitives and such. This makes it impossible to do simple check like dividing probability by number of BVH steps. Other solution might have been to split BVH into fully independent trees, but that will increase memory usage of all the static objects in the scenes, which is also not something desirable. For now used most simple but robust approach: store BVH primitives time and test it in curve intersection functions. This solves the regression, but has two downsides: - Uses more memory. which isn't surprising, and ANY solution to this problem will use more memory. What we still have to do is to avoid this memory increase for cases when we don't use BVH motion steps. - Reduces number of maximum available textures on pre-kepler cards. There is not much we can do here, hardware gets old but we need to move forward on more modern hardware..
2016-08-15Fix Cycles OpenCL textures after recent CUDA fix.Brecht Van Lommel
kernel_textures.h is included in device_opencl.cpp, so we can't check __KERNEL_OPENCL__ there.
2016-08-15Fix CUDA compilation after OpenCL changes.Thomas Dinges
2016-08-14Cycles: Add single channel texture support for OpenCL.Thomas Dinges
This way OpenCL devices can also benefit from a smaller memory footprint, when using e.g. bumpmaps (greyscale, 1 channel). Additional target for my GSoC 2016.
2016-07-29Cycles microdisplacement: ngons and attributes for subdivision meshesMai Lavelle
This adds support for ngons and attributes on subdivision meshes. Ngons are needed for proper attribute interpolation as well as correct Catmull-Clark subdivision. Several changes are made to achieve this: - new primitive `SubdFace` added to `Mesh` - 3 more textures are used to store info on patches from subd meshes - Blender export uses loop interface instead of tessface for subd meshes - `Attribute` class is updated with a simplified way to pass primitive counts around and to support ngons. - extra points for ngons are generated for O(1) attribute interpolation - curves are temporally disabled on subd meshes to avoid various bugs with implementation - old unneeded code is removed from `subd/` - various fixes and improvements Reviewed By: brecht Differential Revision: https://developer.blender.org/D2108
2016-07-07Cycles: Reduce memory usage by de-duplicating triangle storageSergey Sharybin
There are several internal changes for this: First idea is to make __tri_verts to behave similar to __tri_storage, meaning, __tri_verts array now contains all vertices of all triangles instead of just mesh vertices. This saves some lookup when reading triangle coordinates in functions like triangle_normal(). In order to make it efficient needed to store global triangle offset somewhere. So no __tri_vindex.w contains a global triangle index which can be used to read triangle vertices. Additionally, the order of vertices in that array is aligned with primitives from BVH. This is needed to keep cache as much coherent as possible for BVH traversal. This causes some extra tricks needed to fill the array in and deal with True Displacement but those trickery is fully required to prevent noticeable slowdown. Next idea was to use this __tri_verts instead of __tri_storage in intersection code. Unfortunately, this is quite tricky to do without noticeable speed loss. Mainly this loss is caused by extra lookup happening to access vertex coordinate. Fortunately, tricks here and there (i,e, some types changes to avoid casts which are not really coming for free) reduces those losses to an acceptable level. So now they are within couple of percent only, On a positive site we've achieved: - Few percent of memory save with triangle-only scenes. Actual save in this case is close to size of all vertices. On a more fine-subdivided scenes this benefit might become more obvious. - Huge memory save of hairy scenes. For example, on koro.blend there is about 20% memory save. Similar figure for bunny.blend. This memory save was the main goal of this commit to move forward with Hair BVH which required more memory per BVH node. So while this sounds exciting, this memory optimization will become invisible by upcoming Hair BVH work. But again on a positive side, we can add an option to NOT use Hair BVH and then we'll have same-ish render times as we've got currently but will have this 20% memory benefit on hairy scenes.
2016-05-19Cycles: Add support for bindless textures.Thomas Dinges
This adds support for CUDA Texture objects (also known as Bindless textures) for Kepler GPUs (Geforce 6xx and above). This is used for all 2D/3D textures, data still uses arrays as before. User benefits: * No more limits of image textures on Kepler. We had 5 float4 and 145 byte4 slots there before, now we have 1024 float4 and 1024 byte4. This can be extended further if we need to (just change the define). * Single channel textures slots (byte and float) are now supported on Kepler as well (1024 slots for each type). ToDo / Issues: * 3D textures don't work yet, at least don't show up during render. I have no idea whats wrong yet. * Dynamically allocate bindless_mapping array? I hope Fermi still works fine, but that should be tested on a Fermi card before pushing to master. Part of my GSoC 2016. Reviewers: sergey, #cycles, brecht Subscribers: swerner, jtheninja, brecht, sergey Differential Revision: https://developer.blender.org/D1999
2016-05-10Cycles: Add support for float4 textures on OpenCL.Thomas Dinges
Title says it all, this adds OpenCL float4 texture support. There is a bug in the code still, I get a "Out of ressources error" on nvidia hardware here, not sure whats wrong yet. Will investigate further, but maybe someone else has an idea. :) Reviewers: #cycles, brecht Subscribers: brecht, candreacchio Differential Revision: https://developer.blender.org/D1983
2016-05-09Cleanup: More byte -> byte4 renaming for consistency.Thomas Dinges
2016-05-06Cleanup: Rename texture slots to float4 and byte, to distinguish from future ↵Thomas Dinges
float (single channel) and half_float slots. Should be no functional changes, tested CPU and CUDA.
2016-04-11Cycles: Rename tri_woop to tri_storageSergey Sharybin
It's no longer a pre-computed data and just a storage of triangle coordinates which are faster to access to.
2016-03-25Cycles: Cleanup, indent nested preprocessor directivesSergey Sharybin
Quite straightforward, main trick is happening in path_source_replace_includes(). Reviewers: brecht, dingto, lukasstockner97, juicyfruit Differential Revision: https://developer.blender.org/D1794
2016-02-15Cycles: Initial support of 3D textures for CUDA renderingSergey Sharybin
Supports both smoke/fire and point density textures now. Reduces number of textures available for sm_20 and sm_21, but you have to compromise somewhere on such a limited hardware. Currently limited to linear interpolation only, and decoupled ray marching is not supported yet. Think those could be considered just a further improvement. Some quick example: https://developer.blender.org/F282934 Code is minimal and we can fully consider it a fix for missing support of 3D textures with CUDA. Reviewers: lukasstockner97, brecht, juicyfruit, dingto Reviewed By: brecht, juicyfruit, dingto Subscribers: mib2berlin Differential Revision: https://developer.blender.org/D1806
2015-04-20Cycles: Split BVH nodes storage into inner and leaf nodesSergey Sharybin
This way we can get rid of inefficient memory usage caused by BVH boundbox part being unused by leaf nodes but still being allocated for them. Doing such split allows to save 6 of float4 values for QBVH per leaf node and 3 of float4 values for regular BVH per leaf node. This translates into following memory save using 01.01.01.G rendered without hair: Device memory size Device memory peak Global memory peak Before the patch: 4957 5051 7668 With the patch: 4467 4562 7332 The measurements are done against current master. Still need to run speed tests and it's hard to predict if it's faster or not: on the one hand leaf nodes are now much more coherent in cache, on the other hand they're not so much coherent with regular nodes anymore. Reviewers: brecht, juicyfruit Subscribers: venomgfx, eyecandy Differential Revision: https://developer.blender.org/D1236
2014-12-25Cleanup: Fix Cycles Apache header.Thomas Dinges
This was already mixed a bit, but the dot belongs there.
2014-09-24make "tri_shader" an int instead of a floatMartijn Berger
tri_shader does no longer need to a float. Reviewers: dingto, sergey Reviewed By: dingto, sergey Subscribers: dingto Projects: #cycles Differential Revision: https://developer.blender.org/D789
2014-07-02Cleanup: Update list and remove ifdef here.Thomas Dinges
2014-06-14Cycles: Add support for uchar4 attributes.Thomas Dinges
* Added support for uchar4 attributes to Cycles' attribute system. * This is used for Vertex Colors now, which saves some memory (4 unsigned characters, instead of 4 floats). * GPU Texture Limit on sm_20 and sm_21 decreased from 95 to 94, because we need a new texture for the uchar4 attributes. This is no problem for sm_30 or newer. Part of my GSoC 2014.
2014-06-13Cycles: Calculate face normal on the fly.Thomas Dinges
Instead of pre-calculation and storage, we now calculate the face normal during render. This gives a small slowdown (~1%) but decreases memory usage, which is especially important for GPUs, where you have limited VRAM. Part of my GSoC 2014.
2014-05-11Quiet warnings with __CUDA_ARCH__ useCampbell Barton
2014-05-11Cycles / CUDA: Increase maximum image textures on GPU.Thomas Dinges
Instead of 95, we can use 145 images now. This only affects Kepler and above (sm30, sm_35 and sm_50). This can be increased further if needed, but let's first test if this does not come with a performance impact. Originally developed during my GSoC 2013.
2014-03-29Cycles code refactor: changes to make adding new primitive types easier.Brecht Van Lommel
2013-08-18Cycles: relicense GNU GPL source code to Apache version 2.0.Brecht Van Lommel
More information in this post: http://code.blender.org/ Thanks to all contributes for giving their permission!
2013-04-02Cycles: code refactoring to add generic lookup table memory.Brecht Van Lommel
2013-01-03Cycles Hair: refactoring to store curves with the index of the first key and theBrecht Van Lommel
number of keys in the curve, rather than curve segments with the indices of two keys. ShaderData.segment now stores the segment number in the curve.
2013-01-03Cycles Hair: refactoring to support generic attributes for hair curves. ThereBrecht Van Lommel
should be no functional changes yet. UV, tangent and intercept are now stored as attributes, with the intention to add more like multiple uv's, vertex colors, generated coordinates and motion vectors later. Things got a bit messy due to having both triangle and curve data in the same mesh data structure, which also gives us two sets of attributes. This will get cleaned up when we split the mesh class.
2012-12-28New featureStuart Broadfoot
Patch [#33445] - Experimental Cycles Hair Rendering (CPU only) This patch allows hair data to be exported to cycles and introduces a new line segment primitive to render with. The UI appears under the particle tab and there is a new hair info node available. It is only available under the experimental feature set and for cpu rendering.
2012-12-20Cycles: reduce memory usage of instanced objects by about 40%, as long as theBrecht Van Lommel
motion vector pass is not enabled.
2012-09-04Cycles: merge of changes from tomato branch.Brecht Van Lommel
Regular rendering now works tiled, and supports save buffers to save memory during render and cache render results. Brick texture node by Thomas. http://wiki.blender.org/index.php/Doc:2.6/Manual/Render/Cycles/Nodes/Textures#Brick_Texture Image texture Blended Box Mapping. http://wiki.blender.org/index.php/Doc:2.6/Manual/Render/Cycles/Nodes/Textures#Image_Texture http://mango.blender.org/production/blended_box/ Various bug fixes by Sergey and Campbell. * Fix for reading freed memory in some node setups. * Fix incorrect memory read when synchronizing mesh motion. * Fix crash appearing when direct light usage is different on different layers. * Fix for vector pass gives wrong result in some circumstances. * Fix for wrong resolution used for rendering Render Layer node. * Option to cancel rendering when doing initial synchronization. * No more texture limit when using CPU render. * Many fixes for new tiled rendering.
2012-06-08Particle Info node for Cycles. This can be used to access particle ↵Lukas Toenne
information in material shaders for dupli objects. For now only the particle Age and individual Lifetime (in frames) are supported, more attributes can be added when needed. The particle data is stored in a separate texture if any of the dupli objects uses particle info nodes in shaders. To map dupli objects onto particles the store an additional particle_index value, which is different from the simple dupli object index (only visible particles, also works for particle dupli groups mode). Some simple use cases on the code.blender.org blog: http://code.blender.org/index.php/2012/05/particle-info-node/
2012-06-01Cycles:Thomas Dinges
* Added missing GPL licence block to kernel_textures.h
2012-05-13Cycles: OpenCL image texture support, fix an attribute node issue and refactorBrecht Van Lommel
feature enabling #defines a bit.
2012-05-02Fix #31168: cycles mask layer should only affect objects for camera rays.Brecht Van Lommel
Fix: texture coordinate normal output was not correct, still changed under object transform.
2012-03-07Cycles: float texture support. Due to GPU limitations there are now 95 byte,Brecht Van Lommel
and 5 float image textures. For CPU render this limit will be lifted later on with image cache support. Patch by Mike Farnsworth. Also changed color space option in image/environment texture node, to show options Color and Non-Color Data, instead of sRGB and Linear, this is more descriptive, and it was not really correct to equate Non-Color Data with Linear.
2012-01-20Sample as Lamp option for world shaders, to enable multiple importance sampling.Brecht Van Lommel
By default lighting from the world is computed solely with indirect light sampling. However for more complex environment maps this can be too noisy, as sampling the BSDF may not easily find the highlights in the environment map image. By enabling this option, the world background will be sampled as a lamp, with lighter parts automatically given more samples. Map Resolution specifies the size of the importance map (res x res). Before rendering starts, an importance map is generated by "baking" a grayscale image from the world shader. This will then be used to determine which parts of the background are light and so should receive more samples than darker parts. Higher resolutions will result in more accurate sampling but take more setup time and memory. Patch by Mike Farnsworth, thanks!
2011-09-28Cycles: internal changes that should have no effect on user level yet, addedBrecht Van Lommel
shader flags for various purposes, and some code for light types other than points.
2011-09-01Cycles:Brecht Van Lommel
* Add max diffuse/glossy/transmission bounces * Add separate min/max for transparent depth * Updated/added some presets that use these options * Add ray visibility options for objects, to hide them from camera/diffuse/glossy/transmission/shadow rays * Is singular ray output for light path node Details here: http://wiki.blender.org/index.php/Dev:2.5/Source/Render/Cycles/LightPaths
2011-08-28Cycles:Brecht Van Lommel
* Add alpha pass output, to use set Transparent option in Film panel. * Add Holdout closure (OSL terminology), this is like the Sky option in the internal renderer, objects with this closure show the background / zero alpha. * Add option to use Gaussian instead of Box pixel filter in the UI. * Remove camera response curves for now, they don't really belong here in the pipeline, should be moved to compositor. * Output full float values for rendering now, previously was only byte precision. * Add a patch from Thomas to get a preview passes option, but still disabled because it isn't quite working right yet. * CUDA: don't compile shader graph evaluation inline. * Convert tabs to spaces in python files.
2011-05-20Cycles: some steps to getting OpenCL backend to compile.Brecht Van Lommel