Campbell Barton
8ff099bc7b
BoxPack: avoid using static vars (make threadsafe)
2015-02-08 17:07:47 +11:00
Campbell Barton
aab4f2b762
cleanup: redundant casts & const cast correctness
2015-01-01 23:42:28 +11:00
Antony Riakiotakis
33df6aa12e
Fix T39196, Dynamic Topology Undo Applied to Wrong Mesh
...
Undoing nodes that do not belong to the current object will cause the
saved bmesh log entry to be reverted instead. This entry can belong to
another object though.
This is easy to fix by enforcing name matching (this was borrowed by
edit mode but can definitely be improved) between current object name
and undo node name and deleting older entries.
However there are complications. Deleting dyntopo entries in this way
can leave a brush stroke as first dyntopo log entry. This can present
issues if we attempt to delete that entry since it's deleted mesh
elements may now have had their ids (which would still be valid at the
time) cleaned up. This can result in crashing if we attempt to resculpt
on the mesh. To fix this I have disabled releasing the deleted entries.
This entanglement between bm_log and undo is quite volatile but I hope
the system works better now.
Also minor cleanup, fix unneeded check warning
2014-05-13 22:05:23 +03:00
Campbell Barton
dd86773969
BoxPack: replace macros with functions
...
also correct error merging vertices
2014-04-26 00:25:49 +10:00
Sergey Sharybin
fe52e64f6b
Revert previous change after discussion with Campbell
...
Let's just be really verbose and it some compiler gives
issues tell him NOT to do this.
We shouldn't really workaround compiles' idiocy..
2014-04-25 17:16:06 +06:00
Sergey Sharybin
9d335dffa4
Fix strict flags compilation error in box pack
...
No need to check q >= 0 in quad_flag() since q is
an unsigned int argument.
2014-04-25 17:02:18 +06:00
Campbell Barton
ae71729c8b
BoxPack: add bias, fixes erratic placement with identical boxes
2014-04-25 03:20:51 +10:00
Campbell Barton
69de54f99a
BoxPack: remove unusable vertices while packing
...
avoids having to check placing boxes there.
2014-04-25 03:13:35 +10:00
Campbell Barton
e6c1a23341
BoxPack: add support for merging verts as they are packed in
...
Reduces the number of vertices to pack boxes into.
2014-04-25 03:13:35 +10:00
Campbell Barton
d5647a37b4
BoxPack: flag verts used in packed boxes
2014-04-25 03:13:35 +10:00
Campbell Barton
72e9052713
BoxPack: remove quad_flags array, replace with inline bit-shift
2014-04-25 03:13:35 +10:00
Campbell Barton
6c57ee53bf
Box Pack: Improve when packing boxes of the same size
2014-04-25 03:13:35 +10:00
Campbell Barton
f895bc54cd
code cleanup: boxpack, pack struct and use unsigned ints
2013-10-11 00:22:00 +00:00
Campbell Barton
92d94ccb08
misc minor changes
...
- make cmake osx use of -ftemplate-depth match scons.
- use array size within sizeof(), more compact.
- replace AT with __func__ where the function is unique enough.
- BLI_box_pack_2D -> 2d to match other functions.
- rename new mesh normal calculation to mesh.calc_normals_split()
2013-09-10 19:23:39 +00:00
Campbell Barton
9d04a61f36
use strict flags for lasso, boxpack, gsqueue and quadric's.
...
for lasso also use unsigned ints rather then shorts for the path length.
2013-09-01 03:43:10 +00:00
Campbell Barton
f70d2c65d8
rename api functions...
...
- minf, maxf, mini, maxi --> min_ff, max_ff, min_ii, max_ii
2012-10-23 13:28:22 +00:00
Campbell Barton
d599b643b7
style cleanup: bge, switch statements mostly.
...
also left bmesh decimator on in previous commit.
2012-10-21 07:58:38 +00:00
Campbell Barton
25c96bc9f3
code cleanup: remove unused macros, commet some which may be useful later - or good to keep for completeness. quieted some warnings and add flags -Wmissing-include-dirs and -Wno-div-by-zero to cmake/gcc
2012-09-20 01:02:39 +00:00
Campbell Barton
74c9c24d27
style cleanyp
2012-06-23 23:22:19 +00:00
Campbell Barton
5534701e5d
style cleanup: use capital camel case names for typedef's
2012-06-10 15:20:10 +00:00
Campbell Barton
bddc7dfc20
style cleanup: remaining BLI files.
2012-05-12 15:13:06 +00:00
Campbell Barton
4c5502bfd6
code cleanup: function naming for BLI functions.
2012-05-05 00:23:55 +00:00
Campbell Barton
c7988dc1ac
style cleanup
2012-03-10 14:43:12 +00:00
Campbell Barton
95670e03a0
style cleanup / comment formatting for bli/bke/bmesh
2012-03-03 20:19:11 +00:00
Campbell Barton
ea13ec1699
Spelling Cleanup
2012-03-01 12:20:18 +00:00
Campbell Barton
3f1584c758
fix 2 bugs
...
- box packing wasn't flagging out the right free corner of a vertex in some cases.
- tex_space_curve wasn't counting quad displists properly.
2012-01-20 22:09:30 +00:00
Campbell Barton
309f3f31e7
remove redundant trailing slashes
2012-01-12 06:11:08 +00:00
Campbell Barton
4a04f72069
remove $Id: tags after discussion on the mailign list: http://markmail.org/message/fp7ozcywxum3ar7n
2011-10-23 17:52:20 +00:00
Campbell Barton
f9f771cd01
converted more mixed tab/space indentations to tabs. only whitespace changes.
2011-04-21 15:53:30 +00:00
Nathan Letwory
7900b5949f
doxygen: blender/blenlib tagged.
2011-02-27 20:37:56 +00:00
Campbell Barton
7daabec534
mesh validation: bugfix for removing doubles, another fix coming...
2011-02-10 12:34:52 +00:00
Campbell Barton
8cf1184c04
bad spelling; 'indicies' --> 'indices'
2011-01-18 01:58:19 +00:00
Campbell Barton
a7ceeafd71
- correct typos in comments.
...
- move boxpack struct out of the public header.
2011-01-02 11:06:50 +00:00
Campbell Barton
1e9bf0cfdb
spaces -> tabs, (4 spaces == 1 tab, only for white space preceding text)
2010-03-22 09:30:00 +00:00
Campbell Barton
081c1205a3
correct fsf address
2010-02-12 13:34:04 +00:00
Campbell Barton
4f47f21d44
small corrections, no functionality change
2009-11-12 12:48:39 +00:00
Campbell Barton
dfc7d63911
- typos in boxpack comments (incorrectly had comment that it was from NAN)
...
- removed unused defines STREQ, STREQ2, STREQ3 and MINSIZE
2009-08-16 08:36:08 +00:00
Campbell Barton
e632b966ec
BKE_global.h include path wasnt correct. made boxpack2d.c a bit more
...
readable. no functionality changes.
2008-08-02 21:39:01 +00:00
Campbell Barton
ac71783e8d
last commit had a typo, also adjusted teh and colour instances
2008-05-12 21:12:10 +00:00
Chris Want
5d0a207ecb
Patch from GSR that a) fixes a whole bunch of GPL/BL license
...
blocks that were previously missed; and b) greatly increase my
ohloh stats!
2008-04-16 22:40:48 +00:00
Campbell Barton
f8b13d57cb
added stdlib.h header, comments and all lines < 80 chars.
2007-03-22 03:28:34 +00:00
Campbell Barton
903a8ed1fd
missing x/y setting for the first box
2007-03-21 17:11:25 +00:00
Campbell Barton
ca94d97049
moved the boxpacker from PyAPI's Geometry to BLI_boxpack2d
...
made LSCM UV Unwrapper use boxpack2d
2007-03-21 17:06:02 +00:00