Then download and unzip libQGLViewer-2.6.4.zip.Depending on your environment:
QGLViewer/QGLViewer.proproject file and "build all".
cd \path\to\libQGLViewer-2.6.4\QGLViewer qmake mingw32-make
QGLViewer/QGLViewer.proand build the solution*.
Then copy the generated
QGLViewer2d.dll to a system
shared directory such as
C:\Windows\System32. An alternative is to copy the
dll in every executable's directory.
See the compilation with libQGLViewer page for details on examples' compilation.
.vcprojfile by typing
qmake -t vclib QGLViewer.pro -spec win32-msvc2010(adapt to your configuration) in a Qt command prompt window.
LNK4068 /MACHINE warning message can be fixed by editing Project - Properties of QGLViewer - Configuration properties - Link editor - Advanced - Target Computer.
.dspgenerated file, and select Release as the Build/Active Configuration.
Display Widgetstab to add it to your interface:
When added to your user interface, the widget displays the standard spiral, which can be manipulated when you test your interface. All the viewers' signals and slots are available and can be connected to the rest of your interface.
To compile the plugin, open the
designerPlugin.pro file to create your workspace.
Install the resulting plugin library (
C:\Program Files\QtSoftware\Qt VS Integration\plugins to use it with the Visual Studio
QGLViewer2.dll. Note that you also have to install
C:\Windows\System32(as described above). Copying this file to
$QTDir\binsometimes also seems necessary.
To create your own designer plugin for your derived QGLViewer class, start from this code and change a few lines as explained in the source.See the interface example for an illustration of a user interface that includes a QGLViewer.
Please let me know if you encounter installation problems.
Last modified on Tuesday, September 27, 2016.