CGTalk > Software > Autodesk Maya > Maya Rendering
Login register
reply share thread « Previous Thread | Next Thread »
 
Thread Tools Search this Thread Display Modes
Old 09-15-2014, 10:44 AM   #1
Pahuska
Veteran
 
Pahuska's Avatar
portfolio
FERRACHAT Guillaume
Maya Rigging/Scripting
Valence, France
 
Join Date: Feb 2012
Posts: 79
Xgen & Arnold issues

Hello,

I have two problems with Xgen maya & Arnold (I don't know if they're linked or not) and it's driving me crazy.

First one is whenever I try to export an archive with an Arnold shader on it, I got a message saying "Pythoninterpreter has stopped working", and then arnold tells me that :

* CRASHED in Tstring::operator==
* signal caught: error C0000005 -- access violation

Second is I can't render any custom primitives with arnold & Xgen. I tried with spheres and it works fine, but when I switch to archives, import my archives and apply a shader, it doesn't render.
 
Old 09-15-2014, 01:40 PM   #2
ytsejam1976
Maya Light Finder
 
ytsejam1976's Avatar
portfolio
Dario Ortisi
3D modeler and render
Dallara Engineering at Simulator
Italy
 
Join Date: Apr 2008
Posts: 977
Create an object to use as archive in another scene, delete history, rename the object without numbers or : save and export this object as archive. Don't set arnold as render engine for now.
__________________
www.darioortisi.it
MayAdvanced Blog
My youtube channel
 
Old 09-15-2014, 05:12 PM   #3
Pahuska
Veteran
 
Pahuska's Avatar
portfolio
FERRACHAT Guillaume
Maya Rigging/Scripting
Valence, France
 
Join Date: Feb 2012
Posts: 79
Thanks for your reply.
It doesn't work either.
I also tried to export the archive with the lambert1, then imported them without material and applied an Arnold shader on the collection, but it doesn't render the archives. It works fine with Mental Ray but I'd prefer to work with Arnold because of the userData nodes.
 
Old 09-18-2014, 10:11 AM   #4
Pahuska
Veteran
 
Pahuska's Avatar
portfolio
FERRACHAT Guillaume
Maya Rigging/Scripting
Valence, France
 
Join Date: Feb 2012
Posts: 79
I found out what was wrong. When exporting the archives, maya is supposed to create an alembic, a .mi for mental ray and a .ass for arnold. For some reason maya doesn't create the .ass file when I export my models, so I exported it manually, and added it manually in the archive (either by editing the xarc file or by editing it in maya after adding it to the description)
 
Old 11-13-2014, 10:18 PM   #5
prekabreki
New Member
portfolio
 
Join Date: Nov 2014
Posts: 3
Quote:
Originally Posted by Pahuska
I found out what was wrong. When exporting the archives, maya is supposed to create an alembic, a .mi for mental ray and a .ass for arnold. For some reason maya doesn't create the .ass file when I export my models, so I exported it manually, and added it manually in the archive (either by editing the xarc file or by editing it in maya after adding it to the description)


I'm having the same problem and it's driving me insane. Could you go into more detail about how you fixed it please? I'd be so grateful!
 
Old 08-18-2015, 10:43 AM   #6
mareyus
New Member
portfolio
 
Join Date: Jun 2014
Posts: 4
Hey Pahuska, I have the exact same issue. Could you describe in more detail what you did, please?
 
Old 10-08-2015, 02:16 PM   #7
duveil
New Member
mustafa yılmaz
telesine
istanbul, Turkey
 
Join Date: Apr 2006
Posts: 1
Hi Pahuska
I have the same problem and I couldn`t find a solution yet..Any progress about this problem ?
 
Old 10-31-2015, 10:00 AM   #8
strangerman
3D peasant
portfolio
Jorge García
Madrid, España
 
Join Date: Nov 2003
Posts: 22
There seems to be a bug in the arnold-xgen exporter to archives (Maya 2016, maybe 2105 also). For whatever reason it can't export a thing if arnold is involved in any way in the process, meaning you can't export nodes with arnold shaders or being arnold itself the current renderer. Even the geometry can't have any of the arnold attributes or it'll fail. A workaround would be exporting the geometry setting any renderer but arnold as the current renderer and assingning lambert placeholder materials to your objects. Once done, you'll have the usual file structure able to be renderer in MR. Create a folder called "ass" inside the "archives" folder beside the "mi", "material" and "abc" folders. Select your geometry and export to ASS to this "ass" folder making sure you activate the "export bounding box" and "use gzip compression (.ass.gz) options. Add the required lines to the .xarc file pointing to your newly created arnold .ass.gz file (take the existing lines as template changing the "mi" part to "ass". You'll may have an error saying maya is unable to find the route. I don't know why, but the arnold parser which reads this file seems to have a hardcoded "/" after the "{$PROJECT}" part, so you can safely delete it leaving it as this ""{$PROJECT}your/path/to/archives". Import the archives into your description an save the file. Cry of joy.
__________________
Jorge
 
Old 11-25-2015, 11:41 PM   #9
hahmad4
New Member
portfolio
Haris Ahmad
Bradford, United Kingdom
 
Join Date: Dec 2008
Posts: 6
Quote:
Originally Posted by strangerman
There seems to be a bug in the arnold-xgen exporter to archives (Maya 2016, maybe 2105 also). For whatever reason it can't export a thing if arnold is involved in any way in the process, meaning you can't export nodes with arnold shaders or being arnold itself the current renderer. Even the geometry can't have any of the arnold attributes or it'll fail. A workaround would be exporting the geometry setting any renderer but arnold as the current renderer and assingning lambert placeholder materials to your objects. Once done, you'll have the usual file structure able to be renderer in MR. Create a folder called "ass" inside the "archives" folder beside the "mi", "material" and "abc" folders. Select your geometry and export to ASS to this "ass" folder making sure you activate the "export bounding box" and "use gzip compression (.ass.gz) options. Add the required lines to the .xarc file pointing to your newly created arnold .ass.gz file (take the existing lines as template changing the "mi" part to "ass". You'll may have an error saying maya is unable to find the route. I don't know why, but the arnold parser which reads this file seems to have a hardcoded "/" after the "{$PROJECT}" part, so you can safely delete it leaving it as this ""{$PROJECT}your/path/to/archives". Import the archives into your description an save the file. Cry of joy.


Thanks strangerman! I still can't seem to render any xgen descriptions with arnold in maya 2016! No matter if I export my object as the default abc archive or try it as an .ass file...I just can't seem to get my head around why I can't see it in the render! Any ideas what I might be doing wrong? Thanks for your help!
 
Old 12-03-2015, 02:22 PM   #10
thewall92
Explorer
portfolio
daniele la mura
London, United Kingdom
 
Join Date: Apr 2014
Posts: 8
Me too, I'm using maya 2016 and arnold. I tried exporting a simple cube with lambert1, create an xgen description and it works, but when I render nothing is visible.
Also, strangerman, can you please post a "before/after" example? I couldn't understand what you mean with "Add the required lines to the .xarc file pointing to your newly created arnold .ass.gz file". I have more than one line even if I only had assigned one material to the object, see this example:

Code:
#ArchiveGroup 0 name="scaleTest" description="No description." thumbnail="scaleTest.png" materials="${PROJECT}/xgen/archives/materials/scaleTest.ma" color=[1,0,0] 0 "${PROJECT}/xgen/archives/abc/scaleTest.abc" material=scaleTest:mia_material_x1SG objects=|scale1 1 "${PROJECT}/xgen/archives/abc/scaleTest.abc" material=scaleTest:mia_material_x1SG objects=|scale1 2 "${PROJECT}/xgen/archives/abc/scaleTest.abc" material=scaleTest:mia_material_x1SG objects=|scale1 3 "${PROJECT}/xgen/archives/mi/scaleTest__scale1.mi.gz" material=scaleTest:mia_material_x1SG objects=|scale1 4 "${PROJECT}/xgen/archives/mi/scaleTest__scale1.mi.gz" material=scaleTest:mia_material_x1SG objects=|scale1 5 "${PROJECT}/xgen/archives/mi/scaleTest__scale1.mi.gz" material=scaleTest:mia_material_x1SG objects=|scale1


EDIT:now I got it working, here it is how I did it:
take the .xarc code I wrote before as an example, that's what you get when you export an object with a mia material x.
change that in this:

Code:
#ArchiveGroup 0 name="scaleTest" description="No description." thumbnail="scaleTest.png" materials="${PROJECT}xgen/archives/materials/scaleTest.ma" color=[1,0,0] 0 "${PROJECT}xgen/archives/abc/scaleTest.abc" material=aiStandard1SG objects=|scale1 1 "${PROJECT}xgen/archives/abc/scaleTest.abc" material=aiStandard1SG objects=|scale1 2 "${PROJECT}xgen/archives/abc/scaleTest.abc" material=aiStandard1SG objects=|scale1 3 "${PROJECT}xgen/archives/ass/scaleTest.ass.gz" material=aiStandard1SG objects=|scale1 4 "${PROJECT}xgen/archives/ass/scaleTest.ass.gz" material=aiStandard1SG objects=|scale1 5 "${PROJECT}xgen/archives/ass/scaleTest.ass.gz" material=aiStandard1SG objects=|scale1


Obviously change the shading group with the one of the shader you want to assign.
Now it works as it should! thank you strangerman, you rock!
I recorded a video for how to do it:

Last edited by thewall92 : 12-03-2015 at 04:45 PM.
 
Old 12-03-2015, 05:43 PM   #11
curtis10945
Lord of the Eyes
 
curtis10945's Avatar
portfolio
!@#$
Rendererist
USA
 
Join Date: Mar 2015
Posts: 681
Seems like a lot of work.
What if you had ten different materials with ten different xarc's?
Is this a bug or ADSK wanting you to use native Mental Ray?
Seems like a script could fix this renaming thing or maybe the Solid Angle pples could look at it coding wise.
Thanks for the tutorials video.
 
Old 03-04-2016, 07:06 PM   #12
vsanghan
Explorer
portfolio
Vishal Sanghani
India
 
Join Date: Apr 2015
Posts: 10
Working model.

I have fixed the issue with Maya2016 and arnold. This could work with other Maya versions also. I'm on win10 system.
There are only two places where you need do the changes and it should up and running.

Here's the procedure :
1) Open C:\Program Files\Autodesk\Maya2016\plug-ins\xgen\plug-ins\xgenMR.py
Add the bold line in the scrip (Make sure you copy the .py at safe place before changing it.)

import sys
sys.path.append( 'C:\solidangle\mtoadeploy\2016\scripts' )
import maya.standalone
maya.standalone.initialize()
import maya.cmds as cmds


2) Open C:\Program Files\Autodesk\Maya2016\plug-ins\xgen\scripts\xgenm\xmaya\xgenMRExport.py (save a safe copy)
Add the bold line in the scrip

# Export Init callback. Must fill in som arrays on self
def xgmrArchiveExportInit( selfid ):
self = castSelf(selfid)
self.batch_plugins.append( "Mayatomr" )
self.batch_plugins.append( "xgenMR.py" )
self.batch_plugins.append( "mtoa" )

Open maya and run the xGen archive from menu.

P.S. When I ran it first time the maya got crashed but that had created all the related files. On the second attempt it was very smooth and Maya did not crash.
 
Old 03-05-2016, 11:21 AM   #13
thewall92
Explorer
portfolio
daniele la mura
London, United Kingdom
 
Join Date: Apr 2014
Posts: 8
Yess! This definitely works! thank you very much!
 
Old 03-07-2016, 10:53 AM   #14
hahmad4
New Member
portfolio
Haris Ahmad
Bradford, United Kingdom
 
Join Date: Dec 2008
Posts: 6
Thank you very much for getting that to work vsanghan! It finally works!

Just a quick question...I get an error "// Error: XGen: Failed to open file: /__collection.xgen //" when I render a scene with a xgen description in it. It renders it despite the error. Any idea what might be causing this? Thanks a bunch!
 
Old 03-09-2016, 04:32 AM   #15
vsanghan
Explorer
portfolio
Vishal Sanghani
India
 
Join Date: Apr 2015
Posts: 10
Quote:
Originally Posted by hahmad4
Thank you very much for getting that to work vsanghan! It finally works!

Just a quick question...I get an error "// Error: XGen: Failed to open file: /__collection.xgen //" when I render a scene with a xgen description in it. It renders it despite the error. Any idea what might be causing this? Thanks a bunch!


Happy for you guys that the solution working for you too!!

I have not came across this error.
But, I'm facing issue with arnold shader property, it doesn't behave they way it behaves normally. Specifically opacity. I have populated trees with leaf which has alpha to cut out the shape of it. As a work around I'm exporting MEL file and re-importing it in fresh file (maya import it as instance geo) and with instance geo opacity seems working fine. (May be because it understands the opaque check box under shape node, which xGen doesn't.)

Share any other workaround if you have cracked one.
 
reply share thread


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
CGSociety
Society of Digital Artists
www.cgsociety.org

Powered by vBulletin
Copyright ©2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump
Miscellaneous

All times are GMT. The time now is 01:02 PM.


Powered by vBulletin
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.