audiality2 icon indicating copy to clipboard operation
audiality2 copied to clipboard

Property API values should probably be 'double'

Open olofson opened this issue 11 years ago • 2 comments
trafficstars

Property API values should probably be 'double' rather than 'int', so we can avoid weird units and/or resolution issues.

Not sure if there are any real reasons to even have an integer version of that API, as it's not really meant for anything performance critical.

See also #40.

olofson avatar Nov 06 '14 00:11 olofson

Hmm... Then again, most/all current properties are distinctly integer, so switching to floating point seems backwards.

The implementation is very direct and simple, so it's no big deal to support both. And strings, or whatever.

If doing that, adding basic introspection ("What type is this Property?") would probably be a VERY good idea, though...

olofson avatar Oct 11 '22 08:10 olofson

Oh, wait. A2_PSILENCELEVEL, for starters. (Used internally by a2_Render().)

Don't know about the validity of double here, but I'm going ahead and adding a2_GetStatePropertyf() etc, OpenGL style, for now.

olofson avatar Oct 11 '22 12:10 olofson