Page 1 of 1

Constant screen size object

Posted: Tue Jan 15, 2019 9:04 pm
by SyWind
Hi
I need to keep one of my objects of constant size which does not change on zoom. Is there a way to do it in DG Kernel?
Thank you

Re: Constant screen size object

Posted: Thu Jan 17, 2019 8:47 pm
by Prashant Kande
Hello

I assume the object and the rest of the scene are 3D?

Do you need it to be aligned to the screen? I mean does it have to stay at fixed orientation relative to the imaginable plane of the screen or you need to be able to view it from all sides?

Regards

Re: Constant screen size object

Posted: Sun Jan 20, 2019 12:11 am
by SyWind
Hi Prashant
Thankyou for answering
I need it to be normal 3D object to view from any side like others, but it should scale up relatively to the rest when the user zooms out to keep it approximately, say 1/10 of the window height

Re: Constant screen size object

Posted: Tue Jan 22, 2019 10:52 pm
by Prashant Kande
For normal 3D the only option is to resize the object in your code.

Use IView_DG.GetPixelSize() http://www.dynoinsight.com/Help/V6_0/In ... tPixelSize to map screen size to 3D geometric size.

I would do it in mouse up handler for performance. it would be jerky to do it on every mouse move event. There is a possibility we could smooth it out on our side. Get in touch if it is critical

Cheers

Re: Constant screen size object

Posted: Thu Jan 24, 2019 5:31 am
by SyWind
Thank you!
I will get going with that