cji3bp62000 / animatablevolumecomponent Goto Github PK
View Code? Open in Web Editor NEWThis Unity package provides helper scripts that let you animate Post-Process parameters (VolumeProfile) in URP/HDRP.
License: MIT License
This Unity package provides helper scripts that let you animate Post-Process parameters (VolumeProfile) in URP/HDRP.
License: MIT License
feature: Add [Read From Running Profile] Button to AnimatableVolumeComponent
or maybe VolumeHelper.
Sync
or Read
this is optional feature that may not be implement, because currently there's no class other than TextureCurve
/ AnimationCurve
that is built-in Unity VolumeParameter, both URP and HDRP.
(technically ,TextureCurve
and AnimationCurve
can't be animated)
if you want to animate class, just use struct.
Unity can't animate class
(even though it can serialize it π’ ), but unity can animate struct
!
see β Animating serialized class properties with animation clip?
So, if there's a class VolumeParameter (VolumeParameter<SomeClass>
), we can maybe generate a struct for it, and link between them.
example:
/// <summary>
/// User class, not animatable
/// </summary>
[Serializable]
public class MyClass
{
public int intField;
public float floatField;
public bool boolField;
}
// -> generates...
/// <summary>
/// generated struct; this is animatable!
/// </summary>
[Serializable]
public struct MyStruct
{
public int intField;
public float floatField;
public bool boolField;
}
problem and solution:
AnimatableVolumeComponentMapping.g.cs
(because we search new components by reflection)
AnimationComponent
, use their expected class name to generate the map (before the script compilation of new components).another solution:
When [Read from Profile] is on, current system is constantly writing back to animatable.
When animation window is in recording state, and user drags the playback head, the system will overwrite keyed value by current value.
(this is base on imagination)
example:
when dragging, animation will set current value to new value, but Read-from-Profile reads profile value (which is old value!) and overwrites values in animation.
OnDidApplyAnimationProperties
)
EditorUtility.IsDirty(profile)
before reading from profileJapanese Support
No comment is not good for me and others!
The AnimatableVolumeComponent seems to work in HDRP, but code-gen generates classes with errors.
+
-> .
in type nameHideInInspector
, Obsolete
attributes
fix me.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. πππ
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google β€οΈ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.