"Interpolate from another entity" via command line

Feel free to ask any question here
Post Reply
johannes.schwank
Posts: 3
Joined: Fri Aug 28, 2020 1:16 pm

"Interpolate from another entity" via command line

Post by johannes.schwank »

Hey,

this is my first question here, but I already read a lot. My specific question is about the function "Interpolate from another entity" and how I am able to access this via command line.

In another thread, it has been mentioned that it should be easy to implement this myself since CC is open source. But anyhow, I cannot find a way or tutorial how to do this. Can someone help me here with some tips?
Or is it even possible to include this command to the list of commands?

Thanks
Johannes
daniel
Site Admin
Posts: 7712
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: "Interpolate from another entity" via command line

Post by daniel »

Yes, all the methods of the graphical version are not ported to the command line mode.

To add a command you need to add an entry to the ccCommandLineCommands class:
https://github.com/CloudCompare/CloudCo ... mmands.cpp

The best idea is to copy/paste an existing one that works in a similar way (i.e. which at least relies on 2 entities).

(and don't forget to add it to the ccCommandLineParser::registerBuiltInCommands method:
https://github.com/CloudCompare/CloudCo ... r.cpp#L596)
Daniel, CloudCompare admin
johannes.schwank
Posts: 3
Joined: Fri Aug 28, 2020 1:16 pm

Re: "Interpolate from another entity" via command line

Post by johannes.schwank »

Thanks for your reply, daniel!

Next question that I have: is there a function that I can "just" call and give it the correct parameter (I assume there is), but where do I find it? Unfortunately, I am not a C++ expert, so, a little bit of help would save me a lot of time, I think.
daniel
Site Admin
Posts: 7712
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: "Interpolate from another entity" via command line

Post by daniel »

Daniel, CloudCompare admin
johannes.schwank
Posts: 3
Joined: Fri Aug 28, 2020 1:16 pm

Re: "Interpolate from another entity" via command line

Post by johannes.schwank »

daniel wrote: Mon Aug 31, 2020 8:17 pm I believe it should be this one: https://github.com/CloudCompare/CloudCo ... n.cpp#L317
I think you marked the wrong one, the one you meant is just below: https://github.com/CloudCompare/CloudCo ... n.cpp#L382. But nevertheless, I do not get it to work. Is there a possibility to set it on the todo list?
For now, I will have to click manually although that would be a nice simplification.

But big thanks anyway! Your tool is amazing!
Post Reply