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-10-04Code refactor: remove rng_state buffer and compute hash on the fly.Brecht Van Lommel
A little faster on some benchmark scenes, a little slower on others, seems about performance neutral on average and saves a little memory.
2017-08-25Cycles: Correct logging of sued CPU intrisicsSergey Sharybin
2017-08-08Cycles: Pack kernel textures into buffers for OpenCLMai Lavelle
Image textures were being packed into a single buffer for OpenCL, which limited the amount of memory available for images to the size of one buffer (usually 4gb on AMD hardware). By packing textures into multiple buffers that limit is removed, while simultaneously reducing the number of buffers that need to be passed to each kernel. Benchmarks were within 2%. Fixes T51554. Differential Revision: https://developer.blender.org/D2745
2017-08-07Code refactor: split defines into separate header, changes to SSE type headers.Brecht Van Lommel
I need to use some macros defined in util_simd.h for float3/float4, to emulate SSE4 instructions on SSE2. But due to issues with order of header includes this was not possible, this does some refactoring to make it work. Differential Revision: https://developer.blender.org/D2764
2017-07-05Cycles: Pass string by const reference rather than by valueSergey Sharybin
Some of the functions might have been inlined, but others i don't see how that was possible (don't think virtual functions can be inlined here). In any case, better be explicitly optimal in the code.
2017-07-03Cycles: Add missing split kernel to CPUDeviceLukas Stockner
2017-06-09Cycles Denoising: Merge outlier heuristic and confidence interval testLukas Stockner
The previous outlier heuristic only checked whether the pixel is more than twice as bright compared to the 75% quantile of the 5x5 neighborhood. While this detected fireflies robustly, it also incorrectly marked a lot of legitimate small highlights as outliers and filtered them away. This commit adds an additional condition for marking a pixel as a firefly: In addition to being above the reference brightness, the lower end of the 3-sigma confidence interval has to be below it. Since the lower end approximates how low the true value of the pixel might be, this test separates pixels that are supposed to be very bright from pixels that are very bright due to random fireflies. Also, since there is now a reliable outlier filter as a preprocessing step, the additional confidence interval test in the reconstruction kernel is no longer needed.
2017-05-20Cycles: Cleanup, style and unused argumentsSergey Sharybin
- Some arguments were inapproriatry tagged as unused using (void)foo semantic. Only use such semantic in tricky casses, when something needs to be ignored in release builds or something is dependent on tricky ifndef policy. For rest of the cases just use void foo(int /bar*/) semantic, which ensures variable is not used. Solves confusion and code running out of sync with later development. - Used proper unused semantic to some arguments. - Added braces to make code easier to follow, tricky indentation with ifdef, uh.
2017-05-18Cycles Denoising: Add more robust outlier heuristic to avoid artifactsLukas Stockner
Extremely bright pixels in the rendered image cause the denoising algorithm to produce extremely noticable artifacts. Therefore, a heuristic is needed to exclude these pixels from the filtering process. The new approach calculates the 75% percentile of the 5x5 neighborhood of each pixel and flags the pixel if it is more than twice as bright. During the reconstruction process, flagged pixels are skipped. Therefore, they don't cause any problems for neighboring pixels, and the outlier pixels themselves are replaced by a prediction of their actual value based on their feature pass values and the neighboring pixels. Therefore, the denoiser now also works as a smarter despeckling filter that uses a more accurate prediction of the pixel instead of a simple average. This can be used even if denoising isn't wanted by setting the denoising radius to 1.
2017-05-09Cycles: Properly free memory used by KernelGlobalsSergey Sharybin
Previous logic did not free memory used by vector classes which were storing images, causing memory leaks.
2017-05-07Cycles: Implement denoising option for reducing noise in the rendered imageLukas Stockner
This commit contains the first part of the new Cycles denoising option, which filters the resulting image using information gathered during rendering to get rid of noise while preserving visual features as well as possible. To use the option, enable it in the render layer options. The default settings fit a wide range of scenes, but the user can tweak individual settings to control the tradeoff between a noise-free image, image details, and calculation time. Note that the denoiser may still change in the future and that some features are not implemented yet. The most important missing feature is animation denoising, which uses information from multiple frames at once to produce a flicker-free and smoother result. These features will be added in the future. Finally, thanks to all the people who supported this project: - Google (through the GSoC) and Theory Studios for sponsoring the development - The authors of the papers I used for implementing the denoiser (more details on them will be included in the technical docs) - The other Cycles devs for feedback on the code, especially Sergey for mentoring the GSoC project and Brecht for the code review! - And of course the users who helped with testing, reported bugs and things that could and/or should work better!
2017-05-04Cycles: Fix crash when assigning KernelGlobalsLukas Stockner
The memory isn't initialized during allocation, so calling the assignment operator is a bad idea.
2017-04-07Cycles: Change work pool and global size of split CPU for easier debuggingMai Lavelle
2017-03-29Cycles: Make all #include statements relative to cycles source directorySergey Sharybin
The idea is to make include statements more explicit and obvious where the file is coming from, additionally reducing chance of wrong header being picked up. For example, it was not obvious whether bvh.h was refferring to builder or traversal, whenter node.h is a generic graph node or a shader node and cases like that. Surely this might look obvious for the active developers, but after some time of not touching the code it becomes less obvious where file is coming from. This was briefly mentioned in T50824 and seems @brecht is fine with such explicitness, but need to agree with all active developers before committing this. Please note that this patch is lacking changes related on GPU/OpenCL support. This will be solved if/when we all agree this is a good idea to move forward. Reviewers: brecht, lukasstockner97, maiself, nirved, dingto, juicyfruit, swerner Reviewed By: lukasstockner97, maiself, nirved, dingto Subscribers: brecht Differential Revision: https://developer.blender.org/D2586
2017-03-17Cycles: Silence strict compiler warningSergey Sharybin
2017-03-17Cycles: Improve memory usage of CPU split kernel by using smaller global sizeMai Lavelle
2017-03-11Fix T50888: Numeric overflow in split kernel state buffer size calculationMai Lavelle
Overflow led to the state buffer being too small and the split kernel to get stuck doing nothing forever.
2017-03-08Cycles: Fix indentationMai Lavelle
2017-03-08Cycles: Calculate size of split state buffer kernel sideMai Lavelle
By calculating the size of the state buffer in the kernel rather than the host less code is needed and the size actually reflects the requested features. Will also be a little faster in some cases because of larger global work size.
2017-03-08Cycles: Add names to buffer allocationsMai Lavelle
This is to help debug and track memory usage for generic buffers. We have similar for textures already since those require a name, but for buffers the name is only for debugging proposes.
2017-03-08Cycles: CPU implementation of split kernelMai Lavelle
2017-03-08Cycles: Allow device_memory to be used directlyMai Lavelle
This is useful for when theres no host side memory attched to the buffer
2016-12-03Cycles: Refactor Progress system to provide better estimatesLukas Stockner
The Progress system in Cycles had two limitations so far: - It just counted tiles, but ignored their size. For example, when rendering a 600x500 image with 512x512 tiles, the right 88x500 tile would count for 50% of the progress, although it only covers 15% of the image. - Scene update time was incorrectly counted as rendering time - therefore, the remaining time started very long and gradually decreased. This patch fixes both problems: First of all, the Progress now has a function to ignore time spans, and that is used to ignore scene update time. The larger change is the tile size: Instead of counting samples per tile, so that the final value is num_samples*num_tiles, the code now counts every sample for every pixel, so that the final value is num_samples*num_pixels. Along with that, some unused variables were removed from the Progress and Session classes. Reviewers: brecht, sergey, #cycles Subscribers: brecht, candreacchio, sergey Differential Revision: https://developer.blender.org/D2214
2016-05-31Cycles: Add human readable sizes to debug outputMai Lavelle
Some of these values can get quite large and are hard to read, adding this makes it easy to read them at a glance. Reviewed By: sergey Differential Revision: https://developer.blender.org/D2039
2016-05-18Cycles: Reduce amount of malloc() calls from the kernelSergey Sharybin
This commit makes it so malloc() is only happening once per volume and once per transparent shadow query (per thread), improving scalability of the code to multiple CPU cores. Hard to measure this with a low-bottom i7 here currently, but from quick tests seems volume sampling gave about 3-5% speedup. The idea is to store allocated memory in kernel globals, which are per thread on CPU already. Reviewers: dingto, juicyfruit, lukasstockner97, maiself, brecht Reviewed By: brecht Subscribers: Blendify, nutel Differential Revision: https://developer.blender.org/D1996
2016-05-11Cycles: Add support for single channel float textures on CPU.Thomas Dinges
Until now, single channel textures were packed into a float4, wasting 3 floats per pixel. Memory usage of such textures is now reduced by 3/4. Voxel Attributes such as density, flame and heat benefit from this, but also Bumpmaps with one channel. This commit also includes some cleanup and code deduplication for image loading. Example Smoke render from Cosmos Laundromat: http://www.pasteall.org/pic/show.php?id=102972 Memory here went down from ~600MB to ~300MB. Reviewers: #cycles, brecht Differential Revision: https://developer.blender.org/D1981
2016-05-09Cleanup: Avoid duplicative defines for CPU textures, use the ones from ↵Thomas Dinges
util_texture.h Also includes some further byte -> byte4 renaming, missed that in last commit.
2016-02-06Cycles: Re-implement some utilities to avoid use of boostSergey Sharybin
The title says it all actually, the idea is to make Cycles only requiring Boost via 3rd party dependencies like OIIO and OSL. So now there are only few places which still uses Boost: - Foreach, function bindings and threading primitives. Those we can easily get rid with C++11 bump (which seems inevitable sooner or later if we'll want ot use newer LLVM for OSL), - Networking devices There's no quick solution for those currently, but there are some patches around which improves serialization. Reviewers: juicyfruit, mont29, campbellbarton, brecht, dingto Reviewed By: brecht, dingto Differential Revision: https://developer.blender.org/D1764
2016-01-15Cycles-Bake: Custom Baking passesDalai Felinto
The combined pass is built with the contributions the user finds fit. It is useful for lightmap baking, as well as non-view dependent effects baking. The manual will be updated once we get closer to the 2.77 release. Meanwhile the new page can be found here: http://dalaifelinto.com/blender-manual/render/cycles/baking.html Reviewers: sergey, brecht Differential Revision: https://developer.blender.org/D1674
2016-01-12Cycles: Use special debug panel to fine-tune debug flagsSergey Sharybin
This panel is only visible when debug_value is set to 256 and has no affect in other cases. However, if debug value is not set to this value, environment variables will be used to control which features are enabled, so there's no visible changes to anyone in fact. There are some changes needed to prevent devices re-enumeration on every Cycles session create. Reviewers: juicyfruit, lukasstockner97, dingto, brecht Reviewed By: lukasstockner97, dingto Differential Revision: https://developer.blender.org/D1720
2016-01-06Cycles: Log whch optimizations are used for CPU kernelsSergey Sharybin
Not fully thread-safe, but is rather harmless. Just some messages might be logged several times.
2016-01-06Cycles: Fix stupid mistake which was assining kernel function in a loopSergey Sharybin
2015-12-30Cycles: Optionally output luminance from the shader evaluation kernelSergey Sharybin
This makes it possible to move some parts of evaluation from host to the device and hopefully reduce memory usage by avoid having full RGBA buffer on the host. Reviewers: juicyfruit, lukasstockner97, brecht Reviewed By: lukasstockner97, brecht Differential Revision: https://developer.blender.org/D1702
2015-07-28Cycles: Prepare for more image extension types supportSergey Sharybin
Basically just replace boolean periodic flag with extension type enum in the device API.
2015-07-21Cycles: Expose image image extension mapping to the image managerSergey Sharybin
Currently only two mappings are supported by API, which is Repeat (old behavior) and new Clip behavior. Internally this extension is being converted to periodic flag which was already supported but wasn't exposed. There's no support for OpenCL yet because of the way how we pack images into a single texture. Those settings are not exposed to UI or anywhere else and there should be no functional changes so far.
2015-04-10Cycles: Fix compilation error on windows after recent logging changesSergey Sharybin
2015-04-10Cycles: Add some statistics loggingSergey Sharybin
Covers number of entities in the scene (objects, meshes etc), also reports sizes of textures being allocated.
2015-03-27Cycles: Code cleanup, spaces around keywordsSergey Sharybin
This inconsistency drove me totally crazy, it's really confusing when it's inconsistent especially when you work on both Cycles and Blender sides. Shouldn;t cause merge PITA, it's whitespace changes only, Git should be able to merge it nicely.
2015-03-27Cycles: Code cleanup, prepare for strict C++ flagsSergey Sharybin
2015-02-19Cycles: Cleanup for indentation in device_cpu.cppSergey Sharybin
Perhaps became broken after rather recent change about which entry point to kernel to use.
2015-01-06Cycles: Repot CPU and CUDA capabilities to system info operatorSergey Sharybin
For CPU it gives available instructions set (SSE, AVX and so). For GPU CUDA it reports most of the attribute values returned by cuDeviceGetAttribute(). Ideally we need to only use set of those which are driver-specific (so we don't clutter system info with values which we can get from GPU specifications and be sure they stay the same because driver can't affect on them).
2014-12-25Cleanup: Fix Cycles Apache header.Thomas Dinges
This was already mixed a bit, but the dot belongs there.
2014-11-03Fix typo breaking compilation with SSE2.Bastien Montagne
Spotted by sybrenstuvel (Sybren Stüvel), thanks!
2014-10-30Deduplicate some code by using a function pointer to the real kernelMartijn Berger
This has no performance impact what so ever and is already used in the adaptive sampling patch
2014-10-06Cycles: Workaround dead-slow expf() on 64bit linuxSergey Sharybin
Single precision exponent on 64bit linux tends to be order of magnitude slower than double precision version even with single<->double precision conversion. Some feedback in the mailing lists also suggests that logf() is also slow, but this i didn't confirm here in the studio yet. Depending on the shader setup it gives ~3% with the secret agent shot and up to around 15% with the bmw scene here.
2014-09-04Fix wrong track of the memory when doing device vector resize before freeing itSergey Sharybin
This is rather legit case which happens i.e. when having persistent images enabled and session is updating the lookup tables. Now device_memory keeps track of amount of memory being allocated on the device, which makes freeing using the proper allocated size, not the CPU side buffer size.
2014-08-19Fix T41471 Cycles Bake: Setting small tile size results in wrong bake with ↵Dalai Felinto
stripes rather than the expected noise pattern This problem was introduced in 983cbafd1877f8dbaae60b064a14e27b5b640f18 Basically the issue is that we were not getting a unique index in the baking routine for the RNG (random number generator). Reviewers: sergey Differential Revision: https://developer.blender.org/D749
2014-07-25Cycles Bake: show progress bar during bakeDalai Felinto
Baking progress preview is not possible, in parts due to the way the API was designed. But at least you get to see the progress bar while baking. Reviewers: sergey Differential Revision: https://developer.blender.org/D656
2014-06-14Cycles: Add an AVX2 CPU kernel.Thomas Dinges
This kernel is compiled with AVX2, FMA3, and BMI compiler flags. At the moment only Intel Haswell benefits from this, but future AMD CPUs will have these instructions as well. Makes rendering on Haswell CPUs a few percent faster, only benchmarked with clang on OS X though. Part of my GSoC 2014.
2014-06-06Fix T40370: cycles CUDA baking timeout with high number of AA samples.Brecht Van Lommel
Now baking does one AA sample at a time, just like final render. There is also some code for shader antialiasing that solves T40369 but it is disabled for now because there may be unpredictable side effects.