Author Topic: Technical Question about ALPHAMODE  (Read 1609 times)

Offline mentalthink

  • Prof. Inline
  • *****
  • Posts: 3375
  • Integrated Brain
    • View Profile
Technical Question about ALPHAMODE
« on: 2012-Apr-29 »
HI there...

The question it´s, in my game I need a great number of ALPHAMODE Commands changing from (+-x) values to 0.0...

The question it´s, it´s the same call one by one, or it´s better have all the graphics whit 0.0 in a part of code and each whit alpha +-x in another part of code..

I think the better it´s have all grouped in parts, but I think the code can be very confusing, and it´s a bit long...

Thanks in advance..

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10817
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
Technical Question about ALPHAMODE
« Reply #1 on: 2012-Apr-29 »
There shouldn't be much difference.

MrTAToad

  • Guest
Re: Technical Question about ALPHAMODE
« Reply #2 on: 2012-Apr-29 »
I haven't noticed ALPHAMODE causing any slowdown anywhere - I generally use it multiple times in a loop, so it should be safe to mix values around.

Offline mentalthink

  • Prof. Inline
  • *****
  • Posts: 3375
  • Integrated Brain
    • View Profile
Re: Technical Question about ALPHAMODE
« Reply #3 on: 2012-Apr-29 »
Ok Thanks a lot, I always thinked changing a lot of time ALphamode, can drop down the FPS...

Thanks in advance, very interesting...

Offline monono

  • Mr. Polyvector
  • ***
  • Posts: 213
    • View Profile
    • Sockel Lernmedien
Re: Technical Question about ALPHAMODE
« Reply #4 on: 2012-Apr-30 »
If you draw with a big polyvector loop, there should be a  slowdown if go from - to +, but not if you go just to 0 from any direction. As far as I know openGL has to restart the draw call to change the blending modes.