Forums > Jitter

Which blend mode and slabs for GL feedback?


VG
June 6, 2007 | 10:03 am

Hi list,

i’m trying to get feedback with slabs on OpenGL scenes to be finally
mixed in a videoplane…
but i’m getting confused with the blend mode, and though systematically
searching
through the various possibilities, didn’t find any combination allowing
to get the
original textures colors.

Here’s the patch, what i’d like to get is the two text3D rendered on the
videoplane
with a black background, original texture colors from the movies and a
slight feedback..

Can anyone help?

vincent



VG
June 12, 2007 | 10:19 am

mmmm… it seems the message i had sent had no attached patch
..maybe thats why i got no answer ? ;-)
now, i put it online:

http://www.pucemuse.com/patches/BlendMode.mxt


i’m trying to get feedback with slabs on OpenGL scenes to be finally
mixed in a videoplane…
but i’m getting confused with the blend mode, and though systematically
searching
through the various possibilities, didn’t find any combination allowing
to get the
original textures colors.

Here’s the patch, what i’d like to get is the two text3D rendered on the
videoplane
with a black background, original texture colors from the movies and a
slight feedback..

Can anyone help?

vincent


June 12, 2007 | 2:24 pm

@blend_mode 6 1 is additive blending. It’s a good one to use for
feedback and layering.

wes

On 6/12/07, Vincent Goudard

wrote:
> mmmm… it seems the message i had sent had no attached patch
> ..maybe thats why i got no answer ? ;-)
> now, i put it online:
> http://www.pucemuse.com/patches/BlendMode.mxt
>
>
> …
> i’m trying to get feedback with slabs on OpenGL scenes to be finally
> mixed in a videoplane…
> but i’m getting confused with the blend mode, and though systematically
> searching
> through the various possibilities, didn’t find any combination allowing
> to get the
> original textures colors.
>
> Here’s the patch, what i’d like to get is the two text3D rendered on the
> videoplane
> with a black background, original texture colors from the movies and a
> slight feedback..
>
> Can anyone help?
>
> vincent
>
>
>
>
>
>
>


June 12, 2007 | 2:39 pm

If you want to use feedback with slabs, without any major color
changes, ive got a luminosity based shader you can use that works
pretty well. Youd have to use render to texture, but here it is.



Mix based on luminosity.

Mix amount




< ![CDATA[

// texcoords
varying vec2 texcoord0;
varying vec2 texcoord1;

// samplers
uniform sampler2DRect tex0;
uniform sampler2DRect tex1;

// blend amount
uniform float amount;

// entry point
void main()
{
vec4 lumcoeff = vec4(0.2125,0.7154,0.0721,0.0);

vec4 a = texture2DRect(tex0, texcoord0);
vec4 b = texture2DRect(tex1, texcoord1);

float luminance = dot(a,lumcoeff);

vec4 mixr = mix(a,b, amount * luminance);
gl_FragColor = mixr;
}

]]>

On Jun 12, 2007, at 10:24 AM, Wesley Smith wrote:

> @blend_mode 6 1 is additive blending. It’s a good one to use for
> feedback and layering.
>
> wes
>
> On 6/12/07, Vincent Goudard

wrote:
>> mmmm… it seems the message i had sent had no attached patch
>> ..maybe thats why i got no answer ? ;-)
>> now, i put it online:
>> http://www.pucemuse.com/patches/BlendMode.mxt
>>
>>
>> …
>> i’m trying to get feedback with slabs on OpenGL scenes to be finally
>> mixed in a videoplane…
>> but i’m getting confused with the blend mode, and though
>> systematically
>> searching
>> through the various possibilities, didn’t find any combination
>> allowing
>> to get the
>> original textures colors.
>>
>> Here’s the patch, what i’d like to get is the two text3D rendered
>> on the
>> videoplane
>> with a black background, original texture colors from the movies
>> and a
>> slight feedback..
>>
>> Can anyone help?
>>
>> vincent
>>
>>
>>
>>
>>
>>
>>

v a d e //

http://www.vade.info
abstrakt.vade.info



VG
June 12, 2007 | 3:38 pm


Viewing 5 posts - 1 through 5 (of 5 total)