Archive: Fullscreen and Aspect Ratio


15th January 2004 09:04 UTC

Fullscreen and Aspect Ratio
I've got a question... I use the aspect ratio fix for most of my presets. I notice that it fixes the aspect ratio for presets when they are in windowed mode, but it screws up the fullscreen aspect. Is there any way of checking if avs is running fullscreen in order to apply the fix only when in windowed mode? Thanks.


15th January 2004 10:04 UTC

not exact sure what you mean but presets scrambling up in fullscreen are usually caused by scopes, try setting n per frame instead on init


15th January 2004 12:31 UTC

You have to use w/h or h/w or a more complicated formula as your aspect ratio fix.
Note however that you need to recalculate this every frame, in case the user resizes the window or switches to fullscreen.


16th January 2004 03:49 UTC

I do calculate the aspect ratio per frame. code:

Per Frame:
aspect=w/h;

Per Point:
x=x5/(z5+dist); y=-y5/(z5+dist)*aspect;

It works fine in windowed mode, even when resizing. I never noticed this problem before, so maybe it's a bug that has been introduced with winamp5/avs2.8? Check it yourself if you can, maybe it's just my video card/drivers?

******
*edit*
******
I just tested this in winamp2/avs2.6. I am getting the same results. Perhaps a new avs variable is needed to check for fullscreen mode. Unless it's just my video...


16th January 2004 07:16 UTC

By the way, using aspect=min(w,h)/max(w,h) also works if h is larger than w.