Community
3ds Max Modeling
Welcome to Autodesk’s 3ds Max Forums. Share your knowledge, ask questions, and explore popular 3ds Max modeling topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Drag n Drop material assign tool

6 REPLIES 6
SOLVED
Reply
Message 1 of 7
govindkpradeep
1122 Views, 6 Replies

Drag n Drop material assign tool

Hello All

I was wondering if there is any way we can drag and drop material among objects. Is there a script available to do so? 
I usually end up creating palettes within the scene which is project specific. Since there are usually lot of back n forth as we do color jet 3d printing it could have been quite useful if I can simply drag a material from an existing pre mapped object to the target object that I want. It should take the material + bitmap + UVW map modifier on the object.

 

Below you can see a palette which I have created. Let me know if someone has this script.

Capture.JPG

 

 

 

many thanks

 

 

6 REPLIES 6
Message 2 of 7
miledrizk
in reply to: govindkpradeep

Hi,

 

I made a script that will allow you to do what you're looking for,

Here is a demo on YouTube on how it works:

https://youtu.be/_Cl0L-6iyIs

 

After installing it you can find it by going to the Customize menu, Customize User Interface,

Click on the Toolbars tab if you want to create a toolbar button for it, now in the Category drop-down list

Look for MiRi-Tools and you'll see in the Action section the script called "matchmaterial"

 

------------------------------------------------------
miledrizk@gmail.com
3DS Max 2021, V-Ray 5.2
3DS Max user since 2003 (3DS Max 7)
V-Ray user since 2008 (V-Ray 1.47)
My YouTube Channel http//www.youtube.com/c/MiledRizk
Message 3 of 7
miledrizk
in reply to: miledrizk

I recommend you download this updated version. I noticed a small bug in it, nothing important,

But in the previous one, sometimes, pressing Enter on the keyboard wasn't working, only the

Right-Click. So in this updated version, the Enter key will always work

------------------------------------------------------
miledrizk@gmail.com
3DS Max 2021, V-Ray 5.2
3DS Max user since 2003 (3DS Max 7)
V-Ray user since 2008 (V-Ray 1.47)
My YouTube Channel http//www.youtube.com/c/MiledRizk
Message 4 of 7
miledrizk
in reply to: miledrizk

Again I'm updating my script (hopefully the last time),

I saw another Bug, and that's when the source object has modifiers but without any UVW Map or

Unwrap UVW, the script fails to match the material. I know in your case you are sure to have a material

And a mapping tool but I'm trying to make my script more general, so please use this second update,

The script is created this evening so it's normal to have a few issues.

------------------------------------------------------
miledrizk@gmail.com
3DS Max 2021, V-Ray 5.2
3DS Max user since 2003 (3DS Max 7)
V-Ray user since 2008 (V-Ray 1.47)
My YouTube Channel http//www.youtube.com/c/MiledRizk
Message 5 of 7
govindkpradeep
in reply to: miledrizk

I love it. It's really good. Is there a way to drag n select when the match material command is working. 

Message 6 of 7
miledrizk
in reply to: govindkpradeep

Hi,

 

I tried to make the script simple and small as much as possible to avoid lots of bugs,

And I'm sure there are some left in special scenarios,

Now I'm doing some intensive tests with different scenarios,

I already caught one in a special case and I'm trying to reproduce it and fix it,

Currently, you can click the script while the material editor is open, you can drag

And drop materials onto objects in the viewport while the script is alive and ready for picking

Targets objects. It also works in some other scenarios.

 

 

------------------------------------------------------
miledrizk@gmail.com
3DS Max 2021, V-Ray 5.2
3DS Max user since 2003 (3DS Max 7)
V-Ray user since 2008 (V-Ray 1.47)
My YouTube Channel http//www.youtube.com/c/MiledRizk
Message 7 of 7
miledrizk
in reply to: govindkpradeep

Hi again 🙂

 

Yesterday I discovered a couple of annoying bugs while doing intensive tests on the script. The first one is when the user press Escape after clicking the script, this caused an error. Also, if the User already picked one target, then clicked The script again, that also was causing an error.

I'm attaching the newly revised version.

 

 

------------------------------------------------------
miledrizk@gmail.com
3DS Max 2021, V-Ray 5.2
3DS Max user since 2003 (3DS Max 7)
V-Ray user since 2008 (V-Ray 1.47)
My YouTube Channel http//www.youtube.com/c/MiledRizk

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report