Commit Graph

3935 Commits

Author SHA1 Message Date
Bastien Montagne
75ab57efed Fix T38190: Linux tablet: Issue with XInput/GHOST?
With edits by Campbell, thanks!

Looks like in some cases (driver dependent?), `XDeviceMotionEvent` get generated with only part of expected data
(e.g. only x coordinate, only pressure, etc.), data which did not change since last event being NULL.
We know which data to actually handle with `XDeviceMotionEvent.first_axis` and `XDeviceMotionEvent.axes_count` values.

Reviewed by: campbellbarton

Differential Revision: https://developer.blender.org/D208
2014-01-13 17:51:17 +01:00
Sv. Lockal
9cf6946d31 Fix cycles texture crash on win x86-64 + msvc 11
Use union for __m128 aliasing; while gcc supports no-strict-aliasing attribute, unions are the most common way to deal with __m128 in msvc.
2014-01-13 18:31:02 +04:00
Marcus von Appen
f0fb60f8c9 Fix cycles standalone compile on some systems, CMAKE_DL_LIBS should be enough.
Reviewed By: brecht

Differential Revision: https://developer.blender.org/D205
2014-01-13 10:36:02 +01:00
Antony Riakiotakis
717bf85545 Fix some harmless warnings that mostly appeared on MinGW64 2014-01-13 04:28:51 +02:00
Sv. Lockal
d6c022d6d7 Fix compilation for OpenCL (and small stype fixes) 2014-01-12 18:18:43 +04:00
Sv. Lockal
47c5898fa1 Cycles: SSE for Voronoi textures (targeted for Haswell CPUs)
Gives up to 15% speedup scenes with voronoi-based textures (up to 25% with volumes) on Haswell. The performance change for other CPUs is much smaller: 1-2%.

Reviewed By: brecht

Differential Revision: https://developer.blender.org/D203
2014-01-12 18:14:00 +04:00
Sv. Lockal
da3fdf0b4b Code Cleanup: in Cycles SSE replace macros with templates, skip unused code with preprocessor, simplify casts 2014-01-11 22:20:03 +04:00
Sv. Lockal
b886c26d1f Cycles: mix hair minimum width code with SSE intersection code
Gives 6.5% speedup for hair.blend from testsuite.

Reviewed By: brecht

Differential Revision: https://developer.blender.org/D197
2014-01-11 20:47:30 +04:00
Campbell Barton
50650e28ea Events: support for buttons 6 & 7 (some trackballs have these) X11 only
Patch by Marcus von Appen

Note: this patch makes ISMOUSE accept INBETWEEN_MOUSEMOVE as a mouse
event where before it didnt.
2014-01-12 00:40:23 +11:00
Campbell Barton
1bfa64895e Ghost: update multitest for changes in BLF 2014-01-11 23:53:23 +11:00
4d72a5e34a Fix T38129: cycles viewport render display with very bright colors turning black.
This happened when exceeding the maximum value representable by half floats.
2014-01-11 00:50:53 +01:00
241fccaf6a Fix T37817: cycles CUDA detection problem on Windows with non-ascii paths. 2014-01-11 00:47:58 +01:00
79e040ba95 Fix T38143: pressing F12 key in the text editor on OS X would type an invalid character. 2014-01-10 19:41:01 +01:00
8c0f9365c0 Fix T38134: missing cycles update when removing world volume scatter shader. 2014-01-09 01:26:43 +01:00
2d073bbf21 Fix T38134: cycles viewport render not updating when adding a world volume shader. 2014-01-08 23:12:54 +01:00
Sv. Lockal
20b046d763 Cycles: workaround for noise performance regression in CUDA 5.5
Use manual ternary operation widening in grad(). Without it nvcc 5.5 produces multiple branch splits with very big branches (because of inlining). This solves 19% performance regression for BMW1M-MikePan.blend.

Also remove one redundant instruction in perlin SSE (when h == 12 or h == 14, then h is always >= 4).

Reviewed By: brecht

Differential Revision: https://developer.blender.org/D190
2014-01-08 22:25:55 +04:00
Thomas Dinges
8094ac9194 Cycles: Fix World Homogeneous volume setting, had no influence.
Thanks to "storm" for noticing this!
2014-01-08 11:00:06 +01:00
Thomas Dinges
073be286b4 Cycles: Update Integrator Presets and Total Samples info for latest changes. 2014-01-07 15:55:32 +01:00
7b0a46b1ff Fix CUDA/OpenCL compile errors in scattering commit. 2014-01-07 15:48:04 +01:00
01df756bd1 Cycles Volume Render: scattering support.
This is done by adding a Volume Scatter node. In many cases you will want to
add together a Volume Absorption and Volume Scatter node with the same color
and density to get the expected results.

This should work with branched path tracing, mixing closures, overlapping
volumes, etc. However there's still various optimizations needed for sampling.
The main missing thing from the volume branch is the equiangular sampling for
homogeneous volumes.

The heterogeneous scattering code was arranged such that we can use a single
stratified random number for distance sampling, which gives less noise than
pseudo random numbers for each step. For volumes where the color is textured
there still seems to be something off, needs to be investigated.
2014-01-07 15:03:41 +01:00
Campbell Barton
fee66f7bc8 Code cleanup: defines for statfs were getting out of hand for BSD's.
add __DragonFly__ and internal defines to avoid copy-pasting checks.

also remove __CYGWIN32__ check, since cygwin is no longer supported.
2014-01-07 13:39:00 +11:00
Martijn Berger
62c8bae872 Added scons option to actually build the sse41 kernel. CMake already has it 2014-01-06 21:38:56 +01:00
Thomas Dinges
5022d9f81b Cycles: Don't include SIMD util file for OpenCL/CUDA, this fixes OpenCL compilation. 2014-01-06 21:28:18 +01:00
Jens Verwiebe
a0b424aa4c Take back last header copy, due it is for native only, must be a runtime solution, todo: do by definitions 2014-01-06 20:43:54 +01:00
Jens Verwiebe
48d8faeb79 Cmake: fix kernelcompile after introduction of util_simd.h 2014-01-06 20:26:02 +01:00
Sv. Lockal
acc90b40bf Cycles: Minor optimization (~1%) for texture access on CPU 2014-01-06 22:05:31 +04:00
Sv. Lockal
4817da0df4 Cleanup: use blend() in perlin noise (gives 12 less instructions on SSE4.1) 2014-01-06 21:24:28 +04:00
Sv. Lockal
96903508bc Cycles: SSE optimization for sRGB conversion (gives 7% speedup on CPU for pavillon_barcelone scene)
Thanks brecht/dingto/juicyfruit et al. for testing and reviewing this patch in T38034.
2014-01-06 20:03:30 +04:00
Campbell Barton
64fc94e93f Code Cleanup: osl style 2014-01-06 13:58:33 +11:00
Thomas Dinges
ce6dce3b13 Code cleanup / Cycles: else/if for SSE41 kernel functions. 2014-01-06 03:22:14 +01:00
Campbell Barton
c3bc2fd941 CMake: cleanup and add include 2014-01-04 13:17:07 +11:00
975c048ecd Fix gcc compile error in last commit. 2014-01-03 19:24:55 +01:00
ca7060662d Fix cycles OSL volume render crash with multiple closures. 2014-01-03 18:57:38 +01:00
bb0a0315e2 Code refactor: move random number and MIS variables into PathState.
This makes it easier to pass this state around, and wraps some common RNG
dimension computations in utility functions.
2014-01-03 18:57:38 +01:00
Campbell Barton
a288644b1e Code Cleanup: WIN32 defines, check for _MSC_VER instead of !FREE_WINDOWS 2014-01-03 20:46:12 +11:00
Martijn Berger
1c8a12ee61 Fix T37987: MSVC 2013 has C99 headers and warns for out define hypot _hypot for good reason it seems 2014-01-02 22:19:10 +01:00
d0c6f14c73 Fix T38033: cycles volume emission changes with step size. 2014-01-02 21:34:22 +01:00
aaabac069f Cycles Volume Render: these changes should have included in the last commit. 2013-12-31 18:03:22 +01:00
9cd2b19999 Cycles Volume Render: generated texture coordinates for volume render.
This does not support staying fixed while the surface deforms, but for static
meshes it should match up with the surface texture coordinates. Implemented
as a matrix transform from objects space to mesh texture space.

Making this work for deforming surfaces would be quite complicated, you might
need something like harmonic coordinates as used in the mesh deform modifier,
probably will not be possible anytime soon.
2013-12-31 17:38:26 +01:00
6b03f92aa7 Cycles Volume Render: optimization to avoid exporting surface attributes when
only a volume shader is used.
2013-12-31 17:30:34 +01:00
Masakazu Ito
3d40e3f9db Fix console incorrectly showing on Windows Blender startup in some cases.
The console window is hidden by default, but we need to avoid this when
starting from the command prompt, because it would hide the window you just
typed the command in.

Previously it would check if Blender was started from "explorer.exe" to
determine that, but that wasn't working for application launchers like
Appetizer or Colibri. Instead we now check if the process ID is the same as
the process ID of the console window, which appears to work reliably.

Reviewed By: brecht

Differential Revision: https://developer.blender.org/D122
2013-12-31 00:17:38 +01:00
Campbell Barton
19103b4437 Code Cleanup: quiet unused define warning 2013-12-30 12:19:27 +11:00
Campbell Barton
6d9e6bca8f Code Cleanup: cycles tips and long lines 2013-12-30 12:06:36 +11:00
889d77e6f6 Cycles Volume Render: heterogeneous (textured) volumes support.
Volumes can now have textured colors and density. There is a Volume Sampling
panel in the Render properties with these settings:

* Step size: distance between volume shader samples when rendering the volume.
  Lower values give more accurate and detailed results but also increased render
  time.
* Max steps: maximum number of steps through the volume before giving up, to
  protect from extremely long render times with big objects or small step sizes.

This is much more compute intensive than homogeneous volume, so when you are not
using a texture you should enable the Homogeneous Volume option in the material
or world for faster rendering.

One important missing feature is that Generated texture coordinates are not yet
working in volumes, and they are the default coordinates for nearly all texture
nodes. So until that works you need to plug in object texture coordinates or a
world space position.

This is work by "storm", Stuart Broadfoot, Thomas Dinges and myself.
2013-12-30 00:04:02 +01:00
af128c4c96 Fix cycles volume emission not working with OSL. 2013-12-30 00:04:02 +01:00
30aa0c2482 Code refactor: better distinguish scatter and absorption for volume integration. 2013-12-30 00:04:02 +01:00
Martijn Berger
21d587d9fc Added option to have a seperate environment for executing nvcc
This can be used to compiler cuda kernels with Visual Studio 2010 while
the rest of blender is compiled with MSVC 12.0 / 2013
2013-12-29 14:57:21 +01:00
3f39af9cc2 Fix cycles volume render crash when trying to access primitive attributes
like generated texture coordinates or tangents.
2013-12-28 23:39:15 +01:00
fe222643b4 Cycles Volume Render: add volume emission support.
This is done using the existing Emission node and closure (we may add a volume
emission node, not clear yet if it will be needed).

Volume emission only supports indirect light sampling which means it's not very
efficient to make small or far away bright light sources. Using direct light
sampling and MIS would be tricky and probably won't be added anytime soon. Other
renderers don't support this either as far as I know, lamps and ray visibility
tricks may be used instead.
2013-12-28 23:20:53 +01:00
Sv. Lockal
077fe03eaf Use ccl_device_inline for SSE perlin noise
msvc ignores inline hint here and generates a bunch of push/lea
2013-12-28 23:26:42 +04:00
2b39214c4d Cycles Volume Render: add support for overlapping volume objects.
This works pretty much as you would expect, overlapping volume objects gives
a more dense volume. What did change is that world volume shaders are now
active everywhere, they are no longer excluded inside objects.

This may not be desirable and we need to think of better control over this.
In some cases you clearly want it to happen, for example if you are rendering
a fire in a foggy environment. In other cases like the inside of a house you
may not want any fog, but it doesn't seem possible in general for the renderer
to automatically determine what is inside or outside of the house.

This is implemented using a simple fixed size array of shader/object ID pairs,
limited to max 15 overlapping objects. The closures from all shaders are put
into a single closure array, exactly the same as if an add shader was used to
combine them.
2013-12-28 20:12:11 +01:00
e369a5c485 Cycles Volume Render: support for rendering of homogeneous volume with absorption.
This is the simplest possible volume rendering case, constant density inside
the volume and no scattering or emission. My plan is to tweak, verify and commit
more volume rendering effects one by one, doing it all at once makes it
difficult to verify correctness and track down bugs.

Documentation is here:
http://wiki.blender.org/index.php/Doc:2.6/Manual/Render/Cycles/Materials/Volume

Currently this hooks into path tracing in 3 ways, which should get us pretty
far until we add more advanced light sampling. These 3 hooks are repeated in
the path tracing, branched path tracing and transparent shadow code:

* Determine active volume shader at start of the path
* Change active volume shader on transmission through a surface
* Light attenuation over line segments between camera, surfaces and background

This is work by "storm", Stuart Broadfoot, Thomas Dinges and myself.
2013-12-28 16:57:10 +01:00
133f770ab3 Code cleanup: move shadow_blocked function into separate file. 2013-12-28 16:57:10 +01:00
37c4d6a50a Cycles Volume Render: add flags to quickly detect when objects have a volume shader. 2013-12-28 16:57:10 +01:00
a35db17cee Cycles Volume Render: work on nodes and closures.
* Henyey-Greenstein scattering closure implementation.
* Rename transparent to absorption node and isotropic to scatter node.
* Volume density is folded into the closure weights.
* OSL support for volume closures and nodes.
* This commit has no user visible changes, there is no volume render code yet.

This is work by "storm", Stuart Broadfoot, Thomas Dinges and myself.
2013-12-28 16:57:02 +01:00
Martijn Berger
114284b1fb creation of path from std::string on Windows (VC10/11/12) crashes (access error)
Summary:
Seems to be a known problem in boost: https://svn.boost.org/trac/boost/ticket/6320

Applied the solution but do not know if this is the right place.

Reviewers: dingto, brecht

Reviewed By: dingto

Differential Revision: https://developer.blender.org/D140
2013-12-27 22:38:46 +01:00
Thomas Dinges
1578b55c27 Cycles: Move SIMD utility functions into its own file.
Recently added SSE macros for noise texture can be moved here as well, but I leave this for later.
2013-12-27 21:30:21 +01:00
Thomas Dinges
a92abf5089 Cycles / Perlin Noise: Optimize noise calculation by using SIMD instructions on CPU.
This makes scenes with a Noise Texture render faster, the BMW file is 12-15% faster now.

Patch by Sv. Lockal, many thanks! :)
2013-12-27 18:48:37 +01:00
Campbell Barton
d09a8ea9e7 Code Cleanup: style 2013-12-27 14:21:03 +11:00
Thomas Dinges
40f79cf6e7 Cycles / Hair: Avoid duplicate calculations and remove redundant if branch, instead add the condition to the one above. 2013-12-26 21:52:46 +01:00
Sergej Reich
a706b9feda Rigidbody: Code cleanup
Remove redundant extern keyword.
2013-12-26 21:33:58 +01:00
Sergej Reich
ceb2430dd7 Rigidbody: Allow triangle mesh shapes to deform during simulation
Only supported when using the "Deform" mesh source.
2013-12-26 18:38:06 +01:00
Sergej Reich
c96601138d Rigidbody: Use own structure to store mesh data for collision shapes
This gives us better access to the data and should also be faster to
create.
2013-12-26 18:38:06 +01:00
Thomas Dinges
03fed41e59 Cycles / Hair: Further cleanup of UI and internals.
* UI: Remove deprecated condition (CURVE_RIBBONS) and hide backface property, when it's hardcoded in C (Curve/Line segments && Ribbons).

* Remove "use_tangent_normal" and "CURVE_KN_TANGENTGNORMAL" as its unused (follow up for last commit).
2013-12-26 03:25:30 +01:00
Thomas Dinges
a649b6eef5 Cycles / Hair: Some cleanup and optimizations for hair code.
* Remove dead code from line segments BVH refine.
CURVE_KN_TANGENTGNORMAL and CURVE_KN_TRUETANGENTGNORMAL are either both true, or both false. Therefore a true/false condition is impossible.
This was a leftover of CURVE_CUSTOM, which was removed in r59234.

* Use "else if" in blender_curves.cpp.
2013-12-26 02:02:14 +01:00
Thomas Dinges
ad0a3de3ce Cycles / OpenCL: Let the OpenCL runtime determine its optimal work-group size automatically, by passing a NULL pointer here.
This is recommended in the Intel OpenCL optimization docs (http://software.intel.com/en-us/vcsource/samples/optimizing-opencl) and I can confirm a small performance increase here (1-2% on nVidia OpenCL, up to 8% on Intel OpenCL).
2013-12-24 20:20:57 +01:00
Thomas Dinges
4ba80fd461 Cycles / Hair: No need to calculate curvepoint() when we use Ribbon curves.
Also some style cleanup.
2013-12-24 04:00:45 +01:00
Thomas Dinges
65ab283168 Code cleanup / Cycles: Remove CUDA check (we don't support sm_1x anymore) and unused hair flag. 2013-12-22 14:43:37 +01:00
Thomas Dinges
427105e425 Code cleanup / Cycles: Remove unused interpolation code for hair triangles, we only support cardinal curves. 2013-12-22 14:14:09 +01:00
Sergey Sharybin
ff9974ed69 Fix T37898: blenderplayer painfully slow in recent builds
Issue was caused by recent image cache rewrite and root of
the issue goes to the fact that blender player doesn't
initialize cache limiter and it uses 32meg of memory only.

This leads to infinite image loading/freeing.

For now disabled cache limiter in game engine, this brings
back old behavior.

In theory we might be smarter here, but better caching
policy is to be discussed.
2013-12-22 15:26:59 +06:00
Sergey Sharybin
78698a2ecf Add ItemDestroyable to the cache limitor
This callback is used when cache limiter needs to remove
some cached objects when running out of limit.

From blender side it's used to keep painted images always
in memory.

This fixes issue when painted images were removing from
the memory after image cache rewrite.
2013-12-22 14:44:56 +06:00
Campbell Barton
c1c26c36f6 Style Cleanup: remove preprocessor indentation (updated wiki style guide too) 2013-12-22 14:12:19 +11:00
Thomas Dinges
9bd3a226ae Cleanup: Code and style cleanup for Cycles curve export code. 2013-12-21 00:20:16 +01:00
8ed0878f0f Fix T37884: cycles hair rendering crash with UV coordinates.
This was broken in a recent bugfix for zero length hairs.
2013-12-20 00:08:46 +01:00
6ccf3402cb Fix T37790: OSL not rendering subsurface scattering color correct since upgrade to 1.4. 2013-12-18 12:29:11 +01:00
Sergey Sharybin
c5d7ea091f Changes to partial update during rendering
Summary:
Mainly addressed to solve old TODO with color managed fallback
to CPU mode when displaying render result during rendering.

That fallback was caused by the fact that partial image update
was always acquiring image buffer for composite output and was
only modifying display buffer directly.

This was a big issue for Cycles rendering which renders layers
one by one and wanted to display progress of each individual
layer. This lead to situations when display buffer was based on
what Cycles passes via RenderResult and didn't take layer/pass
from image editor header into account.

Now made it so image buffer which partial update is operating
with always corresponds to what is set in image editor header.

To make Cycles displaying progress of all the layers one by one
made it so image_rect_update switches image editor user to
newly rendering render layer. It happens only once when render
engine starts rendering next render layer, so should not be
annoying for navigation during rendering.

Additional change to render engines was done to make it so
they're able to merge composite output to final result
without marking tile as done. This is done via do_merge_result
argument to end_result() callback. This argument is optional
so should not break script compatibility.

Additional changes:

- Partial display update for Blender Internal now happens from
  the same thread as tile rendering. This makes it so display
  conversion (which could be pretty heavy actually) is done in
  separate threads. Also gives better UI feedback when rendering
  easy scene with small tiles.

- Avoid freeing/allocating byte buffer for render result
  if it's owned by the image buffer. Only mark it as invalid
  for color management.

  Saves loads of buffer re-allocations in cases when having
  several image editors opened with render result. This change
  in conjunction with the rest of the patch gave around
  50%-100% speedup of render time when displaying non-combined
  pass during rendering on my laptop.

- Partial display buffer update was wrong for buffers with number
  of channels different from 4.

- Remove unused window from RenderJob.

- Made image_buffer_rect_update static since it's only used
  in single file.

Reviewers: brecht

Reviewed By: brecht

CC: dingto

Differential Revision: http://developer.blender.org/D98
2013-12-17 23:42:38 +06:00
Thomas Dinges
011ae78857 Cycles / OpenCL: Fix compile error on OS X
After update to Mac OS X 10.9.1, OpenCL works now on my Intel CPU in the 2013 Macbook Pro (even the entire kernel).
The Intel Iris Pro GPU still segfaults here though, even when all flags are disabled (building "clay like" kernel only).

Maybe we need the -no-missing-prototypes for AMD hardware still, but I couldn't find a way to distuinguish here.
2013-12-17 09:59:18 +01:00
c05209ec01 Fix T37827: cycles XML mesh export utility not longer worked. 2013-12-16 11:08:41 +01:00
Peter Staples
4a141022c3 Fix T37816: make cycles panel registration work better with addons.
This would give an error when an addon removed a panel.
2013-12-14 18:00:25 +01:00
cccd06ea44 Fix T37810: GLSL dither shader not working on OS X.
The GLSL function textureSize() is not supported here, only when we start using
OpenGL core profile will this work. For now check the supported GLSL version and
use a somewhat slower replacement.
2013-12-14 16:01:48 +01:00
Thomas Dinges
1bebdc9ad0 Fix T37264: cycles CPU render had limited number of float images, bumped to 1024.
GPU is still limited to 5, but there's no good reason for the CPU to be limited.
2013-12-14 15:07:46 +01:00
Thomas Dinges
b43ce8a140 Code cleanup / Cycles: Remove some unused hair code. 2013-12-14 13:11:44 +01:00
1e045a2417 Cycles: CUDA runtime kernel compilation can now find CUDA 6.0. 2013-12-13 19:12:07 +01:00
Sergey Sharybin
5a91df3271 Implement GPU-side dither
Summary:
Uses some magic pseudo-random which is actually a
texture coordinate hashing function.

TODOs:
- Dither noise is the same for all the frames.
- It's different from Floyd's dither we've been
  using before.
- Currently CPU and GPU dithering used different
  implementation. Ideally we need to use the same
  dither in CPU.

Reviewers: brecht

Reviewed By: brecht

Differential Revision: http://developer.blender.org/D58
2013-12-13 12:36:45 +06:00
Campbell Barton
6c96535fd8 Code Cleanup: use static for sky_model_data.h 2013-12-13 04:40:30 +11:00
Sergey Sharybin
abb7e9f09b Attempt to fix compilation error on Debian armel kernel 2013-12-12 17:33:36 +06:00
Sergey Sharybin
b53bc572fd Attempt to fix compilation against libav-0.8.9 2013-12-11 22:40:45 +06:00
Sergey Sharybin
aeee7118ae Cache limiter cleanup and small fixes
- Made code a bit less cluttered to follow
- Fixed possible deadlock when enforcing limit
  and highest priority element is still referenced.
2013-12-11 16:32:41 +06:00
d7945b7202 Fix T37704: cycles hair render error with hair density vertex group.
Zero length hairs were causing problems, now it skips rendering them as they
are invisible anyway.
2013-12-10 19:47:27 +01:00
7e5d2fee71 Fix T37694: cycles particles emitter object rendering when it shouldn't.
This was broken by a recent bugfix for T37159.
2013-12-09 21:59:45 +01:00
b38f645bf1 Fix build error when building without OSL support. 2013-12-09 05:28:19 +01:00
38adc8a91f Cycles OSL: update to build with latest OSL master shader group changes. 2013-12-08 15:15:27 +01:00
Campbell Barton
05e96ba160 Style: use frozen sets 2013-12-08 22:53:55 +11:00
Thomas Dinges
28d5f2ab60 Cycles: Update stdosl.h to OSL 1.4.0. (includes new aastep functions). 2013-12-08 12:20:15 +01:00
Thomas Dinges
2069606dc5 Code cleanup: UI cleanup for cycles UI code and fix typo in system info. 2013-12-08 12:13:09 +01:00
Sergey Sharybin
b6646c6a2a Bummer, forgot to test with OSL disabled. 2013-12-08 15:19:59 +06:00
Sergey Sharybin
46f8dba4c7 Extend system-info with information about OIIO, OCIO and OSL
Summary:
Version of those libraries might be useful to know.

- OIIO and OCIO is exposed via bpy.app.oiio and bpy.app.ocio.
  There're "supported", "version" and "version_string" defined
  in those modules.

- OSL is available as _cycles.osl_version and _cycles.osl_version_string.

Reviewers: campbellbarton

Reviewed By: campbellbarton

CC: dingto

Differential Revision: http://developer.blender.org/D79
2013-12-08 15:03:17 +06:00
Martijn Berger
85a0c5d4e1 Cycles: network render code updated for latest changes and improved
This actually works somewhat now, although viewport rendering is broken and any
kind of network error or connection failure will kill Blender.

* Experimental WITH_CYCLES_NETWORK cmake option
* Networked Device is shown as an option next to CPU and GPU Compute
* Various updates to work with the latest Cycles code
* Locks and thread safety for RPC calls and tiles
* Refactored pointer mapping code
* Fix error in CPU brand string retrieval code

This includes work by Doug Gale, Martijn Berger and Brecht Van Lommel.

Reviewers: brecht

Differential Revision: http://developer.blender.org/D36
2013-12-07 12:26:58 +01:00
Thomas Laroche
5c07f62fab Cycles: show remaining render time in render info text
It's a simple estimate, not very precise but that isn't really possible always.
For progressive render it will become more accurate the longer you render.

Reviewed By: brecht

Differential Revision: http://developer.blender.org/D67
2013-12-07 12:26:58 +01:00
Alexandr Kuznetsov
e2429d6492 Woo Hoo. First git commit.
Changes for VC2013

Now, I can build Blender with VC2013 with Cycles, Collada, OpenExr,OpenImageIO disabled. Also, you need VC2008 sp1 installed to make old libs compatible.
2013-11-29 15:13:12 -05:00
4d6c877b66 Cycles OSL: fix mistake in recent refactoring, parameters are not set before setup. 2013-11-29 17:18:43 +01:00
746628e0d0 Cycles OSL: refactoring to remove all dependencies on builtin OSL closures.
These were removed in new OSL versions. We only used these as base classes,
not using them at all simplifies the code a bit.
2013-11-29 04:01:07 +01:00
19a41e5a10 Fix iTaSC build error when building with libc++.
This was using TreeElement before it was fully defined, which gives undefined
behavior that happened to work with other libraries but not libc++.

Based on patch by Marcus von Appen, modifications for brevity and to ensure we
don't dereference invalid memory. Ref T37477.
2013-11-28 21:35:28 +01:00
62bf24a5c3 Cycles: experimental OpenSubdiv code.
This code can't actually be enabled for building and is incomplete, but it's
here because we know we want to support this at some point and there's not much
reason to have it in a separate branch if a simple #ifdef can disable it.
2013-11-28 02:11:42 +01:00
89cfeefab5 Cycles: experimental OSL ptex reading code.
This code can't actually be enabled for building and is incomplete, but it's
here because we know we want to support this at some point and there's not much
reason to have it in a separate branch if a simple #ifdef can disable it.
2013-11-28 02:11:42 +01:00
44d1c92e60 Cycles: add ptex face ID and UV attributes.
Not the most memory efficient way to store these things but it's simple and
implementing it better requires some work to natively support subd grids as
a primitive in some way.
2013-11-28 02:11:42 +01:00
731ffd3cd4 Cycles: remove approximate subdivision surface with gregory patches code.
It was never fully implemented and will be replaced by OpenSubdiv. Only linear
subdivision remains now. Also includes some refactoring in the split/dice code,
adding a SubdParams struct to pass around parameters more easily.
2013-11-28 02:11:42 +01:00
f67dda6893 Fix T37159: cycles rendering particle emitter mesh incorrectly when using non-hair particles. 2013-11-27 17:17:25 +01:00
8cb78f1094 Fix mistake in last commit with submodules. 2013-11-26 20:40:55 +01:00
b98ff5cb5b Fix T37303, Fix T37163: cycles mask layers that are also excluded not rendering
correct with multiple render layers.

This case is somewhat weak, we now do a few more checks on sync than I would
like, but it's not too bad.
2013-11-26 20:36:53 +01:00
Campbell Barton
2b4c68b902 CMake Build: option to compile without opennl/superlu. 2013-11-25 15:36:19 +11:00
Thomas Dinges
5dec5fd4e5 Cycles: Add missing unregister for world ray visibility pointer. 2013-11-24 22:30:11 +01:00
fab96b5913 UI List: remove separate name text fields.
It was never the intention to have these separate, and now that we can rename
directly in the list there is no more need for them.
2013-11-24 14:27:02 +01:00
2cb63486a9 Fix scons build error compiling 32 bit OS X built on 64 bit. 2013-11-23 07:12:02 +01:00
58ec292fd8 Fix cycles build error with visual studio, apparently the windows ABI does not
like 16 bit alignment on 32 bit.
2013-11-23 05:47:57 +01:00
Martijn Berger
e3a79258d1 Cycles: test code for sse 4.1 kernel and alignment for some vector types.
This is mostly work towards enabling the __KERNEL_SSE__ option to start using
SIMD operations for vector math operations. This 4.1 kernel performes about 8%
faster with that option but overall is still slower than without the option.

WITH_CYCLES_OPTIMIZED_KERNEL_SSE41 is the cmake flag for testing this kernel.

Alignment of int3, int4, float3, float4 to 16 bytes seems to give a slight 1-2%
speedup on tested systems with the current kernel already, so is enabled now.
2013-11-22 14:42:41 +01:00
Campbell Barton
a5183d7a87 Code Cleanup: use NULL for pointer checks and remove joke. 2013-11-22 10:43:42 +11:00
Thomas Dinges
bd5da19d86 Cycles: Add a "Normal" input socket to the Layer Weight node + GLSL drawing code.
Patch by lichtwerk (Philipp Oeser).

Differential Revision: http://developer.blender.org/D28
2013-11-22 00:33:28 +01:00
Jörg Müller
447d277498 Fix IRC reported by elubie: windows crash with audio animation
There was a bug in how the iterators of STL list was used when erasing during iteration of a list, which was triggered by the STL implementation of MSVC, but hid well with gcc.
2013-11-20 00:26:15 +01:00
c18712e868 Cycles: change __device and similar qualifiers to ccl_device in kernel code.
This to avoids build conflicts with libc++ on FreeBSD, these __ prefixed values
are reserved for compilers. I apologize to anyone who has patches or branches
and has to go through the pain of merging this change, it may be easiest to do
these same replacements in your code and then apply/merge the patch.

Ref T37477.
2013-11-18 08:48:15 +01:00
Jens Verwiebe
c239baa0ba OSX/scons: small reorder and spelling 2013-11-16 22:13:51 +01:00
Jens Verwiebe
a05e90f5fc OSX/scons: fix msgfmt binary linking and locale files distribution 2013-11-16 21:46:55 +01:00
Sergey Sharybin
fd8ad2bbe4 Further tweak to .mo compilation on windows
Was wrong dependency used for msgfmt custom command.
2013-11-16 22:33:45 +06:00
Sergey Sharybin
60ca109340 Attempt to fix compilation error on windows
Seems simply need to add .exe to msgfmt executable when
adding custom command to SCons.

Don't have windows by hand atm, so can not test for sure.
2013-11-16 20:42:39 +06:00
Sergey Sharybin
ac21db957a Add functional and cctype headers to msgfmt.cc
Fixes compilation with MSVC compilers.

Patch by leszekswirski (Lech Swirski) with some own tweaks.

Differential Revision: http://developer.blender.org/D2
2013-11-15 12:43:56 +06:00
Sergey Sharybin
efd518b379 Fix for msgfmt leaving context from previous message string 2013-11-15 12:19:55 +06:00
Joerg Mueller
c53f80aeed Fix for [#37362] Audio strips sometimes are evaluated incorrectly.
For details see bug comments. The problem was that blender's animation system didn't update the audio animation system anymore due to an optimization. Fixed this in a complex but proper way in the audio animation system, so that it can handle gaps of missing values.
2013-11-12 18:29:08 +00:00
Thomas Dinges
cc7b2a0b04 Cycles / Fresnel Node:
* Add a "Normal" Input to the Fresnel node.
* Fix for the Fresnel GLSL code (normalize the Incoming vector).

Patch #37384 by Philipp Oeser (lichtwerk) , thanks!
2013-11-09 13:14:00 +00:00
Sergey Sharybin
ac6d91b939 Be ready for changes in bf-translations repository
Made it so if there's release/datafiles/locale/po
folder, then all the .po files will be converted
to .mo at blender compile time and installed to
an appropriate location.

Uses small own implementation msgfmt which is
based on msgfmt.py from Python project, but also
supports contexts.

There's no functional changes for until we've
switched to use source .po files instead of
pre-compiled .mo.

P.S. Well, there's one change which is msgfmt.cc
     being compiled even if it's not used, but
     would rather not clutter code with checks
     since pretty soon we'll use this program
     anyway.
2013-11-08 20:44:48 +00:00
Joerg Mueller
1457924a21 Fix for [#37293] Audio does not Scrub, plays fully instead 2013-11-07 23:40:06 +00:00
Brecht Van Lommel
99c5e71397 Quicktime: remove backend with the old quicktime API, and keep the QTKit backend.
This means that if you have WITH_BF_QUICKTIME or WITH_CODEC_QUICKTIME enabled,
it will always use QTKit.

The old backend was only used on 32 bit OS X builds, now 32 and 64 bit builds will
give consistent input/output. On Windows or Linux quicktime isn't being used.
2013-11-06 01:45:15 +00:00
Jens Verwiebe
9e3a993392 OSX/GHOST: starting file by file removal of outdated code, such as VERSION_MIN_REQUIRED <= 1040 2013-11-05 17:49:27 +00:00
Jens Verwiebe
37f45454d3 Fix linking for non-apple ndof 2013-11-05 15:48:26 +00:00
Jens Verwiebe
4df23896e5 OSX: removing useless cocoa conditionals as it's solely api now 2013-11-05 14:35:09 +00:00
Jens Verwiebe
e83f169da1 OSX/cmake: ghost carbon removal 2013-11-05 14:09:17 +00:00
Jens Verwiebe
7ccf1f0b46 OSX: more carbon removal cleanups 2013-11-05 13:50:53 +00:00
Jens Verwiebe
311c5f33ff OSX: remove Ghost carbon files finally 2013-11-05 13:35:49 +00:00
Jens Verwiebe
7f5cb54b56 OSX: remove Ghost carbon files and adapt scons 2013-11-05 13:34:05 +00:00
Campbell Barton
4a99d30538 code cleanup: quiet warnings 2013-11-05 04:32:51 +00:00
Thomas Dinges
2c57e4f577 Cycles:
* Change the default Light Path settings.

* Diffuse/Glossy bounces are now set to 4, to give a bit faster renders in default scenes. More bounces are often not needed (especially in animation). 
* Transmission bounces have been increased to 12, to not run into problems with dark glass too quickly. 
* Max/Min bounces are now 12/3.
2013-11-01 09:37:42 +00:00
Campbell Barton
f9d5bccb06 code cleanup: spelling 2013-10-31 23:52:44 +00:00
Campbell Barton
beae4f498d code cleanup: spelling 2013-10-31 14:10:01 +00:00
Campbell Barton
50d1129a57 add atomic_ops.h to cmake's source code listing. 2013-10-31 14:09:01 +00:00
Campbell Barton
7267221715 remove return argument from wmOperatorType->cancel, was only ever returning OPERATOR_CANCELLED. 2013-10-30 23:08:53 +00:00
Lukas Toenne
06fb71bc46 Fix #37194, OSL script crashes blender. The lookup functions for finding Cycles shader inputs/outputs based on socket names are using a few modifications on the Blender socket names. But these only apply
to standard nodes where the Blender socket names can differ from associated Cycles names and may require additional indices to make them unique. Script node sockets are already unique and exact due to
being generated from the script function parameters.
2013-10-30 11:21:31 +00:00
Brecht Van Lommel
70e9191e15 Fix #37184: film exposure + transparency not working well in cycles viewport. 2013-10-28 19:01:01 +00:00
Sergey Sharybin
ecf2f55667 Fix #37187: ghost/test/multitest fails to build
Commited patch provided by Lawrence D'Oliveiro, thanks.
2013-10-28 12:54:18 +00:00
Sergej Reich
7d66d3298c cmake: bsp needs moto 2013-10-27 13:58:13 +00:00
Campbell Barton
48c1e0c0fc spelling: use American spelling for canceled 2013-10-26 01:06:19 +00:00
Campbell Barton
00160d4a1b remove unused var 2013-10-26 01:03:16 +00:00