How to Display Coordinate System

Hello,

I want to display coordinate system on the view as in attached photo(Only main axes X, Y, Z). Do you know how to do this?

Thanks in advance,

Attachments: 
Kirill Gavrilov's picture

You may try V3d_View::GraduatedTrihedronDisplay(), V3d_Viewer::ActivateGrid() or implement a custom presentation displaying coordinate system in desired way.

Omer K's picture

Thank you Kirill,

Can you help how can I implement a custom presentation(if you have a sample code I would very much appreciate it), I want a similar coordinate system to graduated trihedron. There will be no grids, X, Y, Z Lines will go from origin point and X,Y,Z Lines will stay stable(it should not move, graduated trihedron moves while shape moves). Only their length will change dynamically based on positions of AIS_Shapes. Additionally, I want to show fixed distances on X,Y,Z lines( I guess it is similar to TickmarksLength of Axis Aspect class). In the end I want a similar coordinate system to the one in the attached photo.

Even if you dont have a complete answer, any information would be great (Like how to create tickmarks, how to create text on an axis, how to create line with fixed length(GC_makeline creates an infinite line)). Thanks in advance,

Attachments: 
Manjunath Gowda's picture

Hello,
I am using Open cascade in Qt Qml for drawing lines. I have activated the grid and also I am able to do drawing.

But I need to display the x y co ordinates values for the grid at the corner of the window as per the attached image.
When I zoom in / out the co ordinates values should change based on zoom factor.

Could any one please help me to display the co ordinates values for the grid at the corner of the window ?

Attachments: