Commit Graph

10582 Commits

Author SHA1 Message Date
0c51010c67 Fix video FFmpeg nt being able to produce video files due to usage of deprecated settings 2014-04-15 00:15:09 +06:00
4863253c2f Fix T39702: VSE channel preview: strips used as effect operands no more visible 2014-04-14 17:50:47 +06:00
7c78bcef6c Fix for crash un-indenting in the text editor 2014-04-14 13:28:09 +10:00
6f153046e0 Reduce overhead when sampling texture images for brushes. The tests can
be cached and reused.
2014-04-13 19:03:14 +03:00
41b8f88732 Split Normals I (3/5): Add 3Dview shading support of split normals.
Mostly monkey coding in gpu ("modern" VBO drawing) and DM variants ("legacy" drawing) code...

Reviewers: brecht

Reviewed By: brecht

CC: campbellbarton

Differential Revision: https://developer.blender.org/D367
2014-04-13 12:34:45 +02:00
0b7f581397 Split Normals I (2/5): Add basic BMesh support of split normals.
* Merely a re-implementation of core split algorithm for BMesh, taking advantage of topological data available.
* This code needs valid loop indices, so added BM_LOOP support to BM_mesh_elem_index_ensure() & co.

Reviewers: campbellbarton

Reviewed By: campbellbarton

CC: brecht

Differential Revision: https://developer.blender.org/D366
2014-04-13 12:25:54 +02:00
18e4224142 Split Normals I (1/5): basis for split normals (nearly nothing user-visible here):
* Add a new calcLoopNormals function to DerivedMesh struct, and implement it for CDDM and CCGDM (subsurf).
  EditDerivedBMesh (edit mode DM) only gets a dummy one in this commit.
* Add a tessellated version of CD_LOOPNORMAL layer (CD_TESSLOOPNORMAL), with relevant code to handle it
  (tessellation, rna access, etc.).
* Change auto_smooth options of Mesh (angle now in radian internaly, and toggle is now used to enable/disable
  split normals in DM creation process). Note BI render code is not touched here, hence its behavior regarding
  this option is now incoherent, will be addressed in a separate commit.

Reviewers: campbellbarton

CC: brecht

Differential Revision: https://developer.blender.org/D365
2014-04-13 12:19:00 +02:00
2025e4cbb9 Code cleanup: quiet warnings & style 2014-04-13 11:26:31 +10:00
0b50ea5a88 Fix redraw and undo issues with hidden parts in dyntopo after recent
changes.
2014-04-11 15:02:31 +03:00
a3f5e6c76f Fix T39266: Weird Skin modifier shutdown
Fix wrong quat being calculated for curve's path.
Also avoid some divisions by zero.

Happened in cases when all the curve points have the same coord.
2014-04-11 17:56:08 +06:00
4f6c218f19 Fix T39584: Effects strips render black
It's possible that effetc strip would be placed to the same
'machine' as it's inputs. We don't want to clear such strips
from the stack.
2014-04-11 16:26:57 +06:00
93ea10d8fb Fix for rigidbody treating the quat as a v3 with pointcache 2014-04-11 18:20:30 +10:00
3216e4b202 API Cleanup: Use BKE_constraint prefix for constraint api 2014-04-11 11:47:07 +10:00
a15b3c4d11 Code cleanup: use bool 2014-04-11 11:33:29 +10:00
7cdaf56b30 Dyntopo: use hidden face flags in more places 2014-04-11 07:51:14 +10:00
6292b60a3f Dyntopo: Minor display optimization.
While hiding, flush the hidden flags to the faces. This avoids iterating
through all the loops while updating the GPU buffers.
2014-04-10 22:31:39 +03:00
df63e8fd93 Speedup track preview widget for byte images
This gives a huge speedup gain for cases when you've got
rather huge markers on a byte images.

Done by skipping IMB_float_from_rect()/IMB_rect_from_float()
for such cases. We can sample the buffers without color space
conversion.
2014-04-10 21:14:36 +06:00
9b60174e75 BMesh: DM_to_bmesh_ex, no need to calloc 2014-04-10 11:35:17 +10:00
82628a6b0e Code cleanup: use struct type for mempool & style edits 2014-04-10 06:49:25 +10:00
1c811d96b2 Make material array account for mesh/object storage of materials 2014-04-09 18:37:54 +03:00
9de24c82ba View3D: disable LOD when game engine is disabled or ifdef'd 2014-04-09 11:52:34 +10:00
b5d3f183b0 Add material storage to derivedmesh.
The variables are considered invalid unless DM_update_materials is
called prior to use. Only use case currently is
mesh drawing. This helps with excessive allocation on the stack during
GPUObject creation, but may help elsewhere in the future as well.
2014-04-09 04:03:44 +03:00
ebaf3781fa Dyntopo: replace GHash with GSet, saves some memory 2014-04-08 14:45:48 +10:00
593b698b44 DerivedMesh: replace edgehash with edgeset 2014-04-08 14:45:04 +10:00
412826a504 Mempool: delay allocating an initial chunk, its not always used 2014-04-08 12:58:56 +10:00
1e6d2b1dbf Code cleanup: remove paranoid NULL check 2014-04-08 07:46:28 +10:00
c61eb64f06 Fix T39635: Crash convening curve to mesh 2014-04-08 07:41:38 +10:00
6eb20ca048 Fix own broken rB95b25e7333c4 (crash on any undo op :/).
Issue here was that buttons_texture_context_compute() was getting scene from (button-customized) context,
before the button paths (and hence, context) had been updated. So after an undo, it was getting an invalid
(freed by undo) scene pointer.

Now update BCONTEXT_SCENE path before calling buttons_texture_context_compute().
2014-04-07 17:17:40 +02:00
ea01b24bba Fix T39623: deleting an object crashes 2014-04-07 20:25:52 +10:00
95b25e7333 Fix T39562: Properties panel Pinning is broken
'scene' was simply not handled in button context.
2014-04-07 12:23:24 +02:00
8714ae09f8 Fix T39563: Tiny unit-display problem in constraint panels.
There is no good solution here, since RNA props can only have one type/unit.
Tried to find the less worse one - have different RNA props for same DNA value
(a bit like the angle/length for camera lens).

Also fixed two other issues with Transform conctraint:
* Angle were still in degrees (yes, another backward-compatibility breacking).
* Scale was absolute, unlike loc/rot.

Also cleaned up a bit the code, replaced some magic numbers by proper enums, ...
2014-04-07 12:17:01 +02:00
b95e826841 Code cleanup: remove unused functions and convert int -> bool 2014-04-07 17:00:08 +10:00
2527d0ce8f Dyntopo: minor speedups with bmesh use. 2014-04-07 13:48:36 +10:00
212717416b Dyntopo: avoid mask layer lookups while adding/removing verts 2014-04-07 13:05:39 +10:00
07f8c5c3b6 Better code for (bone axis + roll) to mat
See T39470 and D436. Code by @tippisum, with some minor edits by @mont29.

Tested with various rigs, including Rigify, CGcookie flex rig, and gooseberry/pataz caterpillar.

Riggers, please test it, no change expected in behaviour.

Reviewers: aligorith

CC: tippisum

Differential Revision: https://developer.blender.org/D436
2014-04-06 19:15:50 +02:00
1e504bc123 Dyntopo: minor optimizations for edge queue 2014-04-05 16:30:55 +11:00
61c73b49d3 Remove redundant call to CustomData_get_offset 2014-04-05 12:32:25 +11:00
af59ee340f Mempool: remove BLI_MEMPOOL_SYSMALLOC, MEM_* allocs are more efficient now 2014-04-05 12:14:05 +11:00
321c35ec6c Solve issue with dyntopo collapse.
It was possible to delete a masked vertex during collapsing. Looks like
this is one of the causes for hangs during masked flood filling.
2014-04-05 02:31:36 +03:00
71a2ff12a8 Fix crash happening in DAG_pose_sort() due to threading issues
This function used ugly hack with static variable which was
preventing some type checks in DAG nodes. Using this variable
form multiple threads is not considered safe, apparently.

Solved by moving this variable inside the DAGForest structure.
so it's global for the graph now, but different graphs does not
run into conflicts.

This required passing the forest to some functions, which doesn't
look so much nice, but don't want to spend time on making this
code look beautiful because it is really to be replaced by the
new dependency graph.

This is really bad bug actually which is must go to 'a'.
2014-04-04 12:46:08 +06:00
45b02cee47 Code cleanup: no need to use calloc when memory is initialized after
also replace AT with __func__ since AT expands the full pathname
2014-04-04 14:26:01 +11:00
2bba04f1b0 Cloth: replace EdgeHash with EdgeSet 2014-04-04 14:15:57 +11:00
f38331adef Code cleanup: style 2014-04-03 09:24:09 +11:00
03bd418d16 Fix T39517,
Issue here is that "show diffuse" option does not respect its intended
purpose which is to be used only for masking.

There are a couple of caveats here:

Dyntopo and multires -always- have mask data enabled, and thus as soon
as one goes to dyntopo mode or adds a multires modifier he would get the
default grey color instead.

Matcaps would break when nodes asked for a diffuse material color (this
was broken before too). Solved by adding global material state for when
matcaps are enabled. Also matcaps don't always played well with VBOs
off.

Added a few more missing updates for mask operators to notify
show_diffuse property as changed. This was also needed on rebuilding
dyntopo pbvh.

Also make zero mask color duller again after artist feedback.
2014-04-03 00:39:42 +03:00
8c730b1059 Fix T39520, show diffuse not working in dyntopo.
Was marked as a todo in the code.

This does not yet take care of correct display for multi material
meshes, since it would need correct separation of faces during pbvh
creation. Instead we just take material of first face in node and assume
that the rest faces have the same. This will create some funky effects
if one attempts to sculpt in this way.

Note: This does not yet address T39517
2014-04-02 18:56:19 +03:00
4faef1e10c Add drag-resize to uiTemplatePreview (mat/tex/etc. preview widget).
This is done by adding a new button type, GRIP, similar to other numbuttons
(scroll, slider, ...), which here controls the preview height.

Then, we add a new DNA struct to be able to save that height in Blend files
(note I choose not to use Panel struct for this, because we would then have the
same limitation we used to have with uiLists, only one preview per panel
and no preview outside panel).

This implies a change to template_preview UI RNA/py API (each preview needs an ID),
but this is backward compatible, as by default datablock type will be used if no ID is
given (which means e.g. all material previews with no ID will have same height).

Reviewers: brecht

Reviewed By: brecht

Differential Revision: https://developer.blender.org/D342
2014-04-02 13:03:11 +02:00
11ee2d8b97 implement cache line for image editor
It works exactly the same as a cache line in movie clip editor.
2014-04-02 16:54:30 +06:00
35747ee3d5 Rename "BLI_cpu.h" to "BLI_system.h" and add to it BLI_getpid() helper.
There is not much sense to have a whole BLI file just to check SSE2 on CPUs...
So idea is to rename it to more generic "BLI_system", and add to it more system-related
utils, like e.g. an include helper for getpid(), which allows to hide unix/windows
internals from rest of the code...

Reviewers: campbellbarton

Reviewed By: campbellbarton

Differential Revision: https://developer.blender.org/D439
2014-04-02 11:59:43 +02:00
cb7cfd3ab6 Cycles: add dedicated UV Map node, easier to find and has convenient auto complete.
Fixes T37954.

Reviewed By: brecht, dingto

Differential Revision: https://developer.blender.org/D230
2014-04-02 11:53:44 +02:00
eed3974d11 Fix T39545: "Track selected markers", does not stop at end of video
Issue was cauzed by some weird clamping of current frame. Not sure
why it was here at the first point -- it's from the day0 of movie
clip datablock.
2014-04-02 14:11:35 +06:00