Learn what Felgo offers to help your business succeed. Start your free evaluation today! Felgo for Your Business

Qt Quick 3D - Robot Arm Example

// Copyright (C) 2022 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause

#ifndef ANIMATEDPARAM_H
#define ANIMATEDPARAM_H

#include <QProperty>
#include <QVariantAnimation>

class AnimatedParam : public QVariantAnimation
{
    Q_OBJECT
    Q_PROPERTY(int value READ value WRITE setValue NOTIFY valueChanged)

public:
    AnimatedParam(QObject *parent = nullptr);

    int value() const;
    void setValue(int newValue);

    bool isRunning() const;

signals:
    void valueChanged();

private:
    QProperty<bool> m_isRunning;
Qt_Technology_Partner_RGB_475 Qt_Service_Partner_RGB_475_padded