Commit Graph

5361 Commits

Author SHA1 Message Date
Campbell Barton
9cea429f78 Fix T46431: Init glew before glx-context crashes
Initialize glxew before glew,
so we can check whats supported before creating the context.

This also removes need for mxIgnoreNoVersion.
2015-10-12 15:08:20 +11:00
ea7ce7fcf4 Fix T46447: fix build on non-x86 platforms. 2015-10-12 03:22:43 +02:00
Sergey Sharybin
88005475db Cycles: Make light behavior in local view matching BI
Title says it all, based on feedback of artists from gooseberry team.

This mainly affects cases when going to a local view from layers setup
when some lamps were on invisible layers. Those lights are no longer
becoming visible to the object in local view.

Reviewers: brecht, juicyfruit, dingto

Reviewed By: juicyfruit, dingto

Subscribers: maxon, eyecandy, venomgfx

Differential Revision: https://developer.blender.org/D1326
2015-10-11 20:16:53 +05:00
Sergey Sharybin
3f4c0612fe Fix T45058: Cycles hair shader reflects incorrectly for meshes
The issue was caused by non-continuous tangent space calculated for triangles.

This commit adds a Tangent input to Hair BSDF node which can be used to hook up
Tangent calculated form UV as an input to the node in order to make sure the
tangent space is continuous.

Doing this as an input instead of using default tangent layer from UV because of
several reasons:

- This way it's really easy to preserve compatibility with existing setups.

- Default UV map is not necessarily giving continuous space, one might want to
  use other tangent space sources or distort the space for some artistic
  decision.

Reviewers: juicyfruit, dingto

Reviewed By: dingto

Differential Revision: https://developer.blender.org/D1428
2015-10-11 19:43:30 +05:00
Sergey Sharybin
34e7285b0a Cycles: Gracefully handle out-of-memory happening in device vector
Currently only image loading benefits of this and will give magenta color
when image manager detects it's running out of memory.

This isn't ideal solution and can't handle all cases. For example, OOM
killer might kill process before it realized it run out of memory, but
in other cases this could prevent some crashes.

Reviewers: juicyfruit, dingto

Differential Revision: https://developer.blender.org/D1502
2015-10-11 19:41:59 +05:00
Sergey Sharybin
8a1afc28db Cycles: Increase number of textures allowed for OpenCL render
Currently OpenCL devices are packing images into a single texture,
which means technically number of textures is not limited here.

Now OpenCL will use same number of textures as CPU. If we want
to bump number of textures further, this values are to be modified
in sync.

NOTE OpenCL still does not support float textures.

Original patch from a guy called bliblubli in the tracker with
some own modifications.

Reviewers: brecht, dingto, sergey

Differential Revision: https://developer.blender.org/D1530
2015-10-11 18:22:01 +05:00
307d4b3139 Revert "Fix T46406: Cycles ignores default socket value associated with group socket"
Fixes T46442.
2015-10-10 21:57:00 +02:00
b098609186 Fix various compiler warnings. 2015-10-10 17:35:30 +02:00
240f356166 Fix T45167: OS X inertial scrolling can lead to unexpected zooming.
Differential Revision: https://developer.blender.org/D1539
2015-10-10 14:00:02 +02:00
a8dd0af8cf Fix T46341: OS X trackpad and magic mouse gestures not working with 10.11 SDK.
Differential Revision: https://developer.blender.org/D1539
2015-10-10 14:00:02 +02:00
Campbell Barton
f42ae6c569 Fix/Workaround T46431: blender-softwaregl crashes
Order of initialization bug only impacted mesa's software-gl.

For now effectively revert support for glx-context-flags.
2015-10-10 19:39:35 +11:00
Sergey Sharybin
ad5f6a95dd Cycles: Fix compilation error of CUDA kernel after recent decomposition changes 2015-10-09 17:53:29 +05:00
Sergey Sharybin
b54447c0eb Cycles: Make sure ray direction is always normalized
Ray direction is assumed to be normalized in such areas as scaling intersection
distance on instance push/pop when doing ray-scene intersection, but it was
possible that some closures wouldn't give normalized direction which could cause
wrong intersection checks.

Now normalization will happen on surface bounce, which could be a bit of a waste
if closure actually gives normalized direction, but currently only transparent
BSDF seems to give guaranteed normalized direction.
2015-10-09 15:58:03 +05:00
Sergey Sharybin
29247a7a05 Cycles: Fix wrong intersection with motion blur and degenerate object transform 2015-10-09 15:58:03 +05:00
Sergey Sharybin
4974ed93ef Cycles: Fix issues with quick inverse of degenerate matrix
This fixes part of the issues reported in T46322. Still need to solve
issue with wrong intersection distance scaling.
2015-10-09 15:58:03 +05:00
Sergey Sharybin
8fa4fccec4 Cycles: Fix intersection issues caused by degenerate instance matrix
Issue was caused by wrong intersection distance scaling on instance pop,
which could cause intersection distance to become zero, confusing following
intersection checks.
2015-10-09 15:58:03 +05:00
Sergey Sharybin
350cf8ea7f Cycles: Cleanup, whitespace around keywords 2015-10-08 19:08:28 +05:00
Sergey Sharybin
7083423eb4 Fix T46407: Enabling OSL breaks Vector Transform node 2015-10-08 19:04:42 +05:00
Lukas Stockner
e3abcd6723 Cycles: Add an interpolation option to environment textures
This commit exposes the interpolation parameter for environment textures (requested by DolpheenDream on IRC), just as it already is for image textures.

Reviewers: sergey

Differential Revision: https://developer.blender.org/D1544
2015-10-08 15:45:45 +02:00
Sergey Sharybin
1730c3666f Fix T46406: Cycles ignores default socket value associated with group socket 2015-10-08 16:05:51 +05:00
Sergey Sharybin
fca1d14214 Cycles: Fix wrong float3->float3 conversion node 2015-10-08 16:05:50 +05:00
Sergey Sharybin
8d108db184 Fix T46405: Cycles point density missing update when modifying source object 2015-10-08 12:41:05 +05:00
Sergey Sharybin
ac098007fb Cycles: Fix for point density always using render settings for modifiers 2015-10-08 12:41:05 +05:00
Sergey Sharybin
91f1886b8e Fix T46352: Cycles fails to render when material contains UV mapped texture as volume input 2015-10-05 14:45:03 +05:00
Sergey Sharybin
518d68fae0 Cycles: Add some TODO comments about derivatives 2015-10-05 12:54:05 +05:00
Sergey Sharybin
a771e27b84 Cycles: Fix for builtin textures when linking against OSL 1.6.8
Issue was caused by changed function signature. This is still not really full
support of new OSL API since we don't store anything in the derivatives which
could confuse mipmapping.
2015-10-05 12:52:07 +05:00
Sergey Sharybin
2a2e12772c Cycles: Remove redundant coordinate clipping in voxel SVM node
It is now handled via texture extension type.
2015-10-05 12:41:16 +05:00
Sergey Sharybin
d784568805 Cycles: Fix missing z-coordinate check in volume sampling 2015-10-05 12:40:50 +05:00
Sergey Sharybin
1a65289a12 Fix T46358: Cycles point density uses repeat extension type 2015-10-05 12:28:36 +05:00
d9d3a2a500 Fix T44605: OS X continuous grab issues. 2015-10-03 13:08:37 +02:00
Sergey Sharybin
9ad829da7b Cycles: Correction to point density with particle source and world mapping 2015-10-01 19:34:37 +05:00
Thomas Dinges
de80e68768 Cleanup: And one more commit... (BVH Cache). 2015-09-24 17:01:58 +02:00
Thomas Dinges
97a3fa17d6 Cleanup: Remove some more BVH cache code, for reading/writing the cache. 2015-09-24 16:49:10 +02:00
Thomas Dinges
dfadf18659 Cleanup: Remove some underlying code for the BVH disk cache.
Notes:
- There is still some bvh cache code, but that is from the engines initial commit, we might clean this up further or keep it.
- Changes in util_cache.h/.c are kept, this might be re-used in the future.
2015-09-24 15:47:27 +02:00
Thomas Dinges
3804a3660e Cleanup: Typo fixes in OpenCL log messages. 2015-09-24 15:34:41 +02:00
Thomas Dinges
3e59691df5 Cycles: Remove the BVH cache feature
This removes the BVH cache feature from the UI, underlying code will be removed in a separate commit.

The BVH cache was added before we had a multi-threaded BVH build, and a lot of other optimizations were done since then, which makes this not useful anymore.

Fix T46162.
2015-09-24 15:30:15 +02:00
Sergey Sharybin
0ec814c91d Cycles: Support building with latest OSL-1.7dev
So now the following OSL versions are supported (at least for compilation):

- 1.5 with closure alignment patch applied
- 1.6.8 release
- 1.7 development version from latest git
2015-09-23 12:27:02 +05:00
Sergey Sharybin
8da3c5c1b9 Fix T46159: OpenSubdiv does not always give same results as Blender own subsurf code with crease edges 2015-09-21 17:53:21 +05:00
726727191a Fix T43715: IK pole target + stretch not working for a single bone chain. 2015-09-21 01:59:50 +02:00
Sergey Sharybin
de7b7572c2 Fix T46030: Strange behavior of Cycles Brick Texture
Added some extra seed to the hash, so it's now less likely to give repetitive
patters at values around zero.

This will change distribution of bricks for existing files. but it's something
inevitable.
2015-09-18 17:32:17 +05:00
Campbell Barton
247b68476b Cycles: simplify logic for calculating dof-dist
Matches change from BKE_camera
2015-09-18 16:40:55 +10:00
Sergey Sharybin
3cee28ebf3 Fix T46143: Faces missing with GPU render
Epsilon was quite arbitrary for GPU, replaced with checking for zero-sized faces.

It should solve both original report and the new one. After the release we can check
why GPU doesn't produce accurate math here and go to the root of the issue.
2015-09-17 17:21:17 +05:00
Sergey Sharybin
89de6e9eac OpenSubdiv: Fix crash caused by accessing OpenGL vendor from non-main thread 2015-09-16 22:25:13 +05:00
Sergey Sharybin
cf4711bdf9 OpenSubdiv: Attempt to solve crash in background mode 2015-09-16 20:33:16 +05:00
Sergey Sharybin
0f19e6d1a7 Code cleanup, whitespace 2015-09-16 20:26:58 +05:00
Sergey Sharybin
7b3491f2c6 OpenSubdiv: Fix for missing caching of vendor string parsing result 2015-09-16 20:23:32 +05:00
Sergey Sharybin
19d17c8d90 Fllowup to previous commit, remove unused code 2015-09-16 20:20:16 +05:00
Sergey Sharybin
3f05d72a98 Fix T45708: OpenSubdiv crashes on Windows with Intel cards
Disable Intel cards for until we'll go to the root of the issue of the crash.
This will take a bit, so being so close to the release we go safe and disable
unstable GPU, so blender at least doesn't crash.

This could be bypassed by setting OPENSUBDIV_ALLOW_INTEL environment variable.
2015-09-16 19:28:40 +05:00
Campbell Barton
09e40a4956 Cleanup: spelling 2015-09-14 02:22:22 +10:00
Campbell Barton
84c44e026e Fix leak in ContextGLX 2015-09-11 01:48:31 +10:00