Page 1 of 1

Issue using multiple Annotation3D objects

Posted: Fri Nov 10, 2023 1:13 pm
by mobusek
Hello, I am trying to place two Annotation3D objects on a View3D to mark multiple points on the chart.

I was expecting this to work fine because the View3D.Annotations collection is a list, so it seems like I should be able to use multiple annotations at once.

After some testing, it seems only one annotation can show up at a time. If I add two annotations, and set only the second one to be visible, then it shows up correctly. However if I add two annotations and set both to be visible, only the first annotation shows up. I double checked that both annotations still had Visible set to true, but I could never get both to show up at once.

Is this the expected behavior? I wasn't sure if I misunderstood how the feature worked, or if perhaps there's something not working correctly.

Thanks!

Re: Issue using multiple Annotation3D objects

Posted: Fri Nov 10, 2023 2:01 pm
by ArctionKestutis
You need to be more specific, because to my knowledge there are no problems with multiple Annotation3D.

Here simple test, run our Demo, open any 3D example, open Properties Editor and then open View3D.Annotations collection. In the dialog you can add 5, 10 or more Annotations (click OK to close dialog). All Annotation will appear on Chart, but (unless to change properties) they will be overlapping. Just drag Anotation3D one by one to aside.

We need your project in order to investigate what is the problem. You can share here, or send directly to Support email.

One thing you can check is 'object non-sharing' requirement (see User Manual chapter 29.1). If you share some Annotation's property as object, they you may have some unexpected results.

Re: Issue using multiple Annotation3D objects

Posted: Fri Nov 10, 2023 3:22 pm
by mobusek
I tried that out and realized the problem seems specific to the Target Crosshair feature of the annotation. In our project, I was only showing the crosshair, not the arrow or text bubble part of the annotation. So at first it seemed like the whole annotation wasn't showing up.

I attached the source files from a test project that shows the problem I'm seeing. We're using LightningChart version 10.3.2.4002. It adds two annotations that both have ShowTargetCrosshair set to TargetCrossHair.On. Both annotation's arrows and text bubbles show up on the chart, but only the first annotation's crosshair shows up.

Re: Issue using multiple Annotation3D objects

Posted: Tue Nov 14, 2023 8:00 am
by ArctionKestutis
Thank you for the project/details. Yes, indeed TargetCrossHair of Annotation3D is not shown if there are multiple Annotations. Probably reason that initially feature was intended only active Annotation. Which could just one at the time.
Probably it could be fixed in the future, but for now (in such use case) you probably should use PoinlineSeries3D for TargetCrossHair.

Re: Issue using multiple Annotation3D objects

Posted: Tue Nov 14, 2023 3:08 pm
by mobusek
Understood. I was able to use PointLineSeries3D to achieve something that works like a target crosshair. Thank you for the suggestion and all the help!