Forums > Jitter

Importing Alpha channel

July 21, 2008 | 2:18 pm

Is there a way to import a design file (.jpg, .png, .bmp etc…) and use its alpha values to shape a plane? I am using jit.gl.sketch to create a plane and then using a .jpg with jit.matrix to texture the plane. But this leaves me with a square plane. It would be nice to transform a plane to a more complex shape buy using the alpha channel from an imported file. Any ideas?


July 21, 2008 | 3:14 pm

1. make sure you use a 4 plane matrix, or use jit.gl.texture
2. as far as I know, jpg does not support 32bit images, meaning they
have no alpha channel.
3. use the settings depth_enable 0, blend_enable 1 and mess around
with the blend modes on jit.gl.sketch.

On 21 Jul 2008, at 16:18, Nick wrote:

>
> Is there a way to import a design file (.jpg, .png, .bmp etc…)
> and use its alpha values to shape a plane? I am using
> jit.gl.sketch to create a plane and then using a .jpg with
> jit.matrix to texture the plane. But this leaves me with a square
> plane. It would be nice to transform a plane to a more complex
> shape buy using the alpha channel from an imported file. Any ideas?


July 21, 2008 | 9:55 pm

i guess that should’ve been depth_enable 1

On 21 Jul 2008, at 17:14, Brecht Debackere wrote:

> 1. make sure you use a 4 plane matrix, or use jit.gl.texture
> 2. as far as I know, jpg does not support 32bit images, meaning
> they have no alpha channel.
> 3. use the settings depth_enable 0, blend_enable 1 and mess around
> with the blend modes on jit.gl.sketch.
>
>
>
> On 21 Jul 2008, at 16:18, Nick wrote:
>
>>
>> Is there a way to import a design file (.jpg, .png, .bmp etc…)
>> and use its alpha values to shape a plane? I am using
>> jit.gl.sketch to create a plane and then using a .jpg with
>> jit.matrix to texture the plane. But this leaves me with a square
>> plane. It would be nice to transform a plane to a more complex
>> shape buy using the alpha channel from an imported file. Any ideas?
>


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