GillesDebunne / libQGLViewer

libQGLViewer is an open source C++ library based on Qt that eases the creation of OpenGL 3D viewers.
Other
241 stars 94 forks source link

Mixing 2D and 3D viewer? #68

Closed fghoussen closed 1 year ago

fghoussen commented 1 year ago

Does libQGLViewer allow to mix 2D and 3D viewer?

For instance, it is possible to display a 2D image (jpg) in 1 of the 4 quadrant of the multi viewer example: https://libqglviewer.com/examples/multiView.html? If so, is there already an example? If not, are there possible workaround?

Franck

Note: this is more a question than an issue but not sure where to ask it.

kerautret commented 1 year ago

Hi @fghoussen, Not sure that you question is directly related to QglViewer itself, but perhaps it can help you can have a look to the tools sliceViewer of DGtalTools projet potentially you can, you can find some examples with the source code. Here is an preview: 8678ca02-6add-11e5-9d83-fbcf3608612f If your question is more related to display images in the viewer itself, you have here also an exemple of Image display inside the 3D with the tools 3dImageViewer Hope it helps you ;)

fghoussen commented 1 year ago

Indeed, didn't know https://github.com/DGtal-team/DGtalTools: I'll have a look! Thanks :)

GillesDebunne commented 1 year ago

You can layout 2D and 3D widgets with Qt. If the 2D view is a 'flat' view of your 3d scene, consider using an orthographic camera.