Not logged in, Join Here! or Log In Below:  
News Articles Search    

 Home / 3D Theory & Graphics / Substitute for glLogiOp() in DirectX? Account Manager
Archive Notice: This thread is old and no longer active. It is here for reference purposes. This thread was created on an older version of the flipcode forums, before the site closed in 2005. Please keep that in mind as you view this thread, as many of the topics and opinions may be outdated.
Julio Gorgé

April 30, 2005, 04:58 PM

I think the question does not need further explanation.. anyways:

Well, I just discovered the glLogicOp() OpenGL function:

I found it quite useful, and was exactly what I was looking for(needed to invert the colors of gameplay elements in real-time):

  3. if ( condition )
  4. {
  5. glEnable( GL_COLOR_LOGIC_OP );
  6. glLogicOp( GL_COPY_INVERTED );
  7. }
  9. // Draw elements
  10. // ...
  12. glDisable( GL_COLOR_LOGIC_OP );

However, I may have to port the code to DirectX in the future, that's the reason I have been looking for a similar mechanism in the MS API, although I have not found anything..

¿any idea or suggestion?


Fabian 'ryg' Giesen

April 30, 2005, 05:29 PM

There are no logic ops in D3D.

Julio Gorgé

April 30, 2005, 06:12 PM


Thanks.. it is a shame D3D does not have similar capabilites.. at least I can use the logic ops for the next GL vs D3D flamewar =)

This thread contains 3 messages.
Hosting by Solid Eight Studios, maker of PhotoTangler Collage Maker.