overte/libraries/script-engine/src/SpatialEvent.h
2023-05-19 00:17:34 +02:00

44 lines
1,008 B
C++

//
// SpatialEvent.h
// script-engine/src
//
// Created by Stephen Birarda on 2014-10-27.
// Copyright 2014 High Fidelity, Inc.
//
// Distributed under the Apache License, Version 2.0.
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
/// @addtogroup ScriptEngine
/// @{
#ifndef hifi_SpatialEvent_h
#define hifi_SpatialEvent_h
#include <glm/glm.hpp>
#include <glm/gtc/quaternion.hpp>
#include "ScriptValue.h"
class ScriptEngine;
/// [unused] Represents a spatial event to the scripting engine
class SpatialEvent {
public:
SpatialEvent();
SpatialEvent(const SpatialEvent& other);
static ScriptValue toScriptValue(ScriptEngine* engine, const SpatialEvent& event);
static bool fromScriptValue(const ScriptValue& object, SpatialEvent& event);
glm::vec3 locTranslation;
glm::quat locRotation;
glm::vec3 absTranslation;
glm::quat absRotation;
};
Q_DECLARE_METATYPE(SpatialEvent)
#endif // hifi_SpatialEvent_h
/// @}