Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: SFML + QML integration  (Read 1221 times)

0 Members and 1 Guest are viewing this topic.

Oniks

  • Newbie
  • *
  • Posts: 1
    • View Profile
    • Email
SFML + QML integration
« on: November 15, 2018, 06:14:00 pm »
Can anyone provide a minimal example of the integration of SFML and Qt QML (I assume with http://doc.qt.io/qt-5/qquickitem.html#updatePaintNode)?

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11034
    • View Profile
    • development blog
    • Email
Re: SFML + QML integration
« Reply #1 on: November 15, 2018, 08:41:06 pm »
There's this one tutorial with QtWidget which I assume you're not looking for: https://github.com/SFML/SFML/wiki/Tutorial%3A-Integrating-SFML-into-Qt

Sygmei has done something with QML for their engine, might be interesting to look into.
https://github.com/Sygmei/ObEngine/blob/qt/src/Dev/Modes/Menu.cpp
https://github.com/Sygmei/ObEngine/tree/qt/extlibs/QtQuickSFML

Otherwise, I don't have enough insight into Qt to really help you further.
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: SFML + QML integration
« Reply #2 on: November 15, 2018, 10:23:38 pm »
QtQuick already has a lot of useful stuff built in: a scene graph (behind the scenes), shader effects, vector shapes, text, ... (and widgets of course). I'm not really sure what you're hoping to get by "integrating" SFML to it.

And even if something's missing from QtQuick, I'd already search within the variety of libraries built for it, rather than trying to port something that is clearly not made for it. For example, you can have a look at V-Play, which is a fully featured game framework built on top of QtQuick and QML.
Laurent Gomila - SFML developer