Commit Graph

53195 Commits

Author SHA1 Message Date
393216a6df Cycles code refactor: move more code to geom folder, add some comments. 2014-03-29 13:03:48 +01:00
663a750c7f Fix: cycles volume emission incorrectly enabling surface importance sampling. 2014-03-29 13:03:48 +01:00
a2e4ebd36a Cycles code internals: add CPU kernel support for 3D image textures. 2014-03-29 13:03:48 +01:00
07d1fba367 RNA/Smoke: add access to high resolution density grid, and flame and color grids. 2014-03-29 13:03:47 +01:00
e8b1cfed0a Cycles code refactor: replace magic ~0 values in the code with defines. 2014-03-29 13:03:47 +01:00
6997908afc Cycles: add per object options to disable motion blur and set deformation motion steps.
Notes:

* The motion steps only affect deformation motion blur.
* The actual number of steps is 2^(steps - 1). This avoids having to sample at
  many different times for object with more/fewer steps, now the times overlap.
* Deformation motion blur is enabled by default in existing files that have
  motion blur enabled. If the object is not deforming, this will be detected at
  export time, so raytracing performance will not be affected.

Part of the code is from the summer of code project by Gavin Howard.
2014-03-29 13:03:47 +01:00
e2184c653e Cycles: add support for curve deformation motion blur. 2014-03-29 13:03:47 +01:00
6020d00990 Cycles: add support for mesh deformation motion blur. 2014-03-29 13:03:47 +01:00
8f33538fab Cycles code refactor: add motion sampled normals attribute. 2014-03-29 13:03:46 +01:00
99f5993088 Cycles code refactor: improve vertex motion attribute storage and export.
This now supports multiple steps and subframe sampling of motion.

There is one difference for object and camera transform motion blur. It still
only supports two steps there, but the transforms are now sampled at subframe
times instead of the previous and next frame and then interpolated/extrapolated.
This will give different render results in some cases but it's more accurate.

Part of the code is from the summer of code project by Gavin Howard, but it has
been significantly rewritten and extended.
2014-03-29 13:03:46 +01:00
934767cf7f Cycles code refactor: change curve key to float4 for easier storage as attribute. 2014-03-29 13:03:46 +01:00
0509553b5e Cycles code refactor: changes to make adding new primitive types easier. 2014-03-29 13:03:46 +01:00
24ad7e0bea Cycles code refactor: add support for motion vertex attributes. 2014-03-29 13:03:46 +01:00
41d1675053 Cycles code refactor: move more geometry code into per primitive files. 2014-03-29 13:03:45 +01:00
84470a1190 Cycles code refactor: move geometry related kernel files into own directory. 2014-03-29 13:03:45 +01:00
Campbell Barton
2100fb4094 Code cleanup: avoid setting du/dv twice with ray intersection 2014-03-29 22:38:01 +11:00
Campbell Barton
fb0959f88d Code cleanup: replace dot with len_squared and is_zero checks 2014-03-29 22:24:12 +11:00
Antony Riakiotakis
6bba006bf2 Cleanup: Minor spelling fixes: 2014-03-29 11:56:32 +02:00
Antony Riakiotakis
6a1b7facf9 GPU_pbvh_buffers: Use triangles to render multires.
A question here might be: why?

The answer is that GPUs will convert this to triangles so we are wasting
memory during conversion of the element buffer to a triangle buffer
anyway.

The second reason is that some modern GPUs are slower rendering GL_QUADS

The third reason is that due to element caching, this should not in
theory be slower (cached elements do not get recalculated on the GPU).
2014-03-29 11:40:53 +02:00
Campbell Barton
eaaacfc7b8 UI: Color-Ramp handles
- display handles with solid color.
- active handle is highlighted.
- 1/4 of the colorband draws solid.
- use old-style handles when zoomed out.

D289 by Charlie Jolly with own modifications.
2014-03-29 15:36:50 +11:00
Campbell Barton
b64bdb2c1b Checker percentage calc was wrong, also cleanup 2014-03-29 11:25:44 +11:00
Campbell Barton
3eb2724c14 Update clang array checker for new clang py api 2014-03-29 11:08:24 +11:00
Antony Riakiotakis
aec4367226 Fix building without openmp continued 2014-03-29 00:11:35 +02:00
Campbell Barton
d3309ac5c9 Code cleanup: correct arg size 2014-03-29 08:42:59 +11:00
Jens Verwiebe
025421950b Forgot to clean a line in last commit 2014-03-28 22:42:21 +01:00
Jens Verwiebe
00a9e77259 Fix compiling sculpt without OpenMP available 2014-03-28 22:37:05 +01:00
Antony Riakiotakis
6d973b87a6 Fix T39468
Issue is that sampling functions did not pass a thread index to the
texture sampler so all threads were contesting for the same pool.

Paint cursors and sculpting that used openmp for threading suffered from
this. Now use omp_get_thread_num to pass the thread number.
2014-03-28 22:02:26 +02:00
Campbell Barton
8b43b9f255 Fix for mask vert add-slide dragging flipped direction 2014-03-29 06:44:40 +11:00
Bastien Montagne
e9d733a8bd Fix T39484: Time line: highlighted area for frame range one frame too short.
Just using same principle as the one already used for the 'cache bar': add -0.5/+0.5 offsets to start/end (also edited 'view all' op to match this).
2014-03-28 15:15:30 +01:00
Sergey Sharybin
1af69b6df3 Implement asymmetric and free handles type for masks
Summary:
The title actually says it all, it's just possible to
have independent free handles for mask splines. Also
it's now possible to have aligned handles displayed
as independent handles.

Required changes in quite a few places, but they're
rather straightforward.

From user perspective there's one really visible change
which is removed Handle Type menu from the panel. With
asymmetric handles it's not clear which handle type to
display there. So now the only way to change handle type
is via V-key menu.

Rewrote normal evaluation function to make it deal
with new type of handles we support. Now it works in
the following way:

- Offset the original spline by maximal weight
- Calculate vector between corresponding U positions
  on offset and original spline
- Normalize this vector.

Seems to be giving more adequate results and doesn't
tend to self-intersect as much as old behavior used to,

There're still some changes which needed to be done, but
which are planned for further patch:

- Support colors and handle size via themes.
- Make handles color-coded, just the same as done for
  regular bezier splines in 3D viewport.

Additional changes to make roto workflow even better:
- Use circles to draw handles
- Support AA for handles
- Change click-create-drag to change curvature of the
  spline instead of adjusting point position.

Reviewers: campbellbarton

CC: sebastian_k, hype, cronk

Differential Revision: http://developer.blender.org/D121
2014-03-28 17:54:38 +06:00
Sergey Sharybin
6e5e3b73f3 Fix T37599: Crash making linked objects local and undo
Root of the issues comes to the fact that it's possible to produce
a situation when library object data uses local object. This is
actually forbidden and not supported by .blend IO.

Made it so Make Local wouldn't produce such an unsupported states.

Reviewers: brecht

Differential Revision: https://developer.blender.org/D372
2014-03-28 17:14:11 +06:00
Lukas Treyer
97cb76a45d Bevel Factor Mapping
Bevel Factor Mapping allows to control the relation between bevel factors
(number between 0 and 1) and the rendered start and end point of a beveled
spline.

There are three options: "Resolution", "Segments", "Spline". "Resolution"
option maps bevel factors as it was done < 2.71, "Spline" and "Segments"
are new.

* "Resolution“: Map the bevel factor to the number of subdivisions of a
  spline (U resolution).
* "Segments“: Map the bevel factor to the length of a segment and to the
  number of subdivisions of a segment.
* "Spline": Map the bevel factor to the length of a spline.

Reviewers: yakca, sergey, campbellbarton

CC: sanne

Differential Revision: https://developer.blender.org/D294
2014-03-28 16:44:33 +06:00
Campbell Barton
3977b7612f Fix T39288: Inset regression with extreme offset 2014-03-28 21:38:12 +11:00
Campbell Barton
2a25676168 Fix for inset bug (edge rail had feedback loop with direction)
also disable edge-rail by default.
2014-03-28 21:38:12 +11:00
Sergey Sharybin
f88776bb5c Fix T39410: Crashes when Saving HiRes .tif 2014-03-28 15:22:10 +06:00
Lukas Tönne
29888dcea0 Fix T39455: Nodes scaled wrong when some in a frame, some not.
Transform operators for nodes were not taking parent nodes (frames) into
account. Now use the nodeToView/nodeFromView functions to apply
transforms in local node space.
2014-03-28 10:07:11 +01:00
Sergey Sharybin
f0106d2985 Unbreak carve build for clang
Based on D420
2014-03-28 14:41:04 +06:00
Sergey Sharybin
6babbf59bc Fix T39472: Changing Sequencer color space repeatedly changes movie strip's display gamma
Issue was caused by the old color space settings being lurking around
seq->anim after the changes in color space settings.
2014-03-28 13:58:39 +06:00
Mitchell Stokes
93c896d53b BGE code cleanup: Removing an unused include in KX_Light.cpp 2014-03-27 22:44:30 -07:00
Mitchell Stokes
df9d6737b9 BGE code cleanup: Removing OpenGL and bf_gpu code from KX_LightObject
The ultimate goal is to only allow the rasterizer to handle OpenGL and bf_gpu
calls. This commit creates a RAS_ILightObject interface and a RAS_OpenGLLight
implementation.
2014-03-27 22:32:06 -07:00
Campbell Barton
3ec0c73211 View3D: replace RV3D_VIEW_PERSPORTHO with RV3D_VIEW_USER
This is hardly used, and may be removed later (looks like quad view used by accident).

It could cause the 2d grid to draw with the view at an angle.
2014-03-28 15:57:33 +11:00
Campbell Barton
ac07046e55 BMesh: optimize quad_coord, avoid duplicate sqrt calls 2014-03-28 15:25:02 +11:00
Campbell Barton
5981567ec6 Code cleanup: use len_v2v2_int for view zoom-scale 2014-03-28 15:02:57 +11:00
Campbell Barton
7199e2288f Code cleanup: use sqrtf when input and output are float 2014-03-28 14:53:37 +11:00
Campbell Barton
e6e7438181 RNA API: rename Sequence.elements.push() -> append()
also for SpaceNodeEditorPath
2014-03-28 12:11:52 +11:00
Walid Shouman
f4a990bfcd Fix for curve smooth ignoring cyclic 2014-03-28 09:26:45 +11:00
Mitchell Stokes
7ff123ce5c Fix T39452: Meshes without materials causes a memory leak in the game engine
These types of meshes do not use material caching, and thus only the first created
material would be saved, but subsequent ones were not. Those subsequent materials
were then not being freed. Now we make sure to track all of the materials.

Note: Meshes that cannot make use of material caching (no materials or using face textures)
can still use up a large amount of RAM since a material is created per face.
2014-03-27 13:51:07 -07:00
Sergey Sharybin
84823220b8 Attempt to fix compilation error on release windows
MSVC was yelling on me because of unused variable.
2014-03-27 19:14:20 +06:00
Sergey Sharybin
bcf6eedc48 Make blender compilable with FFmpeg-0.8.1
Needed for some own tests.
2014-03-27 19:12:21 +06:00
Sergey Sharybin
d3a73d0845 Windows: Upgrade FFmpeg from 0.10 to 2.1.4
Fixes T39423: Blender crashes on iv41 encoded videos in thumbnail display mode

Libraries are still being committed to the svn, so compilation might be broken
for a while. Sorry for this, but can't really be avoided.

Also, some typos in scons are possible.
2014-03-27 16:52:59 +06:00