Commit Graph

23 Commits

Author SHA1 Message Date
ludovic chabant
da73a683f7 Sequencer: fix loophole where non-renameable tracks could be renamed by simply clicking on their label in the sequencer outliner view
#rb andrew.rodham

[CL 22812043 by ludovic chabant in ue5-main branch]
2022-10-27 12:39:50 -04:00
henrik karlsson
b5b86c796c This change is a strategical submit for a coming change that removes lots of includes in headers that are included by many files. This change contains adding of includes in files that previously got those includes transitively from other inclkudes
#preflight 6355d4940313c24974b2107b
#rb none

[CL 22783162 by henrik karlsson in ue5-main branch]
2022-10-26 12:57:32 -04:00
andrew rodham
a9fb6ad1e7 Sequencer: Added an ensure to protect against adding a model as a child of itself
#jira none
#rb Max.Chen
#preflight 633744e2b34118b9b4bb4b49

[CL 22284287 by andrew rodham in ue5-main branch]
2022-09-30 19:26:01 -04:00
ludovic chabant
c8596663d6 Sequencer: Clean internal state when recycling VMs
This fixes a problem of pre-recycling state leaking through after an update

#rb max.chen, andrew.rodham
#jira none
#preflight 6328be3e6919ce39982d8266

[CL 22087360 by ludovic chabant in ue5-main branch]
2022-09-19 22:28:57 -04:00
ludovic chabant
1ec5865d8a Sequencer: Fix report of hierarchical changes
#rb max.chen, andrew.rodham
#jira none
#preflight 63289426ae4e65ae63ea01cd

[CL 22087247 by ludovic chabant in ue5-main branch]
2022-09-19 22:14:59 -04:00
Max Chen
acd0eec433 Sequencer: Fix channel key areas being included when filtered out
#jira UE-162856
#rb andrew.rodham
#preflight 63123926da1671f997cc9b94

[CL 21763554 by Max Chen in ue5-main branch]
2022-09-02 13:28:36 -04:00
Andrew Rodham
e51c52c348 Sequencer: Optimized key interactions for large numbers of keys
A few changes here:

 - FKeyHandleLookupTable used to roll its own sparse array using a TArray of TOptionals. It was also designed to lazily update its map of handles to indices if it encountered one that was not correct. Unfortunately this results in an n^2 operation if you try and resolve key handles for all the elements in a channel when they are not valid (because it has to look through all the key handles to find the correct index). I have changed this to always keep the handle/index mappings up to date when moving keys around. In this way the operation scales poorly with the number of keys added or removed from the channel, rather than the total number of keys (which is still bad, but not as bad as always scaling poorly for large numbers of keys).

  - Various optimizations to FKeyRenderer. When preserving computed keys (ie, when we are simply padding new keys into or old keys out of view), we no longer re-allocate the entire array (which can be very large), and instead opt to relocate-construct the preserved keys within the same allocation. When the array gets large enough we always end up going to the crt allocator which is extremely slow, so keeping the allocation alive is beneficial here.

  - FKeyRenderer cached key computation is now performed using a parallel for loop when the number of channels or keys is large. This should really be improved by doing the same work for _all keys rendered in the current frame_ rahter than only going wide for each section, but this is a good win for control rigs at least.

  - When determining whether to draw a group of keys as selected, hovered or preview selected, we now only consider the first 500 keys before assuming all the others have the same state. This saves us from iterating thousands and thousands of keys to see if they are all selected when zoomed out very far.

 - FSequencerSelectedKey construction and comparison was taking up a lot of CPU. I have added raw FKeyHandle sets to the various selection classes for direct comparisons which speeds up checking for selected and hovered keys greatly. FKeyHandle is a unique index regardless of what channel it exists on, so this is safe.

#preflight 630d555c0345de4ccf9738e4
#rb Ludovic.Chabant, Max.Chen
#jira UE-162145

[CL 21694939 by Andrew Rodham in ue5-main branch]
2022-08-29 21:23:26 -04:00
Andrew Rodham
2510e5ad6e Sequencer: Added generic ways to create custom views for channels
- This is now supported by either overriding ISequencerSection::CreateChannelModel, or by defining a

TSharedPtr<UE::Sequencer::STrackLaneView> CreateChannelView(TMovieSceneChannelHandle<FMyChannelType>, TWeakPtr<FChannelModel> const UE::Sequencer::FCreateTrackLaneViewParams&);

overload for the sequencer channel traits of that type.


#preflight 630d555c0345de4ccf9738e4
#rb Ludovic.Chabant, Max.Chen
#jira none

[CL 21694520 by Andrew Rodham in ue5-main branch]
2022-08-29 21:05:05 -04:00
bryan sefcik
8cc129f2b6 IWYU Pass 1 - Engine/Source/Editor/...
#jira
#preflight 6306736ac85b7fef22be7751

[CL 21558583 by bryan sefcik in ue5-main branch]
2022-08-24 22:45:13 -04:00
Andrew Rodham
0c80c441ee Sequencer: Add channel view to collapsed sections
SSequencerSection now has an SChannelView that is only shown when collapsed, which reflects all the keys within it (including top-level channels). This actually allows us to also remove a second pass we had to do previously to generate top-level channel view widgets as well.

#jira UE-161879
#rb Max.Chen
#preflight 630661efc744dac9672f5c44

[CL 21545954 by Andrew Rodham in ue5-main branch]
2022-08-24 13:44:18 -04:00
Andrew Rodham
42d6d35621 Sequencer: Readded support for DrawExtra in channel views
DrawExtra now receives a parameter struct that contains the necessary slate rendering parameters, rather than utilizing the section painter and separate geometry. Ideally such rendering code would exist in actual view models or custom views, but for now this API needs to be maintained

#rb Mike.Zyracki, Max.Chen, Benoit.Badreau
#jira none
#preflight 63064e705366f61a42c398d1

[CL 21543371 by Andrew Rodham in ue5-main branch]
2022-08-24 12:40:10 -04:00
Andrew Rodham
5570354b69 Sequencer: Stop key bars from being drawn when EKeyBarConnectionStyle == None
#rb none
#jira none
#preflight 630637ef516bef57ffeadaa0

[CL 21540561 by Andrew Rodham in ue5-main branch]
2022-08-24 10:42:52 -04:00
Andrew Rodham
00eddaf65f 21514370 Sequencer: UX Refresh for 5.1 - Nested tracklanes, key bars, snapping polish
- Nested track lanes are now supported, allowing sequencer channels to be added as fully fledged child widgets of a parent, while still being arranged automatically and have their lifetime managed by their respective outliner item (therefore, they are now fully virtualized as you might expect)

  - Key bars have been added. This is exposed through a new ConnectionStyle member of FKeyDrawParams. Their rendering is also cached and batched within FKeyRenderer

  - Most relevant parts have been moved to SequencerCore now. Channel and category views remain in the Sequencer library due to their reliance on internal classes there, but they should be trivially moved to SequencerCore as a future task.

  - Track area now has a shared FTimeToPixel that can be shared amonst any widgets that need to convert times to track-area-pixel-space.

  - Added methods to ISequencerSection to allow client classes to create custom channel and category model types

  - Layer bar improvements:
    - Layer bars now encompass finite section ranges.
    - Resize handles are now only visible on hover as per design guidelines.

  - Inline curve display improvements:
    - Rendering is now part of each channel's view
    - Added API for determining curve extents
    - Curves are now rendered using FCurveModels

  - Snapping fixes and improvements
    - There were several places where snapping seemed not to work at all, or would snap inconsistently with dense keyframe data.
    - I've added a Weighting to the snap points so we can specify preferred snap points (section bounds, time cursor etc), and accumulate weights for specific frames where many keys exist. This helps to snap to times that are actually relevant, rather than always snapping to the nearest snap point, even if that snap point only has a single key on that time, and there are others within the snap threshold that have hundreds.
    - Converted the snapping utilities to operate on FFrameTimes rather than FFrameNumbers in order to support custom sequencer UIs that might not operate on integer time bases (it remains fully frame accurate with integers however)

  - Allow 'Key this section' to be unchecked


#rb Max.Chen, Ludovic.Chabant, Matt.Hoffman
#preflight 63055b5903520e063cd53cfb

[CL 21526535 by Andrew Rodham in ue5-main branch]
2022-08-23 19:51:55 -04:00
UnrealBot
73409369c0 Branch snapshot for CL 21319338
[CL 21319338 in ue5-main branch]
2022-08-10 16:03:37 +00:00
ludovic chabant
6ce9cca2fe Fix VM extension collection not updating correctly
This made the layer bars never properly computed.

#rb max.chen, mike.zyracki
#robomerge FNMain
#jira none
#preflight 62d84d2ed76ea4b5037e9e01

[CL 21186194 by ludovic chabant in ue5-main branch]
2022-07-20 14:50:44 -04:00
andrew rodham
cc38d03a29 Sequencer: Fixed extension collections not being updated on access when there was a latent hierarchy changed notification pending
#jira UE-158263
#rb Max.Chen
#preflight 62cc16e26a67c3717a37495c

#ROBOMERGE-AUTHOR: andrew.rodham
#ROBOMERGE-SOURCE: CL 21038444 via CL 21038447 via CL 21038451
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v972-20964824)

[CL 21040408 by andrew rodham in ue5-main branch]
2022-07-11 10:52:54 -04:00
Max Chen
9125e744e8 Sequencer: Rename master/slave views to primary/pinned views
#jira UE-158628
#rb andrew.rodham
#preflight 62c5ee08892b4d4f307a6aff
#robomerge enginemerge

[CL 20973375 by Max Chen in ue5-main branch]
2022-07-06 16:56:40 -04:00
Max Chen
67690cef59 Sequencer: Fix crash in FViewModelExtensionCollection::Destroy
#jira UE-158406
#preflight 62c48c8fb47aed4cf1b974ef
#rb andrew.rodham, ludovic.chabant
#robomerge enginemerge

[CL 20947928 by Max Chen in ue5-main branch]
2022-07-05 15:38:49 -04:00
ludovic chabant
7222ef5e91 Only create curve-editor extensions when the host sequencer supports a curve editor.
This lets us not even create a curve editor view model anymore if we don't need to.
#preflight 62b4ea48c366895b8282e67e

[CL 20804218 by ludovic chabant in ue5-main branch]
2022-06-23 18:43:15 -04:00
ludovic chabant
9791930470 Don't include filtered-out outliner items when computing vertical track area lane positions.
#jira UE-156254
#rb max.chen
#preflight 62acf82ed71aedcd76794c25

[CL 20711231 by ludovic chabant in ue5-main branch]
2022-06-17 18:07:13 -04:00
Andrew Rodham
8d5d254f97 Sequencer: Fixed mutation during iteration
#preflight 62ab36d55c69124c40822347
#jira none
#rb none
#robomerge enginemerge

[CL 20687050 by Andrew Rodham in ue5-main branch]
2022-06-16 10:29:10 -04:00
Andrew Rodham
81de5f747a Sequencer: Fixed hierarchy modification during iteration
#jira UE-154779
#preflight 629a176d4014ae259de70159
#rb Max.Chen

[CL 20487124 by Andrew Rodham in ue5-main branch]
2022-06-03 11:26:14 -04:00
Max Chen
0167d4ea0f Sequencer: MVVM2 branch and Layer Bars
Copying //Tasks/UE5/Dev-SequencerMVVM2 to Main (//UE5/Main) @20364093

#preflight 628866dfb94f739b152c1e29
#preflight 628866e4585e8f793ee80943
#rb ludovic.chabant, andrew.rodham
#fyi ludovic.chabant, andrew.rodham, andrew.porter
#jira UE-105322

[CL 20364493 by Max Chen in ue5-main branch]
2022-05-25 10:39:33 -04:00