![]() |
|
Point element - Printable Version +- AB4D Forum (https://forum.ab4d.com) +-- Forum: Products Forums (https://forum.ab4d.com/forumdisplay.php?fid=4) +--- Forum: Ab3d.PowerToys (https://forum.ab4d.com/forumdisplay.php?fid=9) +--- Thread: Point element (/showthread.php?tid=4156) |
Point element - Radu Iordanescu - 12-03-2019 Hello, Is there a simple point element? (Or a workaround) It should have a position, a colour and a size, but the size should remain constant while zooming. And it should require the minimum amount of computer resources if possible. Thanks, RE: Point element - abenedik - 12-04-2019 WPF 3D engine does not support 3D pixels. You could "fake" it with using a 3D plane (PlaneVisual3D) that would be always oriented to face the camera (PlaneVisual3D has a AlignWithCamera method) and adjust its size when the camera changes (to get the desired 3D size you can use the Ab3d.Utilities.CameraUtils.GetPerspectiveWorldSize method). But this will work for showing only a limited number of pixels because the performance will not be good. If you want to show many 3D points then you should use Ab3d.DXEngine (https://www.ab4d.com/DXEngine.aspx). It supports hardware rendering of pixels and with using a decent graphics card it can render hundreds of millions of pixels. See the samples project that comes with Ab3d.DXEngine library. Here you can see two screenshots: https://www.ab4d.com/images/DXEngineGallery/DirectX-100M-pixels-in-DXEngine.png https://www.ab4d.com/images/DXEngineGallery/pixel-rendering-options.png RE: Point element - Radu Iordanescu - 12-10-2019 Thanks, This is really helpful. But, can you elaborate a little more on how to get a 3D object to be of constant size? RE: Point element - abenedik - 12-30-2019 If you will search for the "GetPerspectiveWorldSize" in the Ab3d.PowerToys samples project you will find that this method is used in the "Use Cases / Billboards sample" - see the code comments in the Camera1OnCameraChanged method. |