Arnold flushing

35 views
Skip to first unread message

José Miguel Aragüés

unread,
Nov 3, 2017, 6:43:19 AM11/3/17
to maya_he3d
Hi there people;
I'm making a wheel tiretread with displacement. Everything was fine when using TGA files as displacement, but then I realised it was much better approach to use EXR since I don't have to deal with displacement instensities, EXR is float, so everything displaces in world units.
Great!
The problem is that now, if I don't flush the caches before rendering takes place, the displacement explodes out of boundaries O_o
Anyway, is there a pre-render mel command to flush caches before rendering?, the flush menu button doesn't have a executable code (I tried to put is on a shelf and see its code, but it is super strange to me).
Any advice is welcome :)

Balazs Pataki

unread,
Nov 6, 2017, 11:32:35 AM11/6/17
to maya_he3d
Since you didn't provide any example, this is my theoretical advice list.

First of all, displacement is always in world units. The difference between TGA and EXR should be only in how precise data you have, so you don't have banding problem. TGA is 8bits per channel, EXR can be 16-32bits. Another thing, if you want to be memory friendly, convert your textures to tx.
If you want to flush textures you can this MEL command:
arnoldFlushCache -textures true;
If you want to flush everything:
arnoldFlushCache -flushall true;

When doing IPR your texture gets loaded into memory, and if it doesn't find it, it uses the default value of 0.5.
Flushing can solve the problem since it rereads data into memory.
Also, a way you could debug your displacement values is connect your displacement shader's displacement attribute into a custom channel(alSurface, for example, has this) and you can color pick to see what values you get.(For example Arnold RenderView's Pixel Information on the custom AOV)

joie

unread,
Nov 6, 2017, 1:01:02 PM11/6/17
to maya...@googlegroups.com
Thank you, that's the code I need. Where did you find it?, There is no Mel code section on mtoa documentation page...

--
You received this message because you are subscribed to a topic in the Google Groups "maya_he3d" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/maya_he3d/PXrl5vNiSWk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to maya_he3d+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Balazs Pataki

unread,
Nov 6, 2017, 1:16:36 PM11/6/17
to maya_he3d
If you check the mtoa scripts, in the mtoa/ui/arnoldmenu.py python file you can find what each menuItem calls.
To unsubscribe from this group and all its topics, send an email to maya_he3d+...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages