Commit Graph

87543 Commits

Author SHA1 Message Date
Campbell Barton
9fecac32d9 Screen: replace show footer operator with property
This matches 'show header' internal logic.
2019-05-14 20:21:27 +10:00
Campbell Barton
4887b771f9 Cleanup: sort struct declarations 2019-05-14 20:21:22 +10:00
Campbell Barton
6a4c5b67ec Cleanup: quiet warning 2019-05-14 20:21:22 +10:00
Antonioya
254b1a4294 Fix T64441: GPencil textures weird rotation
New option to disable the follow drawing path. Before it had only a switch property, now there is a list of options.

Modes:

Path: Follows drawing stroke and rotate with object.
Object: Only follows object rotation.
None: Don't rotate.
2019-05-14 11:59:19 +02:00
Jacques Lucke
21bfc469ab Cleanup: rename ED_scrubbing.h to ED_time_scrub_ui.h
Also renames the corresponding .c file.
2019-05-14 11:49:15 +02:00
Alexander Gavrilov
1c106e189a RNA: fix the id_data pointer of PoseBone.bone to point at the Armature.
The owning ID reference of RNA pointers is supposed to point at the
ID container that owns the object, but for PoseBone.bone it wasn't
updated to point at the Armature data ID instead of Armature Object.

This caused issues, like pose_bone.bone.driver_add() adding the
driver to the Armature Object animation data, which violates the
intended design of the animation data structures.

Since RNA code generally assumes that all pointers that don't
refer directly to an ID remain within the current ID, a custom
getter is required to fix this.
2019-05-14 12:39:36 +03:00
Alexander Gavrilov
02e3bf22ab Depsgraph: detect bbone_segments drivers from Object animation data. 2019-05-14 12:39:36 +03:00
Brecht Van Lommel
be967c0b3c Fix T64578: Cycles clamps HDR colors for 16bit integer image with colorspace 2019-05-14 11:22:07 +02:00
Clément Foucault
20421ef952 Cleanup: DRW: Move ModelMatrix declaration to common_view_lib 2019-05-14 10:57:04 +02:00
Clément Foucault
016fc7f0c2 GPUVertexFormat: Reduce size of structs
With this patch, the size of GPUVertFormat goes from 1240 to 388.
2019-05-14 10:57:04 +02:00
Clément Foucault
72a5e3f61a Cleanup: DRW: Add and use DRW_shgroup_uniform_vec2_copy 2019-05-14 10:57:04 +02:00
Clément Foucault
92b4e96afe Cleanup: DRW: Remove unused Uniform types 2019-05-14 10:57:04 +02:00
Clément Foucault
be5192bbb9 Cleanup: DRW: Remove uneeded _add suffix from DRW_shgroup_call_add 2019-05-14 10:57:03 +02:00
Clément Foucault
8bc8a62c57 DRW: Refactor: Use DRWCall to accumulate per instance attributes
This is a big change that cleanup a lot of confusing code.
- The instancing/batching data buffer distribution in draw_instance_data.c.
- The selection & drawing code in draw_manager_exec.c
- Prety much every non-meshes object drawing (object_mode.c).

Most of the changes are just renaming but there still a chance a typo might
have sneek through.

The Batching/Instancing Shading groups are replace by DRWCallBuffers. This
is cleaner and conceptually more in line with what a DRWShadingGroup should
be.

There is still some little confusion in draw_common.c where some function
takes shgroup as input and some don't.
2019-05-14 10:57:03 +02:00
Clément Foucault
20d9cd3a1f GPU: Add GPU_vertbuf_discard and GPU_BATCH_UNUSED
GPU_vertbuf_discard to clear buffer containers in place.
GPU_BATCH_UNUSED to tag batch that are cleared and not immediatly usable.
2019-05-14 10:57:03 +02:00
Clément Foucault
e5349f14eb BLI_memblock: Add more options
- Use int instead of uint for safety and less conversions.
- Add free callback
- Add cleared alloc option
2019-05-14 10:57:03 +02:00
Clément Foucault
0e5da91f0a Cleanup: Remove DRWCallType
This simplify the rendering logic.
2019-05-14 10:57:03 +02:00
Clément Foucault
ed3f05aca9 DRW: Fix threading hazard when rendering and using auto depth 2019-05-14 10:57:03 +02:00
Clément Foucault
e0420097e3 Cleanup: DRW: Remove unused functions 2019-05-14 10:57:03 +02:00
Clément Foucault
754ecd61aa DRW: Change Procedural function to use a GPUBatch
This is in order to have VAO handled by thoses batches instead of using a
common VAO. Even if the VAO has no importance in these case using a batch
will help when transitioning to Vulkan.
2019-05-14 10:57:03 +02:00
Clément Foucault
8406fabc87 Eevee: Replace DRW_shgroup_empty_tri_batch_create by procedural calls 2019-05-14 10:57:03 +02:00
Clément Foucault
201ebc78e8 Mesh Batch Cache: Fix use of uninitialized variable 2019-05-14 10:57:03 +02:00
Clément Foucault
b27492d078 DRW: Make Instance count not a pointer
Goal is still to simplify the draw manager.
2019-05-14 10:57:03 +02:00
Clément Foucault
cf8109d2aa Cleanup: Eevee: Make planar downsampling not use instance drawing 2019-05-14 10:57:03 +02:00
Clément Foucault
ad0e95688d Cleanup: DRW: Remove pointers to materials 2019-05-14 10:57:03 +02:00
Clément Foucault
2d28df783a GPU: Move Material index to nodetree evaluation
This removes the need to pass the Material* all over the place in the draw
manager. Cleanup comming right after.
2019-05-14 10:57:03 +02:00
Clément Foucault
642c8010b2 DRW: Remove ModelViewMatrix and ModelViewMatrixInverse 2019-05-14 10:57:03 +02:00
Clément Foucault
b13e0568d3 GPU: Remove ModelViewMatrix and ModelViewMatrixInverse usage 2019-05-14 10:57:03 +02:00
Brecht Van Lommel
49a7031caa Fix T64588: some new theme preferences not saving 2019-05-14 10:42:53 +02:00
Campbell Barton
153c144053 Fix T64339: Crash with UV sculpt after undo 2019-05-14 17:05:02 +10:00
Campbell Barton
1f891bbc2c Keymap: add option for tilde key preference
Since the view menu is redundant for people with a numpad,
add a preference for it to switch between gizmos instead.
2019-05-14 15:19:50 +10:00
Campbell Barton
9c9081d9ef Preferences: file menu item to temporarily load factory settings
It's common to load factory settings as a test without wanting to
overwrite your own settings on exit.
2019-05-14 12:37:07 +10:00
Campbell Barton
34da7f8fdd Preferences: set dirty flag when dragging 2019-05-14 11:15:38 +10:00
Campbell Barton
8fe5a28635 Fix property update setting dirty flag 2019-05-14 11:12:02 +10:00
Campbell Barton
a5b5bd2c24 Fix missing preference dirty tagging
Tagging dirty was failing for UI scale, line width, hinting & others.

Checking for an update function means all update functions
need to tag preferences as dirty.

Since this check was added to prevent the active section marking the
preferences as dirty, only exclude this property.
2019-05-14 10:25:55 +10:00
Campbell Barton
36a33b8c82 UI: grey out 'Revert' when preferences aren't dirty 2019-05-14 10:25:55 +10:00
Brecht Van Lommel
f070bdd7c9 Fix T63802: textured lights not working with OSL 2019-05-14 00:40:25 +02:00
Brecht Van Lommel
2ff7494e6d Fix T64561: wrong colorspace for Cycles displacement nodes 2019-05-13 23:40:45 +02:00
Brecht Van Lommel
1428435a9a Fix compiler warning with OpenGL icon textures 2019-05-13 23:30:23 +02:00
Brecht Van Lommel
1de990651f Fix T64292: world missing from outliner Scenes view 2019-05-13 22:37:45 +02:00
Brecht Van Lommel
cac0e604e7 Fix T64297: edit light energy not working for Eevee, when nodes exist
Simplify code now that Cycles also has energy outside nodes.
2019-05-13 22:32:50 +02:00
Brecht Van Lommel
e2fdbf7599 Fix T64407: crash adding workspace after appending datablock
The files operator property should not be remembered for next
operator executions, gives unexpected effects when using the
operator again.
2019-05-13 22:20:49 +02:00
Ray Molenkamp
164fafdcb0 make.bat: add option for enabling the OpenGL based tests. 2019-05-13 14:08:27 -06:00
Alexander Gavrilov
27d097e92d Python API: expose conversion between tweaked NLA strip and scene time.
This is necessary to correctly do low-level keyframe manipulation
in tweak mode, and the logic is complex enough that re-implementing
it in Python is impractical.
2019-05-13 22:09:42 +03:00
Philipp Oeser
c6f975e3e5 Better support for (mirrored) bbone scaling in pose mode
since own rB5d9d32fd1fa3 (mirror bbone scaling in editmode)
- bbone scaling in posemode was missing immediate updates
- bbone scaling in posemode could crash

This now properly supports mirroring in posemode as well.
note: for bbone scaling, I made both X-Axis-Mirror options (editmode
option as well as posemode option) valid.

Fixes T64091

Reviewers: brecht

Maniphest Tasks: T64091

Differential Revision: https://developer.blender.org/D4851
2019-05-13 20:04:32 +02:00
Alexander Gavrilov
0264d8390f Apply Pose as Rest Pose: implement an Only Selected bones option.
The most difficult part is handling parent-child relations correctly:
when a parent is applied, the children should be moved accordingly,
and when applying a child, it should not include transformation from
unapplied parents. All this requires walking bones as a tree, instead
of a flat list.

Limitation: Applying bones with non-uniform scaling without also applying
children will distort non-rest posing on said children for reasons related
to T54159 (basically, non-uniform scale plus rotation creates shear, and
Blender matrix decomposition utilities don't have tools to deal with it).

Reviewers: campbellbarton, brecht, mont29

Differential Revision: https://developer.blender.org/D3775
2019-05-13 19:17:53 +03:00
Bastien Montagne
93cabce3a1 I18n Disambiguation: "Shift".
Give WM context to the shortcut, since this is more specific meaning
than usual 'shifting' one...

Part of T43295.
2019-05-13 17:58:25 +02:00
Bastien Montagne
17e172b6c1 I18n Disambiguation: One more case of 'Root' falloff without 'Curve' context.
Part of T43295.
2019-05-13 17:58:25 +02:00
Bastien Montagne
6ec096facf I18n Disambiguation: "Add" in menu labels.
This one is usually a verb/action one in menus' labels,
hence we give it the Operator default context.

Part of T43295.
2019-05-13 17:58:25 +02:00
Sergey Sharybin
9ed8f8a968 Fix T63325: Drivers freezing input value
Not sure why driver would be affecting on the behavior, the actual
issue was caused by lack of proper relations built for lamps and
cameras.
2019-05-13 17:55:28 +02:00