Commit Graph

60372 Commits

Author SHA1 Message Date
Campbell Barton
5b0f674e09 Fix crash in redraw timer
Was modifying wrong regions flag, that could also be NULL.
2015-07-13 00:21:08 +10:00
Campbell Barton
8d48f8e0b0 Add ability for redraw timer to run for fixed time
Also avoid accessing context vars in timer loop.
2015-07-12 22:57:35 +10:00
Campbell Barton
2fd3b9ad84 PyAPI: Use separate writes for operator reports
This allows us to temp override the stdout and extract individual reports
2015-07-12 22:26:14 +10:00
Campbell Barton
532b735ee8 Docs; Py API gotcha's section
Minor corrections and cleanup
2015-07-12 20:50:44 +10:00
Campbell Barton
5c8fc8e505 Use const for direntry strings 2015-07-12 05:50:07 +10:00
Julian Eisel
8c67b8ffe9 File Browser: Fix possible bug and some minor tweaks
BLI_add_slash appended to a char *, a potential buffer overflow

Also partially removed an assert, which failed after changing file format of a saved image. We need a better way to handle such cases.
2015-07-11 21:44:42 +02:00
Campbell Barton
7b1489b93b Error in last commit 2015-07-12 05:35:44 +10:00
Campbell Barton
968351d916 Minor changes for more efficient endian switching 2015-07-12 05:33:04 +10:00
Campbell Barton
17ebbc06e2 Use const for sculpt vars
resolves building with gcc4.9
2015-07-12 03:50:39 +10:00
Sergey Sharybin
5a19d9d8f3 ImBuf: Fix compilation error with older libpng
Older libpng library does not use const pointer to a memory.

The exact version is a bit of a guess here, maybe needs tweaks to it tho.
2015-07-11 19:18:20 +02:00
Campbell Barton
3a810bfed6 remove redundant casts 2015-07-12 02:53:37 +10:00
Campbell Barton
eed7efa151 error in own last commit 2015-07-12 02:31:46 +10:00
Bastien Montagne
b610ec50de Add Thai and Khmer charsets to our i18n font. 2015-07-11 18:03:18 +02:00
Campbell Barton
a6259d4290 Avoid static var for OpenEXR 2015-07-12 01:45:30 +10:00
Campbell Barton
e42e01875e Make Iris image loading thread-safe
Needed for thumbnails
2015-07-12 01:13:33 +10:00
Campbell Barton
2410797ab1 ImBuf: cleanup, use const for memory passed in 2015-07-12 01:07:59 +10:00
Bastien Montagne
03d8907ca7 Add some basic report/timing/logging tool as util py module progress_report.
It supports any level of sub-steps, timing, messaging, and uses WindowManage.progress API
to report progress in UI, in addition to console printing.
2015-07-11 16:50:22 +02:00
Campbell Barton
114e7eaa09 Add WM_framebuffer_to_index_array
Convert buffer to index in one loop,
also minor cleanup to backbuf/selection functions.

- Use IMB_rectcpy instead of inline pixel copy.
- Redundant WM_framebuffer_to_index call.
2015-07-11 23:21:41 +10:00
Julian Eisel
02b3618873 File Browser: Keep file name after changing directory
Actually this was an intentional change in rBaeeb23efa28dc to prevent Blender from trying to open the old file from the new directory. Issue is that this is really bad for saving and basically breaks "Save As".

Some more tweaks were needed to make it work like before, so now it keeps the name of the last selected file, but clears it when selecting a folder.
2015-07-11 05:48:02 +02:00
Bastien Montagne
909fa34c5f BLI_matrix space_transform: Add a 'local-invariant' setter.
`BLI_space_transform_from_matrices()` defines a 'global-invariant' transform
(same point in global space, two different coordinates in local and target spaces).

New `BLI_space_transform_global_from_matrices()` is kind of opposite, it defines
a 'local-invariant' transform (two different points in global space, same coordinates in local and target spaces).

Useful to 'match' meshes.
2015-07-11 00:04:27 +02:00
Julian Eisel
bf3fe67862 Fix T45405: Crash on opening a file (in filebrowser code)
Quoting Bastien from IRC: "Filebrowser is a nest of bad surprises" -- indeed :S
2015-07-10 22:09:14 +02:00
Campbell Barton
f3d5af4172 Cleanup: use const for mesh functions 2015-07-11 04:39:27 +10:00
Campbell Barton
0875cb07cc Cleanup: use const for gpu buffer 2015-07-11 03:25:28 +10:00
Campbell Barton
78cae5bad9 Cleanup: remove redundant includes 2015-07-11 02:49:04 +10:00
Campbell Barton
3443686399 Sequencer: changes to text effect strip
- default alignment to lower center.
- placement is now relative,
  so changing output size keeps correct placement.
- instead of center override, add align option (left/right/center).

Also don't use pixel-size for setting the font size, on new strips.
Better not have UI prefs impact low level API's.
2015-07-11 02:30:26 +10:00
Julian Eisel
9a3dfa1f21 Fix crash when appending from File Browser
Again own mistake in rBaeeb23efa28dc1
2015-07-10 17:49:58 +02:00
Tamito Kajiyama
e7a48113a9 Freestyle: Missing __all__ symbols added in D963. 2015-07-10 23:15:59 +09:00
Tamito Kajiyama
25638a9656 Code cleanup: White space and dead code. 2015-07-10 23:15:57 +09:00
Folkert de Vries
eeeb845d33 Freestyle: new stroke modifiers
This patch introduces a couple new stroke modifiers. The ones currently implemented are based on prototypes by @kjym3 and myself.

The new modifiers:
  - Tangent
  - Thickness noise
  - Crease Angle
  - Simplification
  - Curvature 3D

The documentation for these new modifier types can be found [[ http://www.blender.org/manual/render/freestyle/parameter_editor/index.html | in the manual ]]:

{F134441}
(left: AnisotropicThicknessShader, right: NoiseThicknessShader)

{F140499}
(left: Curvature 3D, right: Simplification)

Author: Folkert de Vries (flokkievids)

Reviewers: kjym3

Subscribers: #user_interface, plasmasolutions, kjym3

Projects: #bf_blender

Differential Revision: https://developer.blender.org/D963
2015-07-10 23:15:56 +09:00
Bastien Montagne
7837f0e833 BLI_math 'compare' cleanup & enhancements.
This commit:
* Adds a 'compare_ff' function for absolute 'almost equal' comparison of floats.
* Makes 'compare_vxvx' functions use that new 'compare_ff' one.
* Adds a 'compare_ff_relative' function for secured ulp-based relative comparison of floats.
* Adds matching 'compare_vxvx_relative' functions.
* Adds some basic tests for compare_ff_relative.

See https://randomascii.wordpress.com/2012/02/25/comparing-floating-point-numbers-2012-edition/

Note that we could replace our python/mathutils' EXPP_FloatsAreEqual() by BLI's compare_ff_relative
(using a very small absolute max_diff), but these do not have exact same behavior...
Left a comment there for now, we can do it later if/when we are sure it won't break anything!
2015-07-10 15:02:43 +02:00
Bastien Montagne
bbcbd2eed9 REmove stupid apple check on OMP in weightvg modifier.
This is handled in build files...
2015-07-10 09:56:10 +02:00
Campbell Barton
a8b8d60c50 CustomData: deprecate CD_ID_MCOL 2015-07-10 16:47:39 +10:00
Campbell Barton
a7ed374459 makesrna: use int64 for rounding check
Harmless but larger values would overflow
2015-07-10 16:42:36 +10:00
Campbell Barton
66f1c3b882 DNA: replace GCC poison with ifdef for enums 2015-07-10 15:58:50 +10:00
Julian Eisel
5513fdc629 Fix T45398: Saving file from File Browser doesn't work if no file is selected
Own mistake in rBaeeb23efa28dc16e20
2015-07-09 23:48:55 +02:00
Julian Eisel
f766a61626 File Browser: (Re-)Allow selecting '..' parent entry for file navigation
Selecting '..' entry was intentionally disabled in rB76b4fad6dbda1b10c, however, for file navigation this can be really useful. So this basically allows selecting '..' entry again, *if it is the only entry to select*. It won't be selected using box select, select all or when expanding selection.
2015-07-09 19:48:03 +02:00
Julian Eisel
aeeb23efa2 File Browser: Improve usage of Enter-key to open files/directories
From a user-POV this makes following changes:
* Adds support for using the Enter-key to open directories
* Updates the upper text-buttons for file and directory on selection
* Last selected file/directory is opened now (in sync with upper text-buttons)
* Changes text in open button to "Open Directory" if a directory is selected

D1349, Reviewed by @mont29
2015-07-09 18:40:34 +02:00
Campbell Barton
26bd1a766a Cleanup: warnings 2015-07-09 19:39:37 +10:00
Campbell Barton
a837797740 Cleanup: quiet warning 2015-07-09 19:33:02 +10:00
Porteries Tristan
980ea4e54f Use it->second instead of (*it).second in KX_BlenderSceneConverter. 2015-07-09 09:45:21 +02:00
Campbell Barton
cdbb60b0a3 Select Shortest Path for edit-curve
D1391 by @pink.vertex with own fixes/edits
2015-07-09 17:03:00 +10:00
Campbell Barton
ee1b1b9e59 Curve: change rules wrt active bezier
Activate the vertex even if only a single handle is selected
2015-07-09 14:52:01 +10:00
Campbell Barton
bbc4a92318 Curve selection, de-duplicate & cleanup 2015-07-09 14:39:24 +10:00
Campbell Barton
ec64bf17e3 Select Similar for edit-curve
D1381 by @johnroper100 with edits
2015-07-09 03:03:19 +10:00
Campbell Barton
161bbfcd19 Add BKE_nurb_bpoint_calc_normal 2015-07-09 02:56:04 +10:00
Campbell Barton
4a328a7689 EditCurve: move selection into own file 2015-07-09 00:09:26 +10:00
Bastien Montagne
de6b4dc7f7 Fix/Cleanup mesh remap dest transformation in tree/source space.
In org work, bvhtree helpers were modifying passed co/no in place according to given transform.

However, during review pass we decided this was bad, and made them modify copies. But this broke
some cases where we'd do extra tests after bvhtree query, expecting tmp_co to be in tree (aka source) space!

Further more, since in quite a few cases we were already doing that transform outside of bvhtree helpers,
decided to remove this alltogether from the helpers - makes things more clear and easy to follow,
avoids needless copy of vector, and ensures we are always using tmp_co in its transformed version!
2015-07-07 19:29:17 +02:00
Campbell Barton
30b7aafe33 Correct default enum values
Had assert creating cheat sheet
2015-07-07 23:10:08 +10:00
Sergey Sharybin
3dc86f586c Cycles: Add debug print about CLEW initialization status 2015-07-07 14:37:12 +02:00
Sergey Sharybin
37539962fe Cycles: Add an option to force disable all OpenCL devices
This way it's possible to disable OpenCL devices for AMD devices
which are considered whitelisted.
2015-07-07 14:18:45 +02:00