View Full Version : mental mill (Shaders, Tips, Tricks, etc)...
PiXeL_MoNKeY 04-18-2009, 04:33 AM Lets start this off with some basic tips on using mental mill shaders in 3ds Max 2010:
Q: Where is Mental Mill in 2010 ? (http://forums.cgsociety.org/showpost.php?p=5786028&postcount=1)
A: It is on your install DVD, it can be accessed from the install UI > Install Tools or Utilities > mental mill Artist Edition. Or you can manually navigate to the Support > Partners > MentalMill folder. It can also be downloaded from the Autodesk Support site here (http://usa.autodesk.com/adsk/servlet/ps/dl/item?siteID=123112&id=13091718&linkID=9241178).
Q: Anyone figure out how to get shaders from Mental Mill to Max? (http://forums.cgsociety.org/showpost.php?p=5787011&postcount=10)
A: File > Save As > .XMSL. This is then loaded into the 3ds Max DirectX Shader.
Q: One question...if you do a meta Sl shader, when you render it inside mental ray, can you get real reflections and refractions? (http://forums.cgsociety.org/showpost.php?p=5808944&postcount=20)
A: Yes you can. You will need to add a Component_Reflection and/or Component_Refraction node into your Phenomenon network. It is these Component nodes that instruct mental ray to do raytracing at render time. See my post on the mental mill forum here (http://forum.mentalimages.com/showthread.php?t=5299).
Tips: Some helpful tips from JeffPatton (http://forums.cgsociety.org/showpost.php?p=5787051&postcount=13)*:
*You must make your custom shader a phenomena.
*You must end the phenomena with a node that has a single output.
*If using texture nodes, you'll need to add a state_uv input to the texture node.
Your phenomenon can only have a single output result.
Official mental mill pages:
mental mill forums (http://forum.mentalimages.com/forumdisplay.php?f=10)
mental mill product page (http://www.mentalimages.com/products/mental-mill.html)
Difference between mental mill Artist Edition and Standard Edition
(http://www.mentalimages.com/products/mental-mill/artist-edition.html)
Exising mental mill threads:
XSML shaders (http://forums.cgsociety.org/showthread.php?f=6&t=752665)
Mental Mill (http://forums.cgsociety.org/showthread.php?f=6&t=749239)
mental mill :: Software Feature (http://forums.cgsociety.org/showthread.php?f=59&t=731932)
So lets start sharing our shaders, tips, tricks, questions, and .xmsl shaders.
-Eric
|
|
Arashi2
04-24-2009, 10:28 PM
Hello,
i played around with mental mill a little bit and i got everything to work, but neither in the viewport nor in mental ray i get the alpha channel to work. I tried it with the alpha value in illuminate_phong node and over a texture mask with the comp_set_alpha node but none of both work.
How do i get the alpha channel to work?
Thanks in advance
thorsten hartmann
04-27-2009, 07:50 AM
Hi
ask the 3D-Guru Ruediger on the mental images Forum, he knows all about mental mill. :thumbsup:
german mental ray Treads about mental mill: http://www.germanmentalray.de/viewforum.php?f=55
PS: In 3dsmax2010 is a bug, when you want render the DirectX Shader. Change in Windows from "." to ","... than works fine ...
control panel => Regional and Language Options => Number : 123,456,789.00
mfg
hot chip
From Zap Andersson on Mental Images forum:
"Go to your windows Control Panel => Regional and Language Settings => Regional Options tab, the "number format" button, and make sure the "Decimal Separator" is a dot, not a comma, I.e. that decimals are written 1.0 not 1,0"
focomoso
05-02-2009, 11:35 AM
Holy crap, it works! Thanks for the help.
PiXeL_MoNKeY
05-03-2009, 01:46 AM
By default the shipping version of mental mill Artist Edition has the ability to add 3rd party .msl files disabled, however you can manually add them yourself.
1) Navigate to: \mental images\mental mill Artist Edition\shaders folder.
2) Open the mill_toolbox.xml file in a text editor.
3) At the end of the document add a new entry similar to:<metasl_code file_name="my_new_shader.msl"/> You need to include the full path, or make sure the file is in the shaders folder.
4) Save the modified mill_toolbox.xml and open mental mill Artist Edition.
Adding new shaders to the Toolbox.
1) Search for the shader in search box at the bottom of the toolbox.
2) a) Create a New Folder by right-click > New Folder on the Root folder.
b) Unlock an existing folder by right-click > Unlock Folder.
3) Drag your new shader to the desired folder.
**NOTE 1: for .xmsl files using any non-default shaders to work in 3ds Max 2010 you need to use the full path to the file in the mill_toolbox.msl file, or copy the .msl to the: \3ds Max 2010\hardwareshaders\MetaSL folder. Or you can modify the entries to the file in the .xmsl file in a text editor to add the full path.
**NOTE 2: when renaming folders from the UI they must start with non-numeric characters. For example, you can rename a folder "Third_Party", but not "3rd_Party". To do it manually search your user folder for the mill_treeview.tvx file. Open it in a text editor, find the desired folder entry, and rename it. Example, using this method I can rename "Third_Party" to "3rd_Party" and save the document. The next time I open mental mill the folder will be named properly.
**NOTE 3: for shaders written by 3rd parties to work, you need to have all the shaders it references in the shader folder and added to the mill_toolbox.msl file. Some shaders found on the mental images forums may reference shaders that are only available in the Standard Edition.
-Eric
focomoso
05-03-2009, 10:09 PM
1) Search for the shader in search box at the bottom of the toolbox.
This is the step I was missing. Thanks for that.
focomoso
05-03-2009, 11:08 PM
Using the full path, I'm able to get the shader to work in the viewport in max, but not when rendering. It throws a "shader not found" error. Any thoughts?
PiXeL_MoNKeY
05-04-2009, 12:31 AM
Without having the exact .msl and .xmsl file it would be hard to diagnose. Since I have no idea if its a shader the .msl is trying to load, or Max not liking it because its not in the hardwareshaders folder, or what.
-Eric
focomoso
05-04-2009, 01:53 AM
I tried again using a relative path and putting the shader in the hardware shaders folder, but I still have the same problem. It works in mental mill and the viewport, but errors out when rendering. Is there another place I might need to put it?
PiXeL_MoNKeY
05-04-2009, 02:23 AM
The problem is probably in the .xmsl shader, but can't do anything but guess without seeing the shaders.
-Eric
focomoso
05-04-2009, 03:00 AM
If you have the time, here's the .xmsl and the .msl zipped up. I just copied the code from Generator_brick.msl as a template. It works fine in mental mill and fine in the viewports, but not when rendering.
Thanks for all your help on this.
PiXeL_MoNKeY
05-04-2009, 03:53 AM
I have no idea. I would go post it to the actual mental mill forums.
-Eric
focomoso
05-04-2009, 08:12 AM
I have no idea. I would go post it to the actual mental mill forums.
I'll give it a shot, but I suspect they might not be too excited about questions on how to work around the limitations deliberately built into their software.
PiXeL_MoNKeY
05-04-2009, 04:06 PM
That shouldn't be an issue since the Standard Edition does allow you to load custom .msl files. The problem is in Max or the .xmsl file.
-Eric
depleteD
05-05-2009, 01:38 PM
Can we make a volume shader?
Glacierise
05-05-2009, 02:44 PM
Heh that'd be great but I doubt it :) I think the next big hope for volumetrics is the Krakatoa voxels, that with some cool coloring can look magnificent!
depleteD
05-05-2009, 03:19 PM
http://www.binaryalchemy.de/index_dev.htm
ah anything is possible.... :)
I really cant wait to get my hands dirty with mental mill
Glacierise
05-05-2009, 03:23 PM
Yeah people have been asking for binary alchemy to come to max for a long time now, it would be awesome if it happens :)
PiXeL_MoNKeY
05-05-2009, 03:50 PM
There are some basic volume fog .msl files that come with it, so maybe you could hack that to do what you want. Or find some existing volume .fx code and convert it to .msl.
-Eric
Glacierise
05-05-2009, 03:58 PM
Does it have 3d noises?
focomoso
05-05-2009, 09:39 PM
Does it have 3d noises?
Yes... (4d...)
Glacierise
05-06-2009, 08:51 AM
That's definitely interesting then - if we have fractals and volume shaders, lots of options open up :)
focomoso
05-07-2009, 06:44 PM
Using the full path, I'm able to get the shader to work in the viewport in max, but not when rendering. It throws a "shader not found" error. Any thoughts?
To follow up on this for anyone who might discover this thread. It seems that you cannot code custom shaders in max even using the full version of mental mill. You can combine any of the shaders that come with mental mill artists addition and (I think) use other shaders that have been compiled for max, but according to the mental mill forum, max needs a .dll to be compiled from the .msl files to work in software rendering.
This sucks for me, but maybe they (or someone) will come out with a metaSL to max .dll compiler.
PiXeL_MoNKeY
05-07-2009, 07:10 PM
Look over the forums, there is the cil compilation which does on the fly compiling using .Net (or Visual Studio Express). However, this is not enabled with mr by default. I believe this is one of the solutions that ruediger referred to, there is a thread (http://forum.mentalimages.com/showthread.php?t=5353) about it on the mental mill forums. Though I am not exactly sure where the registry stuff goes to make it work, I personally haven't tried it because I don't want to have to worry about setting up the render farm with extra software just to get them to render.
It was a little bit of a disappointment to find all of this stuff out. Hopefully there will be a solution in the future where we don't need extra tools to render custom .msl shaders in mr.
-Eric
focomoso
05-11-2009, 08:24 PM
I couldn't find the reg entries either. I'm going on vacation. When I get back I'll look into this, though it would be so much easier if we could just compile the .msl files directly from mental mill...
focomoso
06-26-2009, 10:04 AM
I'm back...
Has anyone tried this? Gotten it to work? I've asked at the mental ray forum, but there doesn't seem to be much traffic.
Anyone...?
ctrl.studio
06-29-2009, 02:11 AM
you can add registry variables to any .mi file. startup 3rdparty mi file will be just the best place probably.
max
CGTalk Moderation
06-29-2009, 02:11 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.
vBulletin v3.0.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.