antialias problem

Blitz3D Forums/Blitz3D Beginners Area/antialias problem

David(Posted 2004) [#1]
this code fails on second active antialias
the antilias active one only

what is the problem?

; AntiAlias Example
; -----------------

Graphics3D 640,480
SetBuffer BackBuffer()

camera=CreateCamera()

light=CreateLight()
RotateEntity light,90,0,0

sphere=CreateSphere()
PositionEntity sphere,0,0,2

While Not KeyDown( 1 )

; Toggle antialias enable value between true and false when spacebar is pressed
If KeyHit( 57 )=True Then enable=1-enable

; Enable/disable antialiasing
AntiAlias enable

RenderWorld

Text 0,0,"Press spacebar to toggle between AntiAlias True/False"
If enable=True Then Text 0,20,"AntiAlias True" Else Text 0,20,"AntiAlias False"

Flip

Wend

End


darklordz(Posted 2004) [#2]
works fine here


Beaker(Posted 2004) [#3]
Antialias command is a bit dodgy and doesn't work on all hardware. You should make it optional, cos people can also set anti-alias from their gfx card setup.

Also, I'm not sure its wise to keep turning it on/off like that, or even on/on/on.


(tu) sinu(Posted 2004) [#4]
you'd need to reload textures though if you change antialis mode iirc.


David(Posted 2004) [#5]
the idea is: if fps is >= 60 antilias true else antialias false ;)

in my computer work only one change, other change no work, ex: antialias true(ok), antialias false(ok), antialias true(no work more, always antialias false)

i am spanish and my english is not good, sorry if you no understand


FlameDuck(Posted 2004) [#6]
the idea is: if fps is >= 60 antilias true else antialias false ;)
It's not a (perticularilly) bad idea. Just remember that because you can run the game 'aliased' at >60 fps, doesn't mean you can run the game 'anti-aliased' at >60 fps.


(tu) sinu(Posted 2004) [#7]
it may just end up flipping between the 2 continuosly ie framerate gets >60 aa on, aa and fps drops under 60, so aa off, repeat nonestop.


Beaker(Posted 2004) [#8]
And AntiAlias command crashes on some hardware.


-=Darkheart=-(Posted 2004) [#9]
I think the problem you are experiencing is a known issue discussed here:

http://www.blitzbasic.com/Community/posts.php?topic=22930

There is no fix ATM.

Darkheart