Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Integration 3D Interactive presentation widget problem
Forum Updated to NodeBB v4.3 + New Features

Integration 3D Interactive presentation widget problem

Scheduled Pinned Locked Moved Unsolved General and Desktop
2 Posts 1 Posters 384 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    Anes
    wrote on last edited by Anes
    #1

    Hello,
    I am working on software to develop control and data acquisition systems (SCADA) called WinCC OA.
    this latter does not give the possibility to import 3d objects and animated objects, but it does give the possibility to create API.

    0_1556095410382_Capture.PNG

    For my case it is an EWO (External Widget Object), you will find attached the template I generated, it is developed in C++ using the Qt platform.

    [0_1556095847641__TEMPLATE_.cxx](Uploading 100%)
    [0_1556095858235__TEMPLATE_.hxx](Uploading 100%)
    [0_1556095865858__TEMPLATE_.pro](Uploading 100%)
    [0_1556095874300_README](Uploading 100%)
    [0_1556095883126_VersInfo.rc](Uploading 100%)

    honestly to develop an interactive 3d simulator purely in Qt respecting the generated template I can't even get started.

    here is a video to give an idea about the 3d simulator I want to make
    https://www.youtube.com/watch?v=yu-M6Omk1ps

    I thought about developing the simulator using a 3d engine , I start to develop it using unity (3d metro station visualization where I control camera position from buttons, I can make on/off the elevator ...etc).

    I managed to do but my problem is the integration, how to integrate this simulator into WinCC OA, i.e. the presentation I made under unity will be a widget in the new software, and I can control elevator, escalators .. etc from this last software.

    Help please

    Best Regards

    Anes

    1 Reply Last reply
    0
    • A Offline
      A Offline
      Anes
      wrote on last edited by
      #2

      This is the header of the template

      #ifndef _TEMPLATE__H
      #define _TEMPLATE__H

      #include <BaseExternWidget.hxx>
      #include <QPen>
      #include <QBrush>

      //--------------------------------------------------------------------------------
      // this is the real widget (an ordinary Qt widget), which can also use Q_PROPERTY

      class MyWidget : public QWidget
      {
      Q_OBJECT

      // TODO example properties
      Q_PROPERTY( QStringList values READ getValues WRITE setValues DESIGNABLE false )
      Q_PROPERTY( QPen pen READ getPen WRITE setPen DESIGNABLE false )
      Q_PROPERTY( QBrush brush READ getBrush WRITE setBrush DESIGNABLE false )

      public:
      MyWidget(QWidget *parent);

      // TODO example of a string list property
      QStringList getValues() const { return values; }
      void setValues(const QStringList &list) { values = list; }
      
      // a QPen property used on a line drawn inside this widget
      const QPen &getPen() const { return pen; }
      void setPen(const QPen &p) { pen = p; update(); }
      
      // a QBrush property used as the background of this widget
      QBrush getBrush() const;
      void setBrush(const QBrush &brush);
      

      signals:
      // TODO example of a 2 signals this widget emits
      void clicked1();
      void clicked2();

      protected:
      virtual void paintEvent(QPaintEvent *event);

      private:
      // TODO example of a string list property
      QStringList values;
      QPen pen;
      };

      //--------------------------------------------------------------------------------
      // this is the EWO interface class

      class EWO_EXPORT TEMPLATE : public BaseExternWidget
      {
      Q_OBJECT

      public:
      TEMPLATE(QWidget *parent);

      virtual QWidget *widget() const;
      
      virtual QStringList signalList() const;
      
      virtual bool methodInterface(const QString &name, QVariant::Type &retVal,
                                   QList<QVariant::Type> &args) const;
      
      virtual QStringList methodList() const;
      

      public slots:
      virtual QVariant invokeMethod(const QString &name, QList<QVariant> &values, QString &error);

      private slots:
      // TODO the slots you need to redirect to the generic "signal" signal
      void clicked1();
      void clicked2();

      private:
      MyWidget *baseWidget;
      };

      #endif

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved