PocketMatrix forums

A read-only archive of the PocketMatrix forums (2001–2014). Posting and accounts are closed.

OpenGL - Replacement for BltFast with EFX_OPACITY?

Hi! Since I'm migrating my rendering code to OpenGL ES for iPhone, I need to change the calls to the methods that belong to the E2DSurface "buffer" (the one from ecd.dsp->buffer) so that they make use of ClassEDisplay directly.

The only function calls I haven't been able to port are the ones that make use of the "flags" and "property" parameters from E2DSurface::BltFast (for example, in those cases where I need to blit an image with a certain opacity by using the EFX_OPACITY flag). How can I write equivalent code for a semi-transparent blit when using OpenGL?

Thanks for your reply,

--Nacho
Hi Nacho,

Use ClassEDisplay :: SetShading with E3D_TEXTURE and EFX_ filters before calling BltFast. This will apply the filter while blitting. The property value of SetShading works similar to the property value of BltFast you've been using before.
Great, it's working like a charm on iPhone. Thanks for your reply!

--Nacho