Fine-tuning Alembic Export
-
On 26/02/2013 at 15:44, xxxxxxxx wrote:
We haven't moved to r14.034 yet - will probably put a dev machine on it in the next 24 hrs.
Curious if the configuring the alembic export from Python as discussed in this thread is now supported.
-
On 11/04/2013 at 15:40, xxxxxxxx wrote:
Revisiting this post just so we're on the same page:
As of the R14.034 update, this bug remains: Users must still manually specify the alembic export frame range.
-
On 12/04/2013 at 02:37, xxxxxxxx wrote:
Originally posted by xxxxxxxx
As of the R14.034 update, this bug remains: Users must still manually specify the alembic export frame range.
Hi Eddie,
The fix for changing importer/exporter settings hasn't been yet published.
It's expected for the next service update (3rd of R14). -
On 27/06/2013 at 18:17, xxxxxxxx wrote:
It looks like there was some attention paid to this in the latest release (R14.041). It now is able to access and update the exporter private data. Or at least appears to:
Something like this Python function:
> def plugindata() :
>
> exporter={} # Creates container for Message return object
>
> plug=c4d.plugins.FindPlugin(1028082, c4d.PLUGINTYPE_SCENESAVER)
>
> doc=c4d.documents.GetActiveDocument()
>
> fps=doc.GetFps()
>
> if plug:
>
> if plug.Message(c4d.MSG_RETRIEVEPRIVATEDATA,exporter) :
>
> data=exporter['imexporter'].GetDataInstance()
>
> start=doc.GetMinTime()
>
> end=doc.GetMaxTime()
>
> data.SetTime(c4d.ABCEXPORT_FRAME_START,start)
>
> data.SetTime(c4d.ABCEXPORT_FRAME_END,end)It also updates the start/end export frame range. It sets them to 0. No matter what value is passed to either. I know it's "working" because I can control which parameter I want to set to zero by commenting out alternating data.SetTime instructions.
Am I just missing something, or is this still not working?
-
On 28/06/2013 at 01:24, xxxxxxxx wrote:
Originally posted by xxxxxxxx
It also updates the start/end export frame range. It sets them to 0. No matter what value is passed to either. I know it's "working" because I can control which parameter I want to set to zero by commenting out alternating data.SetTime instructions.
Am I just missing something, or is this still not working?
Hi Eddie,
ABCEXPORT_FRAME_START and ABCEXPORT_FRAME_END aren't BaseTime but LONG values in the Alembic export container. So you have to pass a frame number to set them successfully.
-
On 28/06/2013 at 10:32, xxxxxxxx wrote:
Interesting.
Alembic itself supports float frames - which can be critical for capturing motion blur, especially while exchanging data between packages - but see, if I pass a float to either of those parameters, I get "argument 2 must be c4d.BaseTime, not float" - so the error message I get explicitly suggests I have to pass a BaseTime argument, not a LONG int.
If I pass an INT or a LONG, I get the same error - that "argument 2 must be a c4d.BaseTime, not _____" fill in the blank of whatever type I pass.Give it a try. I think this still isn't working.
-
On 29/06/2013 at 06:52, xxxxxxxx wrote:
Got it - it's a SetLong instead of a SetTime.
-
On 26/02/2014 at 11:31, xxxxxxxx wrote:
Hi,
I up this thread because the code above and the script ExportAlembic.py (help/examples/scripts) were working fine in R14.041 but don't seem to work anymore in R15.037 or R15.057.
Is there a trick or another way to modify export settings or is it a regression bug ?
Thanks,
xs_yann
-
On 27/02/2014 at 01:25, xxxxxxxx wrote:
Thanks for reporting this bug. I reported it to the developers.
I'm afraid there's no other way to change exporters/importers settings. -
On 03/08/2017 at 06:28, xxxxxxxx wrote:
Hello,
Related question,
I am trying to access some of the other common alembic export settings...
eg. [c4d.ABCEXPORT_SPLINES] [c4d.ABCEXPORT_HAIR] [c4d.ABCEXPORT_SDS_WEIGHTS] etc.
...in much the same way as offered in the python alembic export example in the documentation.
Sadly however, it appears as though these values (and others) are not supported on export as these values are not being changed? I'd like to be able to customize all of these values if possible please?
Should I try SetWorldPluginData() right before export instead?
Regards
-
On 03/08/2017 at 07:17, xxxxxxxx wrote:
Everything is in the code you provide above on github.
As you may already know using [parameter_name] allow you to change any parameter.
So in this exemple its a tool. The tool is grab byplug = plugins.FindPlugin(1028082, c4d.PLUGINTYPE_SCENESAVER)
Then understand plug as a variable who hold the tool.
So now you simply have to set plug[parameter_name] = your value
And thats it ! -
On 03/08/2017 at 07:34, xxxxxxxx wrote:
Thank you for the reply,
However this is what I am having problems with. While I can override some things, there does appear to be a whole bunch of these variables which I can't seem to access.
So for example:
# Begin Alembic export phase # Get Alembic export plugin, 1028082 is its ID plug = plugins.FindPlugin(1028082, c4d.PLUGINTYPE_SCENESAVER) if plug is None: return op = {} # Send MSG_RETRIEVEPRIVATEDATA to Alembic export plugin if plug.Message(c4d.MSG_RETRIEVEPRIVATEDATA, op) : print '{} Loading Alembic plugin: {}'.format(self.debug_string, op) if "imexporter" not in op: print '{} Export Failed: There was a problem with the Alembic plugin: {}'.format(self.debug_string, op) return # BaseList2D object stored in "imexporter" key hold the settings abcExport = op["imexporter"] if abcExport is None: return # Change Alembic export settings abcExport[c4d.ABCEXPORT_FORMAT] = abc_export_format abcExport[c4d.ABCEXPORT_FRAME_START] = frame_from_export #WORKS! abcExport[c4d.ABCEXPORT_FRAME_END] = frame_to_export #WORKS! abcExport[c4d.ABCEXPORT_FRAME_STEP] = frame_step #WORKS! abcExport[c4d.ABCEXPORT_SUBFRAMES] = subframes #UNCONFIRMED abcExport[c4d.ABCEXPORT_SELECTION_ONLY] = True #WORKS! abcExport[c4d.ABCEXPORT_SPLINES] = True #FAILS abcExport[c4d.ABCEXPORT_SDS_WEIGHTS] = True #FAILS abcExport[c4d.ABCEXPORT_PARTICLES] = True #WORKS abcExport[c4d.ABCEXPORT_PARTICLE_GEOMETRY] = False #WORKS etc...
Running 18.057
-
On 04/08/2017 at 03:11, xxxxxxxx wrote:
Hi Matt,
The options you're referring to can be changed and does affect the Alembic export.
You should try to print their value before and after changing these. -
On 04/08/2017 at 04:28, xxxxxxxx wrote:
Hi Yannick,
I just can't seem to change these settings. I'm on a mac. This just does not work for me:
abcExport[c4d.ABCEXPORT_SPLINES] = True
Curiously, when i try to change it's value by dragging the Alembicabc[c4d.ABCEXPORT_SPLINES] globalplugin export prefs into the console, it also won't change while some other values do...
Am I doing something wrong?
regards.