• halftheory

    hi forum~
    this is what i want to do:

    1. load an input (pix_film/pix_movie/pix_video = ok).
    2. remove colors / make parts of the input transparent (pix_alpha = ok).
    3. apply this modified input to a rectangle geo (pix_texture = ok).
    4. then *extrude* this 2d texture into a simple 3d geo (like a cuboid) while preserving the alpha channel (i.e. transparent parts of the image look like 'holes' in the 3d object).

    i am really not sure how to proceed with 4. i stole the image below as the closest example i could google (although it doesn't demonstrate the alpha preservation).

    my first thought was to use pix_texture on a cuboid, however this doesn't seem to be the solution as it applies the 2d texture to all 6 surfaces (i.e. i guess a cuboid has no 'front' or 'back'). i want the 2d texture to stay facing the camera and extrude the texture back farther into the 3d space. or is there a way of modifying the default pix_texture behaviour on 3d geos? like having control on how it fills the 'Z' dimension...

    is there an OpenGL object that achieves this effect?
    glBindTexture?
    should i install an OpenGL external? http://linas.org/gle/index.html
    should i switch to blender or something?

    help! :)

    posted in pixel# read more
  • halftheory

    @slvmchn said:

    basically what i'm thinking is take the image you posted and instead of trying to deal with one 3d block (cuboid) maybe use 2d squares, 2 of them with the same texture, and place them like the top and the bottom of the cuboid (like the bottom and top of a box just floating in space). since these two squares contain the same image figure out what object you need to fill the 3d space between the 'active' colors (according to how you set your color threshold, that extern looks like it might be handy for this). have it fill along the Y axis between the active pixels in the image, and then you should have basically the effect you're looking for.

    hmm maybe that hack could work. i will post if i have success...

    i also thought about using LOTS of [pix_data] objects analyzing the color of the texture, and drawing geos from that (in effect, reconstituting the video input with added Z axis). but as [pix_data] can only analyze one pixel at a time it seems tiresome and too much pointless work (even for pd ;) surely there's a better way...

    what about PDP? the 3dp_push function? i can't test on linux for a few days.
    OpenGL brainiacs?

    posted in pixel# read more
Internal error.

Oops! Looks like something went wrong!