Go Back   AC3D Forums > Technical > AC3D Developers
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Display Modes
Old 22nd March 2004, 09:42 PM   #1
monster
Member
Advanced member
 
Join Date: Dec 2003
Location: Melbourne, Australia
Posts: 39
Default Problems with ac_register_file_exporter

Previously, in my plugin, I was using;
Code:
ac_add_command("my_exporter",my_exporter);    
ac_add_export_menu_item("My Format...","ac3d my_exporter");
To register my export function with AC3D, as I use ac_register_file_importer to register my import function I thought I'd switch to use ac_register_file_exporter as it seemed to be more consistent (and possibly more up to date?).
However, now the exporter gets added to the export menu, but when I click on it nothing happens except that I get the following message in the console;
Code:
incorrect number of args for exporter_select_file (should be 1, got 2) - usage:
    <string exporter-name>
I've changed my export function to have the signature;
Code:
Boolean my_exporter(char *filename, ACObject *object)
Is there anything else I need to do?
monster is offline   Reply With Quote
Old 23rd March 2004, 04:54 AM   #2
Andy
Administrator
Professional user
 
Andy's Avatar
 
Join Date: Jun 2003
Posts: 4,563
Default Re: Problems with ac_register_file_exporter

I suspect the exporter name has a space in it - this needs removing.

You are correct that adding an exporter this way is the way to go (although the old method will still work).

Andy
Andy is offline   Reply With Quote
Old 23rd March 2004, 07:15 AM   #3
monster
Member
Advanced member
 
Join Date: Dec 2003
Location: Melbourne, Australia
Posts: 39
Default Re: Problems with ac_register_file_exporter

Ah yes, that'll be it. Thanks Andy.
Interestingly though ac_register_file_importer works even with a space in the name!
monster is offline   Reply With Quote
Reply

Thread Tools
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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



All times are GMT -4. The time now is 02:08 PM.


AC3D Forum
(C) Inivis Limited 2020