Commit Graph

58975 Commits

Author SHA1 Message Date
Campbell Barton
986972701e Fix T44249: Cursor depth offset 2015-04-06 15:00:07 +10:00
Campbell Barton
434087981a Fix minor glitch getting depth from mouse cursor 2015-04-06 15:00:07 +10:00
Joshua Leung
46b42dba14 Fix: Stroke Edit Mode warning for GPencil draws correctly with Region Overlap enabled 2015-04-06 13:21:18 +12:00
Joshua Leung
5574f4c59d Fix: It was difficult to select control points for NLA Control FCurves in the Graph Editor 2015-04-06 12:19:20 +12:00
Campbell Barton
7157f3dbce GHash: no reason to use GSetEntry in ghash API 2015-04-06 09:08:10 +10:00
Julian Eisel
c3dad7953a Stickies: Remove redundant fixes
Those fixes aren't needed anymore due to
776bfa64a53191b6f6aba107449be9353b7a2bee
2015-04-05 20:04:37 +02:00
Julian Eisel
776bfa64a5 Stickies: Don't send extra event on KM_CLICK
Just add KM_CLICK to the already sent KM_RELEASE, don't send a new one
for this.

This might help us to get rid of quite some glitches and workarounds \o/
(why didn't this come earlier to my mind? :S)
2015-04-05 19:32:57 +02:00
Julian Eisel
af23e8d44a Fix T44275: CTRL+LMB to extrude to mouse position conflicts with snapped
extruding

More practical description of the bug: extruding with ctrl to use
snapping and confirming the action added another extrusion to the mouse
position.
This was caused from the second event that is now sent if a key release
happens within the click timeout. It triggers the "Extrude to Cursor"
operator since it is called by CTRL+LMB wich is exactly the event that
is sent in this case.

I'm not totally happy with this workaround since it changes the Confirm/
Abort event for all transformation actions to key release which *might*
result in more conflicts (fingers crossed this isn't the case). If this
happens we might need to write some special transformation handling for
extrusion.

This is an example of the difficulties we get from loading too much
functions on the same keys - we need to be careful with that!
2015-04-05 18:52:36 +02:00
Sergey Sharybin
ab2d05d958 Fix T44269: Typo in volume_attribute_float:geom_volume.h
Was rather harmless typo since we either pass both dx,dy or pass both NULL.
2015-04-05 19:07:45 +05:00
Sergey Sharybin
b06962fcfe Cycles: Avoid using lookup table for Beckmann slopes on GPU
This patch is based on some work done in D788 and re-formulation from Beckmann
implementation in OpenShadingLanguage.

Skipping texture lookup helps a lot on GPUs where it's more expensive to access
texture memory than to do some extra calculation in threads.

CPU code still uses lookup-table based approach since this seems to be still
faster (at least on computers i've got access to).

This change gives about 2% speedup on BMW scene with GTX560TI.
2015-04-05 19:07:45 +05:00
Sergey Sharybin
252b36ce77 Cycles: Remove unused Beckmann slope sampling code
It did not preserve stratification too well and lookup-table approach was
working much better. There are now also some more interesting forumlation
from Wenzel and OpenShadingLanguage which should work better than old code.
2015-04-05 19:07:44 +05:00
Julian Eisel
92755da471 Fix T44251 (2nd try): Changing views using numpad broken 2015-04-05 15:41:20 +02:00
Thomas Szepe
29e968a315 BGE: Fix T36703: Character motion actuator local movement not working correct.
The character motion actuator local movement does not taking account of the object rotation.
It is necessary to rotate the motion vector before adding the local movement.

Reviewers: sybren, lordloki, moguri

Reviewed By: lordloki, moguri

Maniphest Tasks: T42709

Differential Revision: https://developer.blender.org/D1206
2015-04-05 10:13:04 +02:00
Bastien Montagne
1a117ad40c Fix T44263: Invalid parameters to fill_vn_fl in deform.c.
Own fault, thanks a bunch to LazyDodo for finding that - and odd
GCC did not warn about it...
2015-04-05 09:50:16 +02:00
Campbell Barton
a1c2b1a8a8 Fix T44265: Win32 error checking GL version 2015-04-05 09:57:10 +10:00
Campbell Barton
59bfc5c76e Fix T44270: Similar face region crash /w wire edge 2015-04-05 09:44:30 +10:00
Campbell Barton
00f732f268 Fix T44266: win32 delete's malloc'd memory 2015-04-05 06:54:34 +10:00
Campbell Barton
2f42be6995 Cleanup: remove MSVC2008 workaround 2015-04-05 06:54:34 +10:00
Campbell Barton
26979d45b1 Cleanup: use float math funcs 2015-04-05 06:54:34 +10:00
Campbell Barton
cedd7cde44 WM: prefer define over zero wmEvent.val 2015-04-05 06:54:34 +10:00
Antony Riakiotakis
8eac4085be Fix T44264 copy paste error, checking same condition twice. 2015-04-04 22:39:25 +02:00
Julian Eisel
1604a26fe6 Fix T44251: Changing views using numpad broken
For KM_ANY I've filtered out every event that has a click type, although
that was only needed for the additional event sent on KM_HOLD. A bit weird
that this only happened on a few machines though.
2015-04-04 19:17:39 +02:00
Julian Eisel
59df941ea5 Fix T44259: Secondary strokes get terminated early when drawing in Continuous Drawing mode 2015-04-04 14:27:05 +02:00
Campbell Barton
f5949efb53 Missed in recent cleanup 2015-04-04 18:58:49 +11:00
Campbell Barton
e84b0e4c35 Ghost: update tests for recent changes 2015-04-04 17:21:18 +11:00
Campbell Barton
eca22d076c Cleanup: move filelist out of storage
Depends on imbuf, problematic for tests
2015-04-04 17:21:18 +11:00
Thomas Dinges
e5392069cc Cleanup: Typo fix in HSV code. 2015-04-04 07:50:09 +02:00
Campbell Barton
12cede5ca3 Cleanup: use BKE_ocean_* prefix 2015-04-04 15:19:24 +11:00
Campbell Barton
7acd69958b Cleanup: use BKE_sculptsession_* prefix 2015-04-04 15:19:21 +11:00
Campbell Barton
1c96a84320 Cleanup: use BKE_animdata_* prefix 2015-04-04 15:13:56 +11:00
Campbell Barton
89a3e4deff Cleanup: redundant normalize in expmap_to_quat 2015-04-04 14:45:54 +11:00
Campbell Barton
519e20f984 Cleanup 2015-04-04 10:48:17 +11:00
Campbell Barton
92c7632835 Add missing break statements 2015-04-04 10:48:05 +11:00
Campbell Barton
4a4aaabfa9 CMake: treat inline C files as headers 2015-04-04 10:37:38 +11:00
Campbell Barton
f9b6709a17 Add missing declarations 2015-04-04 10:37:38 +11:00
Joshua Leung
53f4aa7817 WIP: Added dedicated operator for unlinking actions from the Action Editor (NLA buttons support to come)
After looking into this more carefully, I've found that we do in fact need a dedicate
operator to add some custom logic when trying to unlink an action from the editor/datablocks.

Specifically, this new operator does the following:
1) When in Tweak Mode, it shouldn't be possible to unlink the active action,
   or else, everything turns to custard.
2) If the Action doesn't have any other users, the user should at least get
   a warning that it is going to get lost.
3) We need a convenient way to exit Tweak Mode from the Action Editor
4) If none of the above apply, we can just unlink normally

This commit implements this for the Action Editor, with stubs for the NLA Editor too.
Those will be fixed next.
2015-04-04 11:37:06 +13:00
Joshua Leung
34c4133daf Tweaks to descriptions for Action Layer Up/Down 2015-04-04 11:37:05 +13:00
Julian Eisel
a3fdc6b755 Update keyconfigs for stickies
Change are needed to avoid conflicts due to rB53a3850a8a05249942a0c4
2015-04-03 16:44:42 +02:00
Julian Eisel
53a3850a8a Sticky Keys backend
Design task: T42339
Differential Revision: D840
Initial implementation proposal: T41867

Short description:
With this we can distinguish between holding and tabbing a key. Useful
is this if we want to assign to operators to a single shortcut. If two
operators are assigned to one shortcut, we call this a sticky key.

More info is accessible through the design task and the diff.

A few people that were involved with this:
* Sean Olson for stressing me with this burden ;) - It is his enthusiasm
that pushed me forward to get this done
* Campbell and Antony for the code and design review
* Ton for the design review
* All the other people that gave feedback on the patch and helped to
make this possible

A big "Thank You" for you all!
2015-04-03 16:21:22 +02:00
Bastien Montagne
b444887054 Fix T44243: File browser behavior is inconsistent between append and open.
Only basic fix, the whole 'dir' field handling needs rework to correctly support
lib stuff (will be done as part of asset-experiment rewriting work)...

All this code is doing way too much filesystem inspection by itself, instead of
reusing flielist.c work - this is stupid, and will completely break with future
asset engines!
2015-04-03 16:20:18 +02:00
Bastien Montagne
3f30ebf64a Fix related to T44243: do not systematically do live-update when tab-completing textedit buttons.
We now have a specific flag for that, use it! Note that for all 'search menu' buttons,
there is already a similar behavior, so there is no need to force apply butt in this case
anyway, which means in practice this change only has effect in the single place
it is needed currently - file browser dir/file fields.

In this case (dir field), applying button even on partial matches leads code
to ask to create a new dir, which breaks completely the expected behavior of
completion. And we do not need immediate apply at all here.

Note this is the only 'autocomplete' button not using search menu, so this change
does not affect anything else in UI.
2015-04-03 16:20:18 +02:00
Joshua Leung
03f2e5d4a6 Fix: Drawing glitch when renaming animation channels
When renaming animation channels, the old names are no longer drawn behind the
text boxes anymore. This used to cause problems if the names were long, or
if text boxes were set to have transparent backgrounds.

Thanks to kopias for reporting on IRC.
2015-04-04 01:40:01 +13:00
Joshua Leung
6ef7e0a194 Bugfix: Stashed actions now get added to the bottom of the NLA Stack if there weren't any stashed actions already 2015-04-04 01:40:00 +13:00
Joshua Leung
b30836dad7 Fix: Action/NLA Tweakmode Checks
Made all action management operators use the AnimData-local flag instead of the scene
global one. Technically, this is more accurate and results in less blocking
situations (i.e. another object may be in tweakmode, but because of that, the active
object's action couldn't be stashed).

The main impetus for this though was that the Action Up/Down feature doesn't clear
the global flag, since it is not in a position to do so (since it can't load up
everything to clear it).

TODO:
I'll need to review how this global flag works and/or potentially ditch it (or
perhaps add some better ways to ensure that it stays valid), since while thinking
this over, I've noticed a few problems here. But, for the meantime, this commit
at least makes things more usable here in the short term.
2015-04-04 01:39:59 +13:00
Joshua Leung
5681b4fc83 Action Editor: Move up/down buttons to be before the datablock selector
It turned out that the constantly changing width of the datablock selector
made it a pain to use these to quickly toggle between different actions,
as the buttons would keep jumping around, thus leading to errors when
quickly toggling between actions. This way doesn't look quite as great,
but should be more usable.
2015-04-04 01:39:58 +13:00
Joshua Leung
943b830bf6 Action Layer Up/Down: Fixes for NLA Solo / NLA Muting
Now marking NLA Tracks as Solo'd and muting the NLA stack are linked together
when using the Action Layer Up/Down tools. That is, when switching from a NLA strip
to the active action, if the track was solo'd, then the NLA stack will get muted;
and when switching from the active action to a NLA track, if the stack was muted,
the track will get solo'd. This linkage means that we ensure that when moving up
and down the stack, we can continue to check the actions in isolation without things
messing up when you switch to and from the active action.

Also fixed a bug where this wasn't getting applied when going in the other direction.

TODO:
- When we get the rest/reference track support, we're going to need to insert
  some calls to flush the restpose values so that values from the previously
  used action do not pollute the pose for the new action (if not all the
  same controls get keyed across both). For now, it's best to only do this
  switching from the first frame.
2015-04-04 01:39:56 +13:00
Joshua Leung
961dac55cf Code Cleanup: Deduplicate logic to switch between NLA Strips/Actions 2015-04-04 01:39:55 +13:00
Joshua Leung
f350e9f3fc Code Cleanup: Split out duplicate code for finding an available NLA strip above/below 2015-04-04 01:39:54 +13:00
Joshua Leung
bcf1abbc83 Action Editor: Go to Next/Previous Animation Layer
With this feature, it is now possible to quickly switch between different actions
stacked/stashed on top of each other in the NLA Stack without having to go to the
NLA Editor and doing a tab-select-tab dance, thus saving quite a few clicks. It
was specifically designed with Game Animation / Action Library workflows in mind,
but also helps layered animation workflows.

Usage:
Simply click on the up/down arrow buttons (between the action datablock selector
and the pushdown/stash buttons) to go to the action in the NLA Track above/below
the NLA Strip being whose action is being tweaked in the Action Editor.

Notes:
- These still work when you're not editing the action used by a NLA Strip.
If you're just animating a new action normally, it is possible to use the "down arrow"
to temporarily jump down to the previous action without losing the new action you're
working on, and then use the "up arrow" to get back to it once you're done checking
the other action(s).

- If there are multiple actions/strips on the same layer/track, then only the one
closest to the current frame will be used.
2015-04-04 01:39:53 +13:00
Bastien Montagne
13a63234d6 Fix T44237: translation does not work for input sockets in 'Active node properties' panel. 2015-04-03 12:38:59 +02:00