Validating Group def tic durations (value -1 is mishandled/unsupported)
With state def's, one can set a length of -1 to make the mobj never leave that state, but -1 doesn't appear to work with texture animation definitions; Dday appears to interpret it as 1 tic.
I wasn't sure if this was a bug or support for -1 tic lengths in texture animations was never added.
I was toying with the idea of a sky that changed into a different one over time, only to find out both that smooth texture animation didn't work with skies (it works with textures and flats as long as they have no transparent part's) and that sky glows and the associated coloured sector lighting don't appear to change if the sky changes.
Fixed|Definitions|libdoomsday: Group definition frame duration validation (mishandled -1)
Do not handle Group definitions whose frame durations do not describe
a valid animation sequence, when generating Material animations.
A warning is now logged by the DED parser when an invalid duration is
encountered. The Group definition itself will be ignored when building
Material animations, later on.
#2 Updated by danij over 9 years ago
Something I'd like to do in a future version is redesign how the sky-glow is sampled. Presently this works by evaluating the colors of the sky textures at load time. This is fine for the skydome where we have prior knowledge about the geometry, but model skies can't be dealt with in the same way.
The solution I'd like to use here is to render the sky to a very low quality cube map and sample the sky-glow color using this instead. That way, it'll work independent of the sky geometry and can be sampled in "real time" (in reality, a delay of a few tics wouldn't hurt if the sampling results were animated with interpolation).
Naturally there are other benefits to using a cube map. Specifically, we'd be able to determine if there is a strong light source in the sky and determine an approximate origin vector in 3D space. Once such a vector is obtained we'd be able to do more interesting lighting in outdoor areas.
#4 Updated by danij almost 9 years ago
- Status changed from New to Feedback
- Assignee set to vermil
vermil: How are you specifying a duration of -1 tics? Using the old Group method? (I don't believe a duration of -1 has ever been supported in a Group def).
It would be very helpful to see an example of what you are trying to do.
#6 Updated by danij almost 9 years ago
I see. Yeah a duration of Group.Flat/Texture.Tics = -1 has never been supported as there is no "infinite" concept at Group level. At the least the parser should catch this and log a warning...
It sounds like you're trying to set things up so that there is a one-time animation which when complete, switches to a separate looped animation? If so then this is far beyond the scope of what a Group is intended for.
Once support for multi-layered Materials has been completed we can then revise the sky dome renderer to use the full material system feature set, removing the special case layer mechanic used for sky layers. At which point, scripting up sky material changes as you'd like should be more doable.
#7 Updated by danij almost 9 years ago
- Tags changed from Textures, Materials, Animation, Sky to Textures, Materials, Animation, Definitions
- Subject changed from texture animation; -1 tic length mis-interpreted as 1 tic to Validating Group def tic durations (value -1 is mishandled/unsupported)
- Status changed from Feedback to In Progress
- Assignee changed from vermil to danij