Commit Graph

52002 Commits

Author SHA1 Message Date
Lukas Toenne 6fe753c11b Extended the draw callback API for node sockets with an explicit text parameter, instead of always using the sock->name string. This can be useful for drawing the socket values separate from the label, e.g. in the node view template. 2013-05-08 14:58:41 +00:00
Lukas Toenne 672d393517 Change to socket draw functions: instead of always only drawing the socket label for connected sockets, leave this check up to the socket draw function itself. This allows future socket types to draw buttons or other info in all cases and handle connected/unconnected state more flexibly.
The drawinputfunc/drawoutputfunc callbacks in bNodeType are pretty much empty wrappers now and should be removed at some point. This per-node differentiation should rather be implemented as a specialized socket type if necessary. The only use case for this feature that remains is the file output node in compositor, which displays shortened file format info for each socket.
2013-05-08 14:58:37 +00:00
Campbell Barton 0ee45c9301 more optimal method of calculating the normal for the solidify modifier.
When adding 2 unit length vectors, the length can be used to calculate the angle.
2013-05-08 14:33:02 +00:00
Sergey Sharybin f25e7d62b3 Mask modifier for sequences
This modifier uses a mask set in the modifier settings
and multiplies strip by it. Alpha channel will also be
multiplied by mask, which makes it easy to mask some
objects on footage and alpha-over them in sequencer.

Actually, this modifier sets alpha for byte strips
directly (since byte is always straight alpha) and
multiplies float buffer by mask (flaots are premulled)
so in both cases masked strip could be easy alpha-overed
without any artifacts.

It uses own structure with only SequenceModifierData
property in to preserve both forward and backwards
compatibilities (using new structure ensures modifier
will be ignored on load in older blenders, the same
happens for mesh modifiers actually).

Request from Pablo Vazquez.
2013-05-08 14:20:57 +00:00
Lukas Toenne 89eb80fb68 Fix for #35253, Cannot animate X, Y, Z values in nodes with vector sub-menu. The "component menu" template used for these socket buttons opens a popup, but this ui function does not support RNA info directly. Setting the uiBut rna pointer directly solves it. 2013-05-08 14:18:09 +00:00
Campbell Barton 7bd7da7cc6 code cleanup: dissolve - use iterator macros, remove unused function. 2013-05-08 14:08:37 +00:00
Campbell Barton 7dbf6d513e mesh dissolve vertices: option to split off corners of surrounding faces, makes the result more localized to the area around the vertex. 2013-05-08 14:01:38 +00:00
Campbell Barton 8193d83cd9 split dissolve into 3 different operators (face/edge/vert). 2013-05-08 13:48:57 +00:00
Brecht Van Lommel 4d842df17e Fix #35219: blender internal auto ray bias to avoid the terminator shadow
problem was giving light flickering on a mesh with animated hair strands.

Now strands are not used to compute this auto bias excluded from this, from
tests it does not seem to be helpful for hair and only gives issues.
2013-05-08 13:23:20 +00:00
Brecht Van Lommel a07dcd67eb Fix #35240: command line -t number of threads option did not work for cycles.
Now it works for blender internal, cycles and other multithreading code in
Blender in both background and UI mode.
2013-05-08 13:23:17 +00:00
Brecht Van Lommel 3e763d7e4d Fix #35246: cycles has no simple way to combine bump and normal mapping. Now
the Bump node has a Normal input, so you can chain it after a Normal Map node.
Note that normal mapping always has to be done first because it is tied to the
particular mesh surface and tangents.
2013-05-08 13:23:13 +00:00
Campbell Barton 28617bd710 fix for recent commit, WITH_GUARDEDALLOC wasn't enabled for makesrna, makesdna. 2013-05-08 13:19:55 +00:00
Sergey Sharybin a9a0e2d98f Fix #35093: New Basis shape key doesn't act as Basis
Made it so Move Shape Key ensures first key is a refkey,
so now it's possible to change basis key from the interface.

It's still needed to manually teak key's relative_key,
not sure whether there's a reliable automated way to tweak
this value when bassi key is changing.
2013-05-08 13:16:45 +00:00
Sergey Sharybin a63be29da3 Fix #35252: Crash with the node placed partially behind the screen
Issue was caused by negative maximal possible text width happening
in label clipping.

Solved by clamping width to 0 if it's negative.
2013-05-08 13:16:39 +00:00
Campbell Barton 13ddfa921e fix [#30862] "Lock" and "Box" Quad View options won't stay put when toggling 2013-05-08 13:01:05 +00:00
Campbell Barton 562ed2b42e add in asserts when rv3d->viewmatob, rv3d->persmatob are not initialized.
This is often hard to spot since in many cases it works correctly even
when not initialized but may still fail in other situations.
2013-05-08 13:00:52 +00:00
Campbell Barton a4634bfe67 code cleanup: ui_but_is_rna_undo --> ui_is_but_rna_undo (ui_is_but_*** is used elsewhere) 2013-05-08 13:00:33 +00:00
Campbell Barton 8ac2fee57a minor speedup for bmesh - add CustomData_bmesh_free_block_data(), use
when the block would be immediately allocated again.
2013-05-08 13:00:25 +00:00
Campbell Barton 8d0de0c3cf code cleanup: remove ShapeActionActuator, they are now versioned out. 2013-05-08 13:00:14 +00:00
Campbell Barton 9514a28e4f code cleanup: remove redundant check in writedata(). 2013-05-08 13:00:06 +00:00
Campbell Barton f554c264da speedup for freeing bmeshes, skip calling free on every
vert/edge/face/loop if there are no free functions for the customdata
layers.
2013-05-08 12:59:56 +00:00
Campbell Barton c6702a3b91 use BM_face_create_ngon_verts for python api face creation
(avoid doing it inline).
2013-05-08 12:59:46 +00:00
Campbell Barton f74201190d code cleanup: remove references to BLI_rand.h 2013-05-08 12:59:35 +00:00
Campbell Barton e4aff35020 smooth falloff options for loopcut. 2013-05-08 12:58:28 +00:00
Campbell Barton a9fb183901 rename BLI_ghashIterator_notDone() -> BLI_ghashIterator_done()
was renamed fairly recently but other similar iterators not negated
	like this, would prefer to keep it as it was
2013-05-08 12:58:11 +00:00
Campbell Barton df664fa6d5 use bool for customdata functions. 2013-05-08 12:57:18 +00:00
Campbell Barton 4daf1958cf de-duplicate draw_new_particle_system() particle drawing. 2013-05-08 12:57:07 +00:00
Campbell Barton 76b1e8bc09 code clenup: rename BKE_mesh_poly_calc_angles -> BKE_mesh_calc_poly_angles 2013-05-08 12:56:51 +00:00
Campbell Barton f433f011cf add option to only beauty fill between vertices with non-matching tags,
useful for beauty filling the result of a bridge between 2 edge-loops.
2013-05-08 12:56:41 +00:00
Campbell Barton df502ffd5f knife tool: use faster method for sort_by_frac_along(), no need to call
line_point_factor_v3().
2013-05-08 12:56:31 +00:00
Campbell Barton a2221cad15 knife tool: use the squared distance for comparison. 2013-05-08 12:56:24 +00:00
Campbell Barton 02c1e6162c knife tool: use 2d vectors for screen coords. 2013-05-08 12:56:17 +00:00
Campbell Barton fdc4eea188 use smaller size for uiWidgetTrias.vec 2013-05-08 12:56:11 +00:00
Campbell Barton 7fac200080 remove unused define CLAMPTEST, move INPR to
collision_compute_barycentric(), only place its used.
2013-05-08 12:56:02 +00:00
Campbell Barton 3b341068ba warn of sign conversions for low level apis - ghash, heap, mempool 2013-05-08 12:55:51 +00:00
Campbell Barton 89c8de1f48 add matrix multiply for projection that outputs 2d values. 2013-05-08 12:55:36 +00:00
Campbell Barton 357655af32 use static functions for raycast functions. 2013-05-08 12:55:05 +00:00
Campbell Barton 8238cd6992 use unsigned int, for mask rasterizer. 2013-05-08 12:54:47 +00:00
Campbell Barton 5c4f96af2c code cleanup: use 'const float[2]' where possible. 2013-05-08 12:54:33 +00:00
Campbell Barton 62db610220 use unsigned int's for smallhash, avoids using ABS when converting an
int from a key.
2013-05-08 12:54:07 +00:00
Campbell Barton 6b1b20ef0d code cleanup: BKE_mesh_nurbs_displist_to_mdata(), use const bool for
'conv_polys'
2013-05-08 12:53:52 +00:00
Campbell Barton 67ec36a615 use negative dot product for clipping, rather then doing it inline. 2013-05-08 12:53:43 +00:00
Campbell Barton 3e4db4969c code cleanup: remove unused 'dm' arg from BVHTreeFromMesh. 2013-05-08 12:53:34 +00:00
Campbell Barton cf3d638681 remove unneeded null check in draw_viewport_name 2013-05-08 12:53:14 +00:00
Campbell Barton 34c28e3a0e fix [#35259] Crash when enabling mesh analysis intersect. 2013-05-08 12:40:23 +00:00
Brecht Van Lommel fdcca14090 Fix #35255: build for older OpenCollada versions failed, but don't see a good
reason to not keep it working.
2013-05-08 10:07:58 +00:00
Brecht Van Lommel 13c0ef139f Fix OS X 32 bit build error, and bring buildbot config in sync with default. 2013-05-07 18:32:37 +00:00
Ton Roosendaal aa959b4e7d Putting undefined versioning to only older than 2.67. 2013-05-07 16:35:37 +00:00
Ton Roosendaal a0800cb8b3 And here's the epic 2.67 splash and version!
Celebrating Freestyle :) Kudos to dfeveloper Tamito and Malaysian artist Mclelun!
2013-05-07 16:27:55 +00:00
Sergey Sharybin 5455928262 Fix #35122: Blenderplayer crashes when loading level
Issue was caused by ntreeUpdateTree calling for a ntree
which is not in G.main.

This lead to issues in ntreeVerifyNodes (which is called
from ntreeUpdateTree).

Made is so ntreeUpdateTree now accepts main as an argument.
Will work for the release, later we could either solve the
TODO mentioned in ntreeUpdateTree which will eliminate need
in main there or make it so context's main is used from all
over where ntreeUpdateTree is called (currently there're
still some usages of G.main).
2013-05-07 15:28:42 +00:00