I have an arbitary shape on a bitmap that I want to extrude. For simplicity let’s say the shape is the letter ‘a’ but it could be any shape. Some of the shapes will be so complicated it would not be possible to use a series of line segments to outline the shape first and then convert to 3D. The bitmap is in RGBA format and all four channels have the letter ‘a’. Assume shape has already been corrected with lighting and specular.
Let’s say I want to extrude from the xy (z=0) plane to another parallel plane at z=30. The planes are guaranteed to be parallel but they could be rotated in any direction. Once the extrusion is done it should look like Playdoh forced out of a cookie cutter type plate.
Anyone have any idea how to do this? I know I can test the alpha channel with glAlphaFunc to determine what to draw but I don’t know how to fill in the space between z=0 and z=30. I suppose I could render the quad several times in between z=0 and z=30 to get the shape but the sides would not be solid.
thanks in advance