Home Technical Talk

misc. maxscript UV scripts/tools

189101113

Replies

  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    I rewrote today the open/close UV editor script so that it now works perfectly with multiple objects at once (only max 2008 +). I needed that for a current work project which involves lots of 3d mesh tiles all sharing the same texture. So I might re-write some of the other methods as well like AO baking stuff which right now only works on 1 object at a time.
    Also colorman.reInitIcons() is now version sensitive, so for the person here that still has max8 he will see a popup asking to restart max in order to see the icons for the macroscripts.

    pior: you mean just like this:
    subobject.png
    but you should already have that in the main floater below the UV window
    UnwrapOptionsPannel.jpg
    I don't see a reason to add it in that case
  • kary
    Options
    Offline / Send Message
    kary polycounter lvl 18
    I'm a bit late as well (I've just started using max again, after a year locked into other software at work), and find your script absolutely awesome. Thanks very much :)
  • Cathodeus
    Options
    Offline / Send Message
    Cathodeus polycounter lvl 14
    Hi,

    Nice to see you back.

    Will it be possible to add a button that call back the Pixel Transform Floater ?

    I noticed that the "get" button do not work with multi sub-object material even if in the uveditor only one material ID channel is selected. Is that possible to fix it ???

    Editing uvs on 2 or more objects with textools will be awesome. :-)
  • alexk
    Options
    Offline / Send Message
    alexk polycounter lvl 12
    has anyone gotten this to work in Win 7 64bit? It worked fine on Win XP, but after I made the switch, it just doesn't work anymore. I drag the mzp file into max but nothing happens after that
  • Yozora
    Options
    Offline / Send Message
    Yozora polycounter lvl 11
    alexk wrote: »
    has anyone gotten this to work in Win 7 64bit? It worked fine on Win XP, but after I made the switch, it just doesn't work anymore. I drag the mzp file into max but nothing happens after that

    I dont think the operating system matters? But to answer your question, yes I'm using win 7 64 bit and works fine for me. Does it appear in your customize user interface options?

    Customize > Customize user interface > keyboard tab/group: main ui/category:textools > Textools

    You'll need to assign a hotkey for it or drag it to your toolbars or add it to your quad menu.
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    but still in a way it should also launch for the first time after you dragged it into the viewport. Check your admin rights - it could be the case that the dumb autodesk design of storing scripts in the program files/autodesk/3dsmax/scripts/
    (because texTools actually tries to copy itself to a subFolder called TexTools in the scripts folder which is not located in the user directory))
    fails for win7 by default - not sure what the details are on that. It just that I am kind of forced on this because its a location I can access booth from maxscript and the MZP startup script.
  • alexk
    Options
    Offline / Send Message
    alexk polycounter lvl 12
    It doesn't show up in my customize UI options. How do I check if I have the right admin rights? Is there a way to manually install the tools?
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    yes,

    open the MZP files (which is just a zip file but renamed) and extract its content to a new Folder TexTools in the scripts folder in max so that it all goes into:
    C:/Program Files/Autodesk/3ds Max 2010/Scripts/TexTools
    
    (or slightly different depending on where you installed max and which max version)
    so you have it like this
    maxtextoolsinstallmanua.gif
    after that go back to max and in the top menu goto
    MAXScript > Run Script...
    go to that folder (..\3ds Max 2010\Scripts\TexTools\) and select the uv_toolbox_2.80.ms file (or whatever version is included)
  • Cathodeus
    Options
    Offline / Send Message
    Cathodeus polycounter lvl 14
    I noticed few bugs :

    -The rectify function do not work anymore.

    -Some times when you use the pixel transform floater tab to align a few uvs clusters by pressing the button it don't align those cluster but scale them to zero. So you don't see faces animore but only one edge.

    Is this normal that the version into the *.Mzp is uv_toolbox_2.80.ms ?

    Will when i look at your last screenshot you're in uv_toolbox_2.99.ms this file is not into the zip of Textools 2.91
  • Cathodeus
    Options
    Offline / Send Message
    Cathodeus polycounter lvl 14
    Did find another bug :

    -When i click the "shad" button max deselct my object and do not show me the object unlit. Like with old versions of textools.
  • swytch
    Options
    Offline / Send Message
    swytch polycounter lvl 8
    render,

    I'm also trying to manually install without Admin rights, and your instructions worked to a point. The tools installed and will run, but the .bmp files for the button icons won't install, so I have gray buttons (the tooltips work ;). I also get the message, "-- Runtime error: Can't load Button images: bitmap: "C:Program Files\Autodesk\3ds Max 2009\scripts\TexTools\TexTools_icons.bmp""
  • Mark Dygert
    Options
    Offline / Send Message
    renderhjs wrote: »
    pior: you mean just like this:
    subobject.png
    but you should already have that in the main floater below the UV window
    UnwrapOptionsPannel.jpg
    I don't see a reason to add it in that case
    I think chuggnuts UV tools modifies or all together gets rid of that floater. If I remember correctly it overwrites the main unwrap script(s) with modified versions from that time (max 4, 5, or 6?). I think Pior would need to get fresh copies of the scripts it overwrites?
  • Joshua Stubbles
    Options
    Offline / Send Message
    Joshua Stubbles polycounter lvl 19
    renderhjs - in future versions will we be able to set our own wireframe colors and such? Every time I open the editor through textools, it resets all of the Unwrap window settings to it's own custom scheme (annoying as hell) :D
  • Muzzoid
    Options
    Offline / Send Message
    Muzzoid polycounter lvl 10
    welcome to aus man! If you are ever in brisbane drop us a line.

    Actually on second thoughts i should be down in syd around Christmas for a week, so if you want to have a mini pc meet up let us know :P.
  • TakuanDaikon
    Options
    Offline / Send Message
    TakuanDaikon polycounter lvl 12
    Is there some trick to getting TexTools to work with multiple objects? I have no issues applying an unwrap modifier to multiple objects and editing them in 2009, but when I attempt to use TexTools to open the uv edit window, it only allows me to edit the first selected object.

    I just recently started using TexTools, and I absolutely love it, but I'm pretty sure I'd love it even more if I could normalize the texel density on multiple objects at once :)

    .
  • Joshua Stubbles
    Options
    Offline / Send Message
    Joshua Stubbles polycounter lvl 19
    If you look up a few posts, Takuan, renderhjs said he re-wrote the open dialog to work with multiple objects now - but I think that's going to be in the next release. =\

    The dialog issue isn't a problem for me, as I have it hotkeyed. But I'd like to have the subscripts work across multiple objects. Like UVnormalize, Linear, etc. None of the scripts seem to work when I have multiple objects edited :(
  • TakuanDaikon
    Options
    Offline / Send Message
    TakuanDaikon polycounter lvl 12
    Vassago wrote: »
    If you look up a few posts, Takuan, renderhjs said he re-wrote the open dialog to work with multiple objects now - but I think that's going to be in the next release. =
    I had seen that, but misread the date on the post, and thought it was older than it is. Thanks for pointing that out.

    Well, I anxiously await the next release. It's an awesome productivity booster for me, and I absolutely love it. Thanks, renderhjs!

    .
  • kary
    Options
    Offline / Send Message
    kary polycounter lvl 18
    Monstrously large thread, so I hope this isn't already covered: What is the reason that when I sometimes use the lineup or compress commands it goes to 45degrees of the expected result? On max2010, 32 and 64bit.
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    kary wrote: »
    Monstrously large thread, so I hope this isn't already covered: What is the reason that when I sometimes use the lineup or compress commands it goes to 45degrees of the expected result? On max2010, 32 and 64bit.
    activated angle snap, just disable it (A key). It forces even core maxscript commands to snap to angles, very annoying.
  • kary
    Options
    Offline / Send Message
    kary polycounter lvl 18
    ugh that is a face palm moment. thanks :)
  • [HP]
    Options
    Offline / Send Message
    [HP] polycounter lvl 13
    I know It's not a big dreal but I'm getting some odd characters on your page.

    a3p2rp.jpg

    Anyways, I just instaled 2.9! gonna see whats new on this beauty! <3
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    yeah and once you reload the page everything is fine. I guess I need to embed the encoding type in the header or so. Noticed that myself before,

    edit: got another email regarding that, fixed it. Some header information in the html was missing.
  • TakuanDaikon
    Options
    Offline / Send Message
    TakuanDaikon polycounter lvl 12
    Can someone give me some guidance about why I frequently encounter odd behavior when using the "Lineup" tool? By odd behavior, I mean that the shells don't line up, they just get spread out over a very large area, with seemingly arbitrary gaps between them, and some of the shells overlapping.

    I read most of this thread a while back, but I don't remember seeing anything about this problem.
  • fiveways
    Options
    Offline / Send Message
    a couple pages ago, someone had an issue with not being able to see the render to texture window after baking an AO map from textools. I'm having the same problem, "texture baking complete" shows up @ the bottom but it doesnt actually do anything so now I can't bake any normal maps.

    I'm using max 2008 if that helps any.

    Edit: I tried rebooting and relaunching max to see if it changed anything. In the meantime I've been able to generate my normal maps by just exporting the high/low poly out as objs and importing them into a new max scene, but in the scene (and all of the following iterations) I used to generate the AO map w/ textools, the "render to texture" feature is still not working.
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    fiveways: I will have a look at it, what you mean is the Framebuffer, I disable that on operations but it should not be something that is saved afterwards - or kept as a setting. I will run some tests (max2010 trial) to see what I get.
  • fiveways
    Options
    Offline / Send Message
    Thanks dude, let me know how it works out :) I've always dreaded unwrapping and texturing anything that wasnt a box until I saw some of the tools available here, definitely looking forward to making use of em.
  • glib
    Options
    Offline / Send Message
    I'd just like to log another request for the 'face map' detail map to return. I find it to be a much cleaner workflow than the blockout map for how I like to do things, and I used it an absolute ton. I miss it :(.
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    already planned
  • TakuanDaikon
    Options
    Offline / Send Message
    TakuanDaikon polycounter lvl 12
    Can someone give me some guidance about why I frequently encounter odd behavior when using the "Lineup" tool? By odd behavior, I mean that the shells don't line up, they just get spread out over a very large area, with seemingly arbitrary gaps between them, and some of the shells overlapping with no clear cause.

    Although this is not a huge issue, it is quite annoying. Does anyone know why this keeps happening?
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    it is a mix of
    • angle snap turned on (so make sure its turned off
    • and or dead UV verts not cleaned up inside max's core but still selected through some maxscript commands.
    I will try to work on that see if I can beat max. I had in the past a related bug in the crop extended but I was able to find another way - hopefully likewise for this.
  • TakuanDaikon
    Options
    Offline / Send Message
    TakuanDaikon polycounter lvl 12
    I've tried toggling the angle snap, which does help ensure that the shells are not rotated but does not help with the other symptoms I have described. Is there something that I might inadvertently be doing to cause the "dead uv verts" issue, some some sort of workflow problem?

    Thank you for the reply, it is much appreciated.
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    so I found some time to work on TexTools after quite a while this sunday. And so far I fixed or added:
    1. max8 or older not getting error message regarding reloading icons
    2. open / close UV editor on multiple selected Objects (max 2008+)
    3. added again Render UV Mask. Now also works on multple Objects also works on Objects that don't have yet a UV modifier - it will delete it afterwards. Such a nice and simple button now.
    4. open UV editor keeps UV modifiers now cleaner and consistent. Before if you were not in the modify mode (but instead create, motion,...) it would add additional UV modifiers on top because max returns undefined regarding modifier stack info, so I made it jump everytime you open the UV editor to the Modify panel if you are not in it.
    5. rewrote the "Transfer UV channel Maps" in the render Texture Maps panel. It still only works with just 1 object (because of numMapChannels command missing in the UV_unwrapModifier object). But it should be more flexible as it also not forces a editAble class object anymore.
    6. fixed issue (I think so) with RTT not working anymore after you used either the AO or some of the map render types from TexTools. (I think the issue was that I set the ...bakeEnabled = false; after the bake, and that option is not availbel in the default 3dsmax RTT window).
    7. simplified some of the Macroscript descritions so its easier to spot which Macroscript triggers which Functionality. In most cases its just shorter and easier to read.
    8. cleaned up some macroscripts as their were targeting wrong variable paths, also disabled each macroscripts if TexTools was not loaded in the RAM (to avoid errrors) + added clean Button Labels should you drag Macroscripts into toolbars.
    9. added Open/Close Editor to the macroscripts
    10. kill the transform floater if you switch the object, go to a different tab (i.e create, animation,...). Opens each time you open the UV editor though
    11. new rotate bounding box 90 degree snap in the Pixel Transform Floater (great for Layouting UV sets)

    still on my working list right now but not completely done:
    1. go through as much functions as possible and make them compatible with Max2008+ multi Object Unwrap mode. This really depends though I f I do not need any polyOp commands or other non UV stuff - like stuff I usually need to measure 3d space or 3d polygon related stuff. But lots of stuff should be possible to port or make compatible
    2. Worn map rendering, I still got this nice code snippet from a friend which really works nice but I need to modify things before I can release any of it.
    3. set custom Wireframe color or some option for disabling TexTools UvEditor overrides.

    but I already solved most bugfixes I got here so far so I think I will jump to 3.0 with the next release.
  • SerdarDesign
    Options
    Offline / Send Message
    Hey Renderhjis

    when do you want to integrate LSCM unwrap in your super script?

    thx
  • Drew_Polycount
    Hello,

    I was recently recommended on a forum to use TexTools for unwrapping. I noticed it did things like unwrap complex bendy pipes and rope so it seems like just what I need.

    However 2.91 doesn't seem to load in 3ds Max 2009. I downloaded it from your website, but instead of downloading a .mzp file it downloads a .zip file.

    I have tried dragging this into the viewport, as well as unzipping and dragging the folder across, but neither of them load.

    In the unzipped folder there is a file called mzp.run, but no files ending .mzp that will load into 3ds max. Is the download file incorrect, or am I doing something wrong?

    Thanks,
    Andrew.
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    Andrew:
    The latest download link
    http://www.renderhjs.net/bbs/polycount/texture_maxscript_tools/TexTools_2.91.mzp
    is a MZP file, if you get something else your computer or software might be controlling you instead of the other way around ;)
    So maybe try a browser or download tool that does what it should do, or maybe you just got the wrong URL. I know some Chinese websites that modify my mzp file into something completely different making it useless and not working anymore (noobs).

    The way a MZP file works (but it also can be a ZIP file) is that you drag it in your viewport and inside that MZP or ZIP the "mzp.run" gets executed (its a special syntax). It holds instructions for copying the files to your
    C:Program FilesAutodesk3ds Max 2010Scripts
    
    (if thats your max directory for example, its dynamic though and not hard coded, I just get the script folder URL) folder, it will create that folder "TexTools".
    Once all those files are copied it will start the wrapper script that basically starts and wraps up stuff for the first time.

    Of course this can go wrong if:
    * you did not downloaded the original MZP file from my domain or the scriptspot one
    * you do not have privileges to copy or create folders on that 3dsmax/scripts location (stupid autodesk I know, but its the spot for me to dumb files). So if you do not have admin rights and your scripts folder is located on a space where you do not have rights to modify things you are powerless.

    Someone else had problems with the installation before so I will try to write a instruction for copying files manually for the ones with restrictive computers or troublesome OS languages (japanese XP I believe makes some trouble because of different system paths of max).
  • Joshua Stubbles
    Options
    Offline / Send Message
    Joshua Stubbles polycounter lvl 19
    Spectacular update list, renderhjs. Like Ryan and a few others on here, your tools are indispensable in day to day work and are a huge benefit to this community and industry as a whole. Looking forward to the next release!
  • Ghostscape
    Options
    Offline / Send Message
    Ghostscape polycounter lvl 13
    I just updated to 2.91 from like 2.6 or 2.8 (I am lazy). At some point you added a feature that snaps it to the top left corner it looks like?

    This sucks, because I don't put it there. I don't want it snapping anywhere. Is there some option to not do this?
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    will see

    meanwhile I wrapped up a small video on youtube showing the multiple object UV editing and multi Object Wireframe (UV) and mask rendering
    [ame]http://www.youtube.com/watch?v=d4bP20PiuS4[/ame]

    In addition to that there are 2 new buttons in the transform bar
    texTools_3.00_transform_floater.gif
    they rotate the selection around the pivot bounding box point (which you define in the very left of the transform floater).
    This means that objects get rotated 90 degrees without shifting annoyingly if you are packing stuff, like centroid of the bounding box like how max does it by default.
  • SerdarDesign
    Options
    Offline / Send Message
    Great! But the Pink Textools Logo looks weird :D (joke)
    Got a question: What can I do against UV/Texture Seams?

    For Example, if I have a character Model, unwrapped with LSCM, there are clearly visible seams...how to fix the visibility of these seams?

    Thx
  • mLichy
    Options
    Offline / Send Message
    Yaaaaay! That's the main thing I've been hoping for, is multiple object Unwrap with TexTools, :D:D
  • TakuanDaikon
    Options
    Offline / Send Message
    TakuanDaikon polycounter lvl 12
    That's some seriously amazing stuff, man.
  • FAT_CAP
    Options
    Offline / Send Message
    FAT_CAP polycounter lvl 18
    renderhjs wrote: »
    some option for disabling TexTools UvEditor overrides.

    please, please, please :)
  • [HP]
    Options
    Offline / Send Message
    [HP] polycounter lvl 13
    mLichy wrote: »
    Yaaaaay! That's the main thing I've been hoping for, is multiple object Unwrap with TexTools, :D:D

    I second this!
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    I am rewriting atm. all functions so that they are working with multi UV's. This is kind of a pain in the ass workflow as I have to structure some functions completely new, it goes usually something like this:
    local uv = modPanel.getCurrentObject();
    if( classof(uv) == Unwrap_UVW)then(
    	if ((maxVersion())[1] >= 10000 )then(--Max 2008+
    		for sel in selection do(--go through multiple objects
    			sortRow sel uv useXaxis texSizeW texSizeH texPad;
    		)
    	)else(--max 9 or older
    		sortRow selection[1] uv useXaxis texSizeW texSizeH texPad;
    	)
    )
    
    and then within each sub selection selections have to be executed different because you have to select by Object node because its not all one soup. So far I have working:
    • open/close UV editor
    • Render: Wire
    • Render: Mask
    • Explode
    • Split by smoothing groups
    • pack UV space
    I will try to make as many functions as possible compatible but there might be some that are simply to difficult to do or impossible at all. But in that case I will try to add some warning message at least (should you have max2008 + several objects selected + the particular function does not support it).

    FAT_CAP wrote: »
    please, please, please :)
    You know that everything gets reset once you close it again with TexTools and then you can simply open the UV editor the standard 3dsmax way (adding UVW unwrap + hit "Edit....").
    People were complaining thats why I added at least that sweeping feature so that it cleans any modifications back to the standard settings.
    But maybe yeah I will add some simple tick saying something like "Modify Editor Visuals" with a default on.
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    for those having trouble installing it the easy way, here is the slightly more hard way: doing it yourself:
    can_not_install_help.gif

    will include that in future releases inside the MZP archive and put it on the website.
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    I found a nice workaround for detecting failing copy attempts with the MZP scripts on Vista and Win7 computers that do not have Administrative Rights! on the 3dsmax/scripts folder.

    For that I am creating a installer that detects extracted MZP files from the windows>userData/temp folder and then tries to copy them with a setup Maxscript (not MZP script) to the scripts/TexTools folder.
    textools_3.00_install.gif
    That way I can detect if it fails and catch that error and perhaps confront the user with a instruction image or text on how to proceed (either manual install or set permission to create files in the scripts folder).
    Uninstall (to be worked on later) will delete all temporary data (like max MZP extracted leftovers), macroscripts, ini file, icons and the TexTools folder from the system with a log view at the end/before.

    Either way with this new architecture the MZP archive will be super easy structured in case you have to install stuff yourself.
    texTools_3.00_winrar.gifthe Folder "TexTools" goes to the 3dsmax/scripts/ folder and the content of the Icons folder goes inside the "3dsmax/ui/Icons/". But I will create some gif inside the MZP archive that will explain that.
  • SyncViewS
    Options
    Offline / Send Message
    SyncViewS polycounter lvl 13
    Hey render, that's how IC.Shape installer works ;D

    Edit: In file "IC_Shape_Installation.ms" you can find a structure with some handy tested functions to manage files and directory tree copy and delete. Get it if you like.
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    I found a neat trick that scans for all MZP folders created by max using
    local url = sysInfo.tempdir as string;
    local folders = getDirectories (url+"mzptmp*");--temporay MZP folders
    
    within a next step I loop through all these folders and check for at least the mzp.run file and a folder named "TexTools".

    However if you drag several times the MZP file in the viewport and or from older times (while max still hasn't sweeped the temp files it created) you have the chance of getting the wrong folder or version to copy.

    So I record all timestamps of the mzp.run files within each folder, and sort out the newest one at the end using;
    local _mathchUrls = #();--store possible matches and have them sort by date later
    local _matchDates = #();--sort Array
    for f in folders do (
    	local  has_folder= getDirectories (f+"TexTools");
    	local  has_mzp= getFiles (f+"mzp.run");
    	if (has_folder.count == 1 and has_mzp.count == 1)then(--booth folder and mzp.run file exist
    		local _date = getFileCreateDate has_mzp[1];
    		append _matchDates _date;
    		append _mathchUrls f;
    	)
    )
    if (_mathchUrls.count > 0)then(--found some urls that match our footprint, now sort by date 	
    	local _new = amax _matchDates;--the latest date item
    	local _indx = findItem _matchDates _new;--index of that newest date
    	local final_url = _mathchUrls[_indx];--the newest folder
    	...
    )
    
    This really works nice because it always gets the latest MZP temp folder that matches the footprint of whats inside the MZP archive of TexTools.

    I will have a look at your file later as soon as I finished this- because I am almost done with this installer.
  • renderhjs
    Options
    Offline / Send Message
    renderhjs sublime tool
    the new setup mode is as good as done, some screens:
    web_tt3.0_setup.jpg
    I am also considering for this release to go with a new GUI style using imageTag buttons (instead of just buttons) so that the buttons itself are bigger and tighter together.
    Also I want to go away from the rainbow colors everywhere and get back to gray as a base.
    web_tt3.0_icons.jpg
    thats a first try
  • SerdarDesign
    Options
    Offline / Send Message
    Very nice Render...

    "Also I want to go away from the rainbow colors everywhere and get back to gray as a base."

    - This is a good Idea :) When will you release the new version?
189101113
Sign In or Register to comment.