Commit Graph

69584 Commits

Author SHA1 Message Date
Campbell Barton
40d8a407d7 Fix invalid stack memory use with GPencil drawing 2019-04-20 15:13:40 +02:00
Campbell Barton
b24dfff9b7 Fix error in recent image preference change 2019-04-20 15:13:40 +02:00
Alexander Gavrilov
f22397206f NLA: check that properties are animatable. 2019-04-20 14:59:52 +03:00
Brecht Van Lommel
7cbb8f20a4 GPU: automatically draw images with GLSL shader depending on resolution
This adds a new "Automatic" image display method which uses GLSL shaders for
most images. It only does CPU side color management for higher res images
where sending big float buffers to the GPU is likely to be a bottleneck or
cause memory usage problem.

Automatic is the default now, previously it was 2D Texture.
2019-04-20 13:32:36 +02:00
Brecht Van Lommel
ed0c9654dd Cleanup: remove unused OpenGL functions, rename some for clarity 2019-04-20 13:32:36 +02:00
Campbell Barton
857b63f1d4 Cleanup: re-use test for ELEM & STR_ELEM
Avoid having same test running at the end of each macro.
2019-04-20 13:03:49 +02:00
Campbell Barton
83b0e975b9 Cleanup: quiet warning for NULL pointer use
Warning was false positive but avoid repeating the same check.
2019-04-20 12:32:47 +02:00
Pablo Dobarro
f2792e91f0 3D View: add opacity for sculpt mask display
This matches vertex/texture paint opacity options.

Useful because 0.75 is sometimes too dark to see the surface shading.

Resolves T63746
2019-04-20 12:03:57 +02:00
Campbell Barton
08f4cdebe4 Cleanup: de-duplicate flag setting macro 2019-04-20 11:39:25 +02:00
Campbell Barton
bbc5c1e36f Cleanup: quiet extra-semicolon warning 2019-04-20 11:30:19 +02:00
Antonioya
20bc30706b Fix T63732: GPencil Onion now working with multiwindows
If you had several windows or, after last changes in topbar, several areas, the swith of overlays or Onion Skin was not working by area, but as whole switch, so it was impossible to have different status by window.
2019-04-20 10:27:08 +02:00
Campbell Barton
e17e119a31 Cleanup: comment line length (tests) 2019-04-20 10:08:59 +02:00
Campbell Barton
e63eb6ed26 Cleanup: comment line length (windowmanager) 2019-04-20 10:02:28 +02:00
Campbell Barton
44ca116ca2 Cleanup: formatting, unused args 2019-04-20 09:15:06 +02:00
Dalai Felinto
2a39f2595b Outliner: Simplify logic for parent nesting 2019-04-19 22:27:44 -03:00
Clément Foucault
3368df4ab6 DRW: Expose VBO garbage collection timings
This adds user side options to tweak the behavior
of the vbo garbage collection.
2019-04-19 18:52:38 +02:00
Antonioya
7e4db169f2 T63644: Editing while parented is not rotating correctly
This commit tries to fix the rotation problem when the parent is at layer level.

The problem was the object location was not used, so all object not in origin got weird transformations.
2019-04-19 17:08:37 +02:00
mano-wii
8f4ba1c046 Fix T63669: Particle editing bypassing occlusion.
The problem occurs because status changes between BackBuffer and Offscreen.

Reviewers: fclem

Differential Revision: https://developer.blender.org/D4703
2019-04-19 11:49:17 -03:00
Sergey Sharybin
b6a9e88aff Fix T63648: Missing update when changing particle force fields
Force fields requires relations update in the dependency graph.
2019-04-19 15:41:32 +02:00
Sergey Sharybin
03c81a4fff Cleanup: Remove dead code
There is no more sorting happening, so the comment is out of date
by manu reasons. If something extra is needed there it would need
to be done differently anyway.
2019-04-19 15:41:31 +02:00
Clément Foucault
6c83c92862 Edit Mode: Change face mode edges display
This improve visibility in edit face select mode by using the face select color
instead of the edge select color (which is in default theme a bit more red). Also
makes the selected edges in this mode a bit more opaque (0.75 instead of  0.4).
Full opacity is still reserved for edge select mode.
2019-04-19 15:19:43 +02:00
Clément Foucault
223f7e79f9 DRW: Add batch garbage collection
This is only working for shading batches for the moment and only if some Custom data layer are not needed anymore.

The collection rate is hardcoded at 60 sec but could be exposed to the user.

This system can be extended and discard most unused batches in the future.

This commit is in prevision of removing BKE_MESH_BATCH_DIRTY_SHADING when changing shader parameters.
2019-04-19 15:19:43 +02:00
Clément Foucault
973e64cf9c DRW: Make shaded batch validation more correct
This is in order to support garbage collection of unused Custom data layer uploaded to the GPU.

Actual Garbage Collection is not added by this commit.
2019-04-19 15:19:43 +02:00
Sergey Sharybin
0ebf43b4d0 Cleanup: Remove image preview code
Was commented out for literally 10 years.
2019-04-19 15:16:33 +02:00
Sergey Sharybin
fd05d7bbcb Cleanup: Remove unneeded compositor update function
Similar to previous commit.

Compositing with animation on socket values and image sequences
still works fine.
2019-04-19 15:16:33 +02:00
Sergey Sharybin
81e0973dec Cleanup: Remove unneeded texture nodes update function
The function was calling update() on the time curve, but there
is no update callback on that node. So, effectively the function
was doing nothing.
2019-04-19 15:16:33 +02:00
Campbell Barton
d892f1037c Fix error in recently added STR_ELEM macro
Very bad oversight, using pointer comparison instead of strcmp
for all but the first item.
2019-04-19 14:52:58 +02:00
Campbell Barton
eb844fc1da CMake: fix building without smoke enabled
Was removed when removing sorted libs however it's needed for stubs.
2019-04-19 13:55:31 +02:00
Campbell Barton
60d733c563 Fix/workaround crash using ED_area_do_msg_notify_tag_redraw
Temporary workaround for crash when refreshing the active tool.

Currently ED_region_tag_redraw fails, use notifiers until
this is resolved.
2019-04-19 12:44:28 +02:00
Brecht Van Lommel
a277804c25 UI: tweak header context menu, gray out items when they have no effect 2019-04-19 12:26:45 +02:00
Campbell Barton
9573bf432c UI: move top-bar into the spaces header
Currently this is only in the 3D viewport however all spaces
that use the tool-system will have this region added.

D4680 by @brecht with own updates.
2019-04-19 06:53:38 +02:00
Alexander Gavrilov
638938e5a8 Armature: remove remains of the object-level deformation data cache.
Now that B-Bone shape data is kept in bPoseChannel_Runtime, the
armature level cache only holds one quaternion value per bone.
It can also be moved to runtime, and the structure removed.

This has an additional effect that, as far as I can tell, now
the Armature modifier can run as soon as all of the bones it
actually needs are done, thus making T59848 a purely depsgraph
level problem.
2019-04-18 23:19:44 +03:00
Campbell Barton
e8c9e85401 UI: Revert fix T37463: Y-clamp for header-only spaces
This reverts 91d8519c47 since I can't redo the reported error
which was in the old header-only info space.
2019-04-18 21:29:22 +02:00
Alexander Gavrilov
7ec6bca92f Fix T63332: backup and restore bPoseChannel_Runtime data during COW. 2019-04-18 21:32:17 +03:00
Brecht Van Lommel
64bcdd65bf Images: support packing edited images as OpenEXR or PNG.
This way float and multilayer images can now be packed without data loss. This
removes the as_png option and always uses the appropriate file format depending
on the image contents.
2019-04-18 20:07:55 +02:00
Campbell Barton
690ed63eb5 Cleanup: unused region init functions 2019-04-18 20:02:09 +02:00
Brecht Van Lommel
8326d59dbb OpenEXR: add support for writing EXR files to memory. 2019-04-18 19:42:20 +02:00
Brecht Van Lommel
624d010fe5 Cleanup: deduplicate single/multiview image packing code. 2019-04-18 19:42:20 +02:00
Brecht Van Lommel
54f420ec46 Cleanup: move image saving code to blenkernel. 2019-04-18 19:42:20 +02:00
Brecht Van Lommel
c2f75c7008 Cleanup: make image saving code reusable outside operator. 2019-04-18 19:42:19 +02:00
Brecht Van Lommel
0a4cded91e Cleanup: deduplicate image user initialization, make consistent. 2019-04-18 19:42:19 +02:00
Antonioya
4dce18fb51 GPencil: Add option to mix color with texture
This was already supported in Fill, but not in Strokes. This adds more artistic options when use textured strokes.
2019-04-18 19:33:06 +02:00
Campbell Barton
4439e5d0ba Cleanup: add trailing commas to avoid right shift 2019-04-18 17:19:44 +02:00
Antonioya
d6f9379149 GPencil: Fix Drawing Path follow error while drawing
The strokes was aligned to drawing path only when the stroke was completed. Now, the stroke is aligned while drawing too.
2019-04-18 16:59:18 +02:00
Campbell Barton
cfed33f738 UI: replace toggle header with a property 2019-04-18 16:39:46 +02:00
Bastien Montagne
9954cce59f Alembic: catch weird exceptions from library instead of aborting Blender.
Similar to what is done e.g. in AbcMeshReader::read_mesh()...
2019-04-18 16:20:19 +02:00
mano-wii
7d78474941 AMD glitch: missing changes in f41ab375f3
It was committed an earlier version of the patch which missed these changes.

Differential Revision: https://developer.blender.org/D4700
2019-04-18 10:54:03 -03:00
Campbell Barton
4c11e57316 Cleanup: add 'if 0' comment why code is repeated
Avoid potentially adding back the problem in the future.
2019-04-18 15:19:47 +02:00
mano-wii
f41ab375f3 Fix T62792: AMD glitch when clipping region in edit mode.
The `AMD Radeon HD 7600M` compiler is usually buggy for Geometry Shaders.
In this case, indexing was causing problems in `gl_in[i].gl_ClipDistance[0]`.

Reviewers: fclem

Differential Revision: https://developer.blender.org/D4700
2019-04-18 10:09:34 -03:00
Campbell Barton
dc8dd24351 PyAPI: remove support for importing text blocks as modules
Allowing direct import of text blocks isn't especially useful,
instead add `text.as_module()` script authors can do this
explicitly if it's needed.

Now the text "Register" option executes
instead of loading as a module.

This removes the need to keep track of the current Main,
and C code to override Python's import & reload.
2019-04-18 15:00:43 +02:00