Commit Graph

2801 Commits

Author SHA1 Message Date
Campbell Barton
95b93b5d46 Add BLI_compiler_compat.h to help with portability 2014-05-02 01:14:15 +10:00
Campbell Barton
af86b008b2 Include removal gave problems with windows, ifdef some back in for windows only 2014-05-01 07:21:08 +10:00
Campbell Barton
cb48c0ceea Revert "Fix msvc 2013 compiler errors after the ingenious cleanup in 4ca67869cc7a."
This reverts commit a47a4ef82f.
2014-05-01 07:20:46 +10:00
Thomas Dinges
a47a4ef82f Fix msvc 2013 compiler errors after the ingenious cleanup in 4ca67869cc. 2014-04-30 23:16:12 +02:00
Campbell Barton
4ca67869cc Code cleanup: remove unused includes
Opted to keep includes if they are used indirectly (even if removing is possible).
2014-05-01 04:47:51 +10:00
Campbell Barton
409fb4da0c Code cleanup: remove redundant matrix initialization 2014-04-29 18:13:20 +10:00
Campbell Barton
7712d86512 Error in last commit, need to take duration into account 2014-04-29 06:05:54 +10:00
Campbell Barton
6600fe0de5 Correction to last commit 2014-04-29 05:48:25 +10:00
Campbell Barton
89b3dcaf82 f-curve easing: Adjustments to Robert Penner elastic easing
Compensate for the clamped amplitude by blending the elastic effect.

Allows for a subtle elastic effect which wasn't possible before.
2014-04-29 05:40:46 +10:00
Campbell Barton
e158fbf934 f-curve easing: make ease in/out expressions consistent 2014-04-29 03:21:32 +10:00
Campbell Barton
b5feb1940d f-curve easing: make ease-out symmetrical to ease-in 2014-04-29 03:20:11 +10:00
Campbell Barton
1b63a5d815 Fix for f-curve elastic ease in/out discontinuity 2014-04-29 02:55:59 +10:00
Campbell Barton
28322c1496 Convex Hull 2D: avoid calling qsort twice 2014-04-29 00:35:32 +10:00
Jens Verwiebe
835765926f Final overlooked cleanup for last commit 2014-04-27 18:44:23 +02:00
Jens Verwiebe
f3798fa45e Revert the testing sculpt openmp thread control and limit for OSX to physical threads as in 2.70a tag 2014-04-27 18:39:03 +02:00
Campbell Barton
d7d2e71a03 Correct some errors in auto-cleanup 2014-04-27 22:02:59 +10:00
Campbell Barton
b6e967be63 Code cleanup: const args and arrays 2014-04-27 08:56:54 +10:00
Campbell Barton
483d8da9bc Code cleanup: use 'const' for arrays (blenlib) 2014-04-27 00:25:15 +10:00
Campbell Barton
1e3904677c Avoid integer overflow in build_implicit_tree_helper 2014-04-26 06:55:36 +10: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
f2c483d108 Fix T39429: Project paint error with UV bleed 2014-04-23 04:33:07 +10:00
Campbell Barton
421c42bc16 Math Lib: move barycentric_weights_v2_persp to into math_geom 2014-04-23 02:10:40 +10:00
Campbell Barton
551096d6fd BLI_open: check returned value for -1 instead of < 0 2014-04-22 16:40:17 +10:00
Campbell Barton
9bff19fbfd GHash, Edgehash: add lookup_default() funcs.
Returns a fallback argument when the key isn't found.
2014-04-22 01:36:59 +10:00
Andrea Weikert
5afb0abfbd Basic support for UNC paths on Windows
Differential Revision: https://developer.blender.org/D298

Allows users on Windows to enter UNC paths in the filebrowser and to link to .blend files on a UNC path. Functionality is limited still, we can't browse the network yet and have no support to check user rights so far.

What works:
- enter an UNC path in the file browser manually or via copy/paste
- navigation within the UNC share subfolders
- link to a file on a UNC share

What does not (yet) work:
- browse the network for computers and shares
- browse to a folder that requires entering user credentials

Contributors:
Rob McKay - original patch
Campbell Barton - style fixes

Reviewers:
Campbell Barton, Brecht van Lommel
2014-04-21 17:06:09 +02:00
Campbell Barton
25c9ea8cb3 GHash, EdgeHash: hint on unlikely branch
also avoid searching buckets for empty hashes
2014-04-21 02:50:07 +10:00
Campbell Barton
55d75f5020 Code cleanup: correct abs use
also minor cleanup to rotation code
2014-04-21 02:02:21 +10:00
Campbell Barton
f77207b1c3 Math Lib: faster version of rotation_between_vecs_to_mat3
Use axis/angle calculation but avoid calls to sin/cos
2014-04-20 20:56:40 +10:00
Campbell Barton
a51a0ca772 Math Lib: add shell_v3v3_normalized_to_dist and v2 version
bypass angle calculation to avoids (asin, sqrt, cos).
2014-04-19 22:17:10 +10:00
Campbell Barton
d6a53bb38f Minor change to recent commit (avoid transpose) 2014-04-19 19:48:07 +10:00
Campbell Barton
0ed6725aae Math Lib: minor optimization to barycentric_transform
replace rotation_between_vecs_to_quat with axis_dominant_v3_to_m3.
2014-04-19 15:52:01 +10:00
Campbell Barton
fabc46b41f Math Lib: add rotation_between_vecs_to_mat3
- behaves like rotation_between_vecs_to_quat
- avoids calling sin,cos calls (approx 1.6x faster).
2014-04-19 15:36:47 +10:00
Campbell Barton
fc9c790563 Math Lib: minor optimization for axis_angle_normalized_to_mat3 2014-04-19 14:10:22 +10:00
Campbell Barton
e5f4f4d484 CMake was missing header 2014-04-18 20:46:14 +10:00
Campbell Barton
3e3efae7e9 Viewport Text Drawing: replace single allocs with a memarena
- pass label strlen since in many cases its already known.
- use single linked list for cached text drawing.
- add BLI_link_utils.h for single linked list macros.

own tests give approx 22% overall speedup.
2014-04-17 16:04:28 +10:00
Campbell Barton
1b9db9911d Code cleanup: use bools
also rename BLI_omp_thread_count -> BLI_system_thread_count_omp
2014-04-17 16:04:28 +10:00
Campbell Barton
b3972aeea0 Math Lib: optimize axis_dominant_v3_to_m3, approx 6x speedup
build the matrix directly rather then calculating with axis/angle

also remove unused function calc_poly_plane
2014-04-16 21:07:28 +10:00
Campbell Barton
233dac1494 Math Lib: increase epsilon for ortho_basis_v3v3_v3
passing in a unit length vector wouldn't always compute unit length vectors because the epsilon tested was too small.
2014-04-16 21:07:28 +10:00
Campbell Barton
28a829893c Math Lib: avoid having to pass a pre-calculated normal tot area_poly_v3
add normal_poly_v3
2014-04-16 00:29:57 +10:00
Bastien Montagne
d9211b1e7b Fix compilation (size_t not defined) by including stddef.h in BLI_sys_types.h 2014-04-15 09:11:45 +02:00
Campbell Barton
aa10cf7f5c GHash: add BLI_ghashutil_uinthash_v4 for hashing 4 ints at once 2014-04-15 14:40:33 +10:00
Campbell Barton
a7241d09cd GHash: add typed hash functions (were all (void *))
- BLI_ghashutil_strhash_n takes string length, to avoid terminating the string before hashing.
- BLI_ghashutil_inthash/uinthash take ints, to avoid casting to (void *)

This also showed up incorrect use of inthash, which was using a pointer.
2014-04-15 14:22:36 +10:00