PDA

View Full Version : low distortion UV mapping


Carl van Heezik
08-20-2003, 12:11 PM
I was tired of moving UV vertices around (in the UVW unwrap editor) to minimize the distortion of the texture map. I just finished a free 3dsmax V5.1 script that may help with low distortion UV mapping. The script adjusts the UV coordinates to get a low distortion UV map. Use the tool to get a large amount of the work done and tweak the rest by hand.

http://www.microcan.nl/uvHelp/example1.jpg http://www.microcan.nl/uvHelp/example2.jpg
left: mesh with distortion right: mesh after using the script

http://www.microcan.nl/uvHelp/uvHelpUI.jpg
The user interface dialog.

Download it at: www.microcan.nl (http://www.microcan.nl)

Try it out and let me know what you think.

EricChadwick
08-20-2003, 02:59 PM
The zip file only has two .max files and a .txt disclaimer. Where's the script itself?

Carl van Heezik
08-20-2003, 06:22 PM
The script is saved inside the max file. With previous scripts I got a lot of questions on how to install the script. Because the script is now saved inside a max file there is no need to install it. Simply loading or merging the max file is enough.

The max file contains a point helper object with the name 'uvHelp V1'. The script is attached to this point helper. When you load it, you will also load the script. The user-interface will show at the position where it was when the file was last saved. If the user-interface is not shown select the 'uvHelp V1' point helper and push the 'Dialog' button in the uvHelp rollout. When you save a file with the 'uvHelp V1' point helper in it, the script is saved in the max file together with some settings such as: dialog position and size. If you want to remove the script delete the point helper.

EricChadwick
08-20-2003, 09:15 PM
Hmm, that's an interesting solution. Unfortunately I can't assign the script to a hotkey or a quad menu or a toolbar. It would be nice to have it as a standalone .mcr, if possible. What about using the MZP installer?

Carl van Heezik
08-21-2003, 07:47 AM
The installation procedure for a mcr is not difficult from my point of view. Just copy the mcr to the 3dsmax5/UI/Macroscripts directory. Then you can assign it to a hotkey, quad menu or toolbar. I thought it was simple and explained it on my website but I still got a lot of mail on it. The all forgot to RTFM.

By saving it in a max file I hope this will not happen. Yes, I could have done it in an mcr and I still can and I will if enough people ask for it. For the moment I try this sollution.

EricChadwick
08-22-2003, 05:48 PM
I for one am casting my vote for a mcr. Maybe offer it as an option? The 4 year-olds can use the max file, while regular users can use the mcr...

You'll get a lot of peer feedback if you post this in the Discreet webboard, in the Maxscript-Library section. There are some really helpful coders in there.

EricChadwick
08-22-2003, 08:51 PM
Wow, this is impressive. Very cool.

At first I had several errors with the script. Then I noticed the point helper was Grouped, so I exploded the Group and then it worked without error.

A few possible improvements:

1. I noticed that it pushed the UVs way out to the upper right (when viewed in Edit UVW). It would be nice to have a checkbox in the dialog for auto-fitting the UVs within the 0-1 box. Chuggnut has a nice tool for this in his UnwrapTools script.
http://www.chuggnut.com

2. Your script seems to have difficulty with acutely-angled surfaces. Not sure how to improve this though. For example I have a rock that is basically an elongated 27-triangle hemisphere, with a planar UV from the top. Your script jumbles the UVs wildly, as if it can't figure out what to do. Even if I select just a face or two, it still goes haywire.

3. Explode the group in your uvHelpV1.max file.

4. Provide a .mcr for those who prefer it. I would love to have this in my quad.

Carl van Heezik
08-23-2003, 11:37 AM
posm,

I downloaded the file from my website to check if the point helper was grouped but it was not.

1. Auto-fitting is a nice option I will work on that.
2. This is indeed the problem area, I do not know a sollution for that. These are areas that can not be flattened without distortion. Exclude them when running the script and except distortion or split the uv map.
3. Sorry could not find it.
4. For this script maybe.

EricChadwick
08-26-2003, 02:47 PM
OK, thanks. I must have grouped the helper by accident somehow. Sorry about that.

Thanks for sharing this cool script!

CGTalk Moderation
01-15-2006, 10:00 PM
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.