Skip to content

Simple example integrating OpenCASCADE into QML

License

Notifications You must be signed in to change notification settings

crud89/opencascade_qml

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Using OpenCascade in QtQuick 2

This project is a fork of the example project of Anton Shabalin, which was based on Guiseppe D'Angelos QQ2/OpenGL example and the official OCCT AndriodQt sample code.

Example Screenshot

Improvements

The fork improves the example regarding the following points:

  • Largely simplified codebase compared to the original version.
  • Switched implementation to use QQmlApplicationEngine and ApplicationWindow.
  • Support for recent versions of OpenCascade (7.3.0) and Qt (5.12).
  • Removed dependency on private headers (allows for dynamic linking).
  • Build tested in Visual Studio 2019 (vc150), 2017 (vc141) and Qt Creator (4.9.2).

Note that platforms other than Windows may require slight modifications, mainly replacing native calls to wglGetCurrentDC and wglGetCurrentContext and respective include of <windows.h> with appropriate APIs.

Removed from original example

I've removed all mouse interactivity, to keep the example simple. It should be pretty straightforward to wire up the mouse events to OCCT transforms. The AndroidQt sample provides a good starting point.

License

GNU Lesser General Public License 3.0

Releases

No releases published

Packages

No packages published

Languages

  • C++ 80.1%
  • QMake 16.3%
  • QML 3.6%