realbasic-games
[Top] [All Lists]

Re: using opengl to filter texture?

To: REALbasic Games <realbasic-games at lists dot realsoftware dot com>
Subject: Re: using opengl to filter texture?
From: Frank Condello <developer at chaoticbox dot com>
Date: Wed, 31 May 2006 20:10:51 -0400
Delivered-to: listarchive at realsoftware dot com
Delivered-to: realbasic-games at lists dot realsoftware dot com
References: <0407D35F-6DE8-4D55-A249-F2E42AF09616 at divergentmedia dot com>
On 31-May-06, at 1:48 PM, Mike Woodworth wrote:

so,

i've made great progress with the help of glgeterror() and a few online tutorials. i now have opengl drawing my gworld to an opengl scene. now i'd like to extend this to allow me to filter the texture before displaying it - ie: lighten, darken, change hue, and contrast. is this done via shaders? what should i search for, where do i start? can it be done in rb?

I'm not really up to speed with shaders but using them in RB shouldn't be a problem since they're uploaded to OpenGL as strings and compiled/linked using standard calls. There's a good GLSL introduction here: <http://www.lighthouse3d.com/opengl/glsl/>

A lot of image manipulation can be done using fixed function blending and/or register combiners but fragment shaders are your best bet for accurate reproduction. OpenGL's built-in imaging APIs and colour matrix transforms could be useful here, but apparently they aren't accelerated on consumer hardware.

Frank.
–––––––––––––––––––––––––––––––––
Open Source RB Goodies and Shareware
<http://developer.chaoticbox.com/>
<http://www.chaoticbox.com/>
–––––––––––––––––––––––––––––––––

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>


<Prev in Thread] Current Thread [Next in Thread>