View Full Version : cube map help...

12-15-2008, 12:31 AM
hey, can someone show me how to make this image:

to become something of a cube...
a full program would be helpful, as i would like to know how to do it...

i know how to use 6 separate image to make a cube but 1 image with 6 squares in it (i dunno how)..

12-15-2008, 01:50 AM
you dont have to have this image. enough is (from programming perspective) to load all six images as textures or as cube map. DDS file format has the feature to store all six cube sides in one file. in the end you still have a cube with correct images on it. cube mapping is often used for environment mapping where you adress pixels with three texture coordinates, the longest beeing one of the six images and the (s,t) coordinates as the lookup.
more: http://www.codesampler.com/usersrc/usersrc_8.htm#oglu_per_pixel_reflective_environmen t_mapping