PDA

View Full Version : Paging Textures and Uv's automatically


abyjoe
12-17-2008, 12:42 PM
hi guys... wondering if this can be done with maxscript...

I have 4 models, each using a 256 x 256 texture map... i want to page these 4 textures into one 512 x 512...

ideally i am thinking of creating something that will automatically move the UV's of the model in the first, second, third and fourth quad of the 512 texture... not only that, but the script should also be able to take the 4 256x maps and create a new 512 texture

any possibilities ?

abhi

PiXeL_MoNKeY
12-17-2008, 03:17 PM
This should be possible. You will need to either use the unwrap modifier or the texture vertex commands to modify the data. I personally prefer the unwrap since there are commands to scale and move rather than recalculating the position of every vertex based on scaling it down and moving it.

Basically you will need to take the data scale it to 25% and move it based off its [0.5, 0.5, 0.0] offset (i am guessing you are only dealing with UV space and not W coordinates) to a corresponding offset in one of the quadrants. My "Unwrap Seperate by ID" (http://www.scriptspot.com/3ds-max/unwrap-seperate-by-id) script may be of some help in the moving of your data.

You should be able to combine the texture maps as well, but I have no experience with building/combining bitmaps in Maxscript.

-Eric

abyjoe
12-18-2008, 08:19 AM
thanks eric... i will try what you have said and post back any updates.

CGTalk Moderation
12-18-2008, 08:19 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.