Page 1 of 1

fatal error C1083

Posted: Wed Oct 15, 2014 3:30 am
by we0704
hello,
when I "#include "../qCC/mainwindow.h" in qDummyPlugin.h,the following error occured:
"fatal error C1083: Cannot open include file:“ui_mainWindow.h”: No such file or directory"
how can I solve it
Thanks for any help

Re: fatal error C1083

Posted: Wed Oct 15, 2014 5:46 am
by daniel
Indeed,

Plugins don't have a direct access to most of the classes of the 'CloudCompare' executable project (contrarilly to the libraries: CC_Core_Lib, qCC_db, qCC_gl and qCC_io).

To access stuff from the main application you must use the 'ccMainAppInterface'. All standard plugins have a member 'm_app' that implements this interface.

If you miss something in this interface we can discuss whether it's a good idea to modify it or if there are other ways to achieve what you are trying to do.

Re: fatal error C1083

Posted: Wed Oct 15, 2014 6:33 am
by we0704
Thank you.
I want complete the function like the "swap" in "Cloud Registration",if I clicked the "swap" button,the color of the selected enties will change.
1.jpg
1.jpg (185.2 KiB) Viewed 5850 times

Re: fatal error C1083

Posted: Wed Oct 15, 2014 8:28 am
by daniel
Then the best way it to create your own dialog for the plugin (by duplicating most of the content of an existing one if necessary). See how other plugins (such as qPoissonRecon, qRansacSD, etc.) do this.

You can also copy the more simple 'Choose entity role' dialog (ccOrderChoiceDlg).

P.S. : this kind of very simple dialog (such as ccOrderChoiceDlg) could be put in a separate library. But it's rare that a plugin use the exact same dialog as an application (for now) so we haven't done it yet.

Re: fatal error C1083

Posted: Fri Oct 17, 2014 6:51 am
by we0704
Thank you very much.