Multipatch Texture Setup

Discussions concerning plugins for SOFTIMAGE©
Post Reply
User avatar
rray
Moderator
Posts: 1774
Joined: 26 Sep 2009, 15:51
Location: Bonn, Germany
Contact:

Multipatch Texture Setup

Post by rray » 22 Feb 2011, 00:49

Tim Crowson has rewritten his Mari2XSI script supporting a lot of new options

Here's the information he just posted on the mailing list:
I finally got around to revamping our old Mari2XSI script. It was always a very limited script anyway. The new version is an Addon that does a good bit more. If you use this and encounter any problems or glitches, please let me know!

Links:
Info page
Download the Addon
Demo Video


New Features and Changes:
- Installs as a .xsiaddon
- Supports both Mari and Mudbox naming conventions (detects them automatically)
- Renamed to 'Multipatch Texture Setup'
- Implemented via a new command in the Render Tree: User Tools > Multipatch Texture Setup, which launches a custom UI for the setup.
- The new system allows for multiple UV maps on the target mesh.
- Once the compound has been created, you can configure certain settings after the fact, such as the UV map or the color profile depending on your linear workflow setup.
- Currently works with Mental Ray (fo sho!). Exploring Arnold options now. 3delight later...


Now for the disclaimer:
I'm not a codemonkey by nature. I'm primarily a modeling and texture artist, with a hint of Fume. I just use Python in what ways I can to help me get my work done. So if you look at my code, you will be very underwhelmed. For one thing, I just don't understand the whole custom callbacks thing with self-installing plugins, so I resorted to using a big Logic Statement instead. Also, lots of steps could probably use the Object Model instead of the commands, but whatever. It functions well, it's not slow. Works for my needs, maybe it will for yours too.

And if anyone can give me a tutorial on callbacks for custom plugins....I sure do hate all that unformatted red text in the Logic statement...
also featured on (freshly updated) rray.de ;)
softimage resources section updated Jan 5th 2024

El Burritoh
Posts: 151
Joined: 30 Nov 2010, 19:56
Location: Tennessee
Contact:

Re: Multipatch Texture Setup

Post by El Burritoh » 23 Feb 2011, 04:51

Thanks Reinhart!

Currently it only works with Mental Ray. Later this week I'll be updating it again to allow compatibility with Arnold. I don't think it will require any additional update on rray.de, however.


EDIT: Actually, the support for Arnold didn't take as long as I thought. I just updated that download link, so the latest version should support Arnold as well as Mental Ray.
-Tim Crowson
High Nerd, of the Order of Magnetic Nerds
Personal Website

sergiucip
Posts: 2
Joined: 07 Apr 2013, 13:42

Re: Multipatch Texture Setup

Post by sergiucip » 07 Apr 2013, 17:21

Heelo
I install the addon but i have errors with it:

Application.SelectObj("Sources.Materials.DefaultLib.Material", "", "")
Application.SelectObj("Sources.Materials.DefaultLib.Material", "", "")
Application.SelectObjectsUsingMaterial("Sources.Materials.DefaultLib.Material")
Application.SelectObj("Sources.Materials.DefaultLib.Material", "", "")
Application.InspectObj("Sources.Materials.DefaultLib.Material", "All", "", "", "")
Application.SelectObj("Sources.Materials.DefaultLib.Material", "", "")
Application.SelectObj("Sources.Materials.DefaultLib.Material", "", "")
Application.SelectObj("Sources.Materials.DefaultLib.Material.Blinn", "", "")
Application.SelectObj("Sources.Materials.DefaultLib.Material", "", "")
Application.SelectObj("Sources.Materials.DefaultLib.Material", "", "")
Application.SetValue("Sources.Materials.DefaultLib.Material.Name", "Ship", "")
Application.MultipatchSetup()
Application.SetValue("Create_MultiPatch_Texture.uvListParam", 0, "")
Application.SetValue("Create_MultiPatch_Texture.fileDirectory", "D:\\Work\\Carpathia_space\\Pictures\\mari", "")
Application.SetValue("Create_MultiPatch_Texture.channelName", "coro", "")
Application.FindObjects("", "{4C4F7500-51EF-11D0-854E-00A02417D029}")
Application.SetValue("preferences.Interaction.autoinspect", False, "")
# ERROR : Traceback (most recent call last):
# File "<Script Block 2>", line 365, in import_OnClicked
# setupMultiPatchTexture()
# File "<Script Block 2>", line 264, in setupMultiPatchTexture
# for x in range(1, mix8Count+1):
# TypeError: range() integer end argument expected, got float.
# - [line 263 in C:\Program Files\Autodesk\Softimage 2014\Application\bin\sisetpluginvars.py]
# ERROR : Property Page Script Logic Error (Python ActiveX Scripting Engine)
# ERROR : [261] (null)
# ERROR : [262]
# ERROR : >[263] # CREATE THE INITIAL MIX8s AND SET PARAMS --------------------------------------------------------------------------
# ERROR : [264] for x in range(1, mix8Count+1):
# ERROR : [265] xsi.CreateShaderFromProgID("Softimage.sib_color_8mix.1.0", curMat, "Mix_8_Colors"+str(x))
# ERROR : Traceback (most recent call last):
# File "<Script Block 2>", line 365, in import_OnClicked
# setupMultiPatchTexture()
# File "<Script Block 2>", line 264, in setupMultiPatchTexture
# for x in range(1, mix8Count+1):
# TypeError: range() integer end argument expected, got float.
#


Can you help ?

Thank you
Sergiu

sergiucip
Posts: 2
Joined: 07 Apr 2013, 13:42

Re: Multipatch Texture Setup

Post by sergiucip » 08 Apr 2013, 23:25

I fidured out

If you are in trouble to make thi addon work
do this:
1. Deselect Python instaled with XSI 2013/2014
Install python in this order:
a)vcredistx64
b)vcredistx86
allt this file you foun at microsoft (google search)
IMPORTANT:
c)Pytnon 2.6 AMD x64 instaler (version 2.6.6 from python.org)
d)pywin32 AMD coresponding to Python version

2. make a bat file with this lines:
reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment" /v PYTHONPATH /t REG_EXPAND_SZ /d C:\Python26
reg add HKCU\Environment /v PYTHONPATH /t REG_EXPAND_SZ /d C:\Python26

And if u do this correctly u disable the python 2.7.3 ship with XSI2013/2014 and u back at Python 2.6 and everything works great


To test if it working do this:
import sys
import os
import distutils
import distutils.sysconfig
site_packages = distutils.sysconfig.get_python_lib(plat_specific=1)
build_no = open(os.path.join(site_packages, "pywin32.version.txt")).read().strip()
print "Python version: " + sys.version
print "PyWin32 version: " + build_no

Run this code in script editor :
If u disbale python 2.7.3
the result return nothing
If not result show u running pytnon 2.7.3 adn u do something wrong and u make star over withi this steps above

I do this and it is works for me,i cannot guarantee the results but for me WORKS

Greetings
Sergiu

xeraphine
Posts: 31
Joined: 26 Jun 2009, 20:05

Re: Multipatch Texture Setup

Post by xeraphine » 26 Jun 2016, 10:12

Hi, please where i can find the demo video? or the instructions to use this addon? This is the best method for working with mari? Thanks

User avatar
Hirazi Blue
Administrator
Posts: 5107
Joined: 04 Jun 2009, 12:15

Re: Multipatch Texture Setup

Post by Hirazi Blue » 26 Jun 2016, 11:20

It is still available in the "local backup" at rray.de/xsi
Search for "Multipatch Texture Setup" to find the link...
;)
Stay safe, sane & healthy!

xeraphine
Posts: 31
Joined: 26 Jun 2009, 20:05

Re: Multipatch Texture Setup

Post by xeraphine » 27 Jun 2016, 06:04

Thanks Hirazi, i already download it but i still trying to use it, thats why am asking about the video, or the steps. am complete noob texturing multi tile-mari setup.

User avatar
Hirazi Blue
Administrator
Posts: 5107
Joined: 04 Jun 2009, 12:15

Re: Multipatch Texture Setup

Post by Hirazi Blue » 27 Jun 2016, 07:17

Sorry, I wrongly assumed (or was secretly hoping) instructions to be included with the download... =((
Stay safe, sane & healthy!

User avatar
AceMastermind
Posts: 160
Joined: 15 Jun 2009, 00:57
Contact:

Re: Multipatch Texture Setup

Post by AceMastermind » 27 Jun 2016, 17:42

I'm not familiar with this plugin, but does this video look like it could be the missing one?
http://v.youku.com/v_show/id_XMzIzODc1NTky.html

I grabbed the video from my browser's cache and uploaded it if you want to watch it offline:
https://drive.google.com/open?id=0B26xB ... UZwa1lxNms

User avatar
Unaided
Posts: 62
Joined: 26 Feb 2014, 16:35

Re: Multipatch Texture Setup

Post by Unaided » 27 Jun 2016, 22:38

xeraphine wrote:Hi, please where i can find the demo video? or the instructions to use this addon? This is the best method for working with mari? Thanks
UDIM in essence are multiple UV spaces in tiled layout with specific name convention. So uv0-0 or 1001 is the main UV space, and rest represents rows and columns for each additional UV space.

Modo reads automatically this naming convention for files from Mari and loads them in its UV space according its filename.

In SI, without plugins you need load all set maps and apply manually its related offset in UV space.

I wrote this small tool to prepare UV's set for UDIM into SI to use in Mari for example.

Maybe I can update my tool with a autoplace maps according to UDIM naming.

Moderator edit: fixed the link - HB

xeraphine
Posts: 31
Joined: 26 Jun 2009, 20:05

Re: Multipatch Texture Setup

Post by xeraphine » 28 Jun 2016, 17:58

AceMastermind, thanks a lot, please could u upload to another cloud server, long story but google drive its not working for me, and cant see online either.

Unaided, am already using your tool, if you have time to upload the tool, that will be great. Thanks for the contribution.

Still using softimage here.

xeraphine
Posts: 31
Joined: 26 Jun 2009, 20:05

Re: Multipatch Texture Setup

Post by xeraphine » 28 Jun 2016, 19:04

Hey guys, i already manage to use the multipatch plugins, but now am having the same error that post sergiucip:

Code: Select all

Application.MultipatchSetup()
Application.SetValue("Create_MultiPatch_Texture.fileDirectory", "X:\\P_La Loba\\WORK\\SOFTIMAGE\\P_La Loba\\Pictures\\testmultiuv", "")
Application.SetValue("Create_MultiPatch_Texture.channelName", "bump", "")
Application.FindObjects("", "{4C4F7500-51EF-11D0-854E-00A02417D029}")
Application.SetValue("preferences.Interaction.autoinspect", False, "")
# ERROR : Traceback (most recent call last):
#   File "<Script Block 2>", line 364, in import_OnClicked
#     setupMultiPatchTexture()
#   File "<Script Block 2>", line 264, in setupMultiPatchTexture
#     for x in range(1, mix8Count+1):
# TypeError: range() integer end argument expected, got float.
#  - [line 263 in C:\Program Files\Autodesk\Softimage 2015 SP2\Application\bin\sisetpluginvars.py]
# ERROR : Property Page Script Logic Error (Python ActiveX Scripting Engine)
# ERROR :    [261] (null)
# ERROR :    [262] 		
# ERROR :   >[263] 		# CREATE THE INITIAL MIX8s AND SET PARAMS --------------------------------------------------------------------------
# ERROR :    [264] 		for x in range(1, mix8Count+1):
# ERROR :    [265] 			xsi.CreateShaderFromProgID("Softimage.sib_color_8mix.1.0", curMat, "Mix_8_Colors"+str(x))
# ERROR : 	Traceback (most recent call last):
#   File "<Script Block 2>", line 364, in import_OnClicked
#     setupMultiPatchTexture()
#   File "<Script Block 2>", line 264, in setupMultiPatchTexture
#     for x in range(1, mix8Count+1):
# TypeError: range() integer end argument expected, got float.
Is there a form to fix this without messing with the python installs, cuz am using 2.7 versions.

Manualy set 20 udim tiles with mix8nodes changing uv remaps numbers its a nightmare. Thanks guys

Post Reply

Who is online

Users browsing this forum: No registered users and 29 guests