CloudCompare is displayed incorrectly.

Feel free to ask any question here
suyufeng
Posts: 47
Joined: Wed May 26, 2021 7:04 am

CloudCompare is displayed incorrectly.

Post by suyufeng »

hi!
In the CloudCompare code, some functions simply "return" and do not execute subsequent code.

For example, a piece of code in this picture.

I wonder if the statement after this'return' will still be executed? Or under what conditions they'll execute!
When I block them, there is no effect on my compiled cloudcompare!

I'm guessing this might be a later change that you made to stop executing subsequent code.

Thank you.
Attachments
Screenshot from 2021-05-26 15-02-25.png
Screenshot from 2021-05-26 15-02-25.png (57.59 KiB) Viewed 5554 times
WargodHernandez
Posts: 187
Joined: Tue Mar 05, 2019 3:59 pm

Re: CloudCompare is displayed incorrectly.

Post by WargodHernandez »

No the code after a return statement will not execute if the return is.

This function is meant to echo or pass along a mouse wheel rotate event when there are more then one 3d windows and the camera link option is enabled.
Camera link will move all 3d windows at the same time while navigating.
suyufeng
Posts: 47
Joined: Wed May 26, 2021 7:04 am

Re: CloudCompare is displayed incorrectly.

Post by suyufeng »

thank you!
I guess I know what it does.
I want to know when the statement following'return' is executed in CloudCompare.
daniel
Site Admin
Posts: 7711
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: CloudCompare is displayed incorrectly.

Post by daniel »

You need two 3D views AND to enable the 'Display > Camera link' option.
Daniel, CloudCompare admin
suyufeng
Posts: 47
Joined: Wed May 26, 2021 7:04 am

Re: CloudCompare is displayed incorrectly.

Post by suyufeng »

think you!!!
This solves my question, and I'd like to ask another question.
I'm in the middle of the secondary development of CloudCompare, and my current job is to constantly change the position of the camera to achieve the effect of dynamically displaying point clouds, just like your plug-in "Animation", I haven't been involved with C++ for a long time. Your code is a bit difficult to understand. Is there anything you can teach me?
daniel
Site Admin
Posts: 7711
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: CloudCompare is displayed incorrectly.

Post by daniel »

Well, CloudCompare is a complicated software... But the code is pretty standard C++. I guess at best we can answer questions :D
Daniel, CloudCompare admin
suyufeng
Posts: 47
Joined: Wed May 26, 2021 7:04 am

Re: CloudCompare is displayed incorrectly.

Post by suyufeng »

Ha ha ha ha!
There are so many questions to ask you.
Thank you for taking the time to respond to my post.

ccGLWindow* win = getActiveGLWindow();

You use this statement a lot, and I guess it's creating a form.But it doesn't feel like it's。

Can you give me an answer?
suyufeng
Posts: 47
Joined: Wed May 26, 2021 7:04 am

Re: CloudCompare is displayed incorrectly.

Post by suyufeng »

Oh! It's Friday. It's the weekend off again!
Take advantage of this time to ask a few more questions, hahaha!

My idea was to have the camera show the point cloud at my fixed position, and after a delay, show the point cloud at the next fixed point, but it won't, it will show the point cloud after the delay and do nothing before.
Could you give me some pointers?
daniel
Site Admin
Posts: 7711
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: CloudCompare is displayed incorrectly.

Post by daniel »

1) getActiveGLWindow simply returns a pointer to the active 3D view. This is the currently displayed/selected 3D view (as you can have several ones at the same time in CC)

2) Not sure to understand what you are trying to do (and how you do it) sorry. Maybe you should share some code?
Daniel, CloudCompare admin
suyufeng
Posts: 47
Joined: Wed May 26, 2021 7:04 am

Re: CloudCompare is displayed incorrectly.

Post by suyufeng »

I'm so sorry.
I can't share the code because of corporate confidentiality.
Please forgive me.
I mean I wanted to make the preview function of your qAnimation plug-in, I wanted to make it dynamic by constantly setting the camera position, which I did in pcl by constantly setting the camera position via PCLVisualizer. Now I want to implement it in cc, not as a plug-in.

Do you have anything to suggest? I know the setcamerapos function, but after I set the position, it took a while to set the other position, and it didn't do the trick I wanted.
Locked