godotengine / godot-proposals

Godot Improvement Proposals (GIPs)
MIT License
1.26k stars 101 forks source link

Add camera shots track to AnimationPlayer to set active cameras #12627

Open lander-vr opened 3 weeks ago

lander-vr commented 3 weeks ago

Describe the project you are working on

High fidelity 3D environment.

Describe the problem or limitation you are having in your project

Managing cameras for cinematics and cutscenes using the AnimationPlayer is a little cumbersome. You cannot create individual camera shots, and while you can animate the 'current' property on cameras, this doesn't give a preview.

Describe the feature / enhancement and how it helps to overcome the problem or limitation

Add a shots track in which active cameras can be determined. Multiple tracks could be supported, for ease of use on more complex cinematics/cutscenes, as editing is a very iterative process, multiple tracks can be used to organize shots.

A camera button on the shots track acts as a preview button, and will overwrite the editor camera with the current active shot camera when toggled.

When rendering out a cinematic through movie maker mode, frames/sequences could be named by the name of the shot, and/or optionally stored in a unique folder per shot.

This largely follows Unreals shots functionality in their sequencer (their animation workspace).

Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams

Image

Alternatively, for a single track: Image

If this enhancement will not be used often, can it be worked around with a few lines of script?

This cannot be worked around easily. It would be used often as lots of games have cutscenes, and most games need cinematics for trailers, showcases, etc.

Is there a reason why this should be core and not an add-on in the asset library?

Core UX improvement.

AThousandShips commented 3 weeks ago

What do you mean by a "camera shot"? Like a camera motion? Or a video clip?

lander-vr commented 3 weeks ago

The current active camera, instead of animating the "current" property.

Mickeon commented 3 weeks ago

You could implement this ad-hoc for your own project by setting up a script with a custom integer property that is associated to each of the cameras.

Calinou commented 2 weeks ago

and while you can animate the 'current' property on cameras, this doesn't give a preview.

I believe Cinematic Preview in the Perspective menu should do this already.

lander-vr commented 2 weeks ago

I believe Cinematic Preview in the Perspective menu should do this already.

You're right! I didn't know this feature existed, the button seems a little misplaced if the intended purpose is for it to be used with the animation player.

Maybe this toggle should be moved to the animation bottom panel? Or if the feature is intended for a broader use case beyond the animation player, the animation panel should still have its own toggle for this.

Calinou commented 2 weeks ago

You're right! I didn't know this feature existed, the button seems a little misplaced if the intended purpose is for it to be used with the animation player.

It's in the Perspective menu because it's set on a per-viewport basis, and you can have multiple viewports at the same time in the 3D editor. The toggle also affects any usage of the current camera being set in the editor, not just AnimationPlayer's doing (e.g. a @tool script running within the editor).