加入5套spine官方运行时

This commit is contained in:
tianmo
2026-09-07 21:40:29 +08:00
parent 98e51a259e
commit 6837ecada9
935 changed files with 204665 additions and 8 deletions
@@ -0,0 +1,112 @@
/******************************************************************************
* Spine Runtimes License Agreement
* Last updated April 5, 2025. Replaces all prior versions.
*
* Copyright (c) 2013-2025, Esoteric Software LLC
*
* Integration of the Spine Runtimes into software or otherwise creating
* derivative works of the Spine Runtimes is permitted under the terms and
* conditions of Section 2 of the Spine Editor License Agreement:
* http://esotericsoftware.com/spine-editor-license
*
* Otherwise, it is permitted to integrate the Spine Runtimes into software
* or otherwise create derivative works of the Spine Runtimes (collectively,
* "Products"), provided that each user of the Products must obtain their own
* Spine Editor license and redistribution of the Products in any form must
* include this license and copyright notice.
*
* THE SPINE RUNTIMES ARE PROVIDED BY ESOTERIC SOFTWARE LLC "AS IS" AND ANY
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL ESOTERIC SOFTWARE LLC BE LIABLE FOR ANY
* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES,
* BUSINESS INTERRUPTION, OR LOSS OF USE, DATA, OR PROFITS) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THE SPINE RUNTIMES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*****************************************************************************/
#ifndef Spine_SliderData_h
#define Spine_SliderData_h
#include <spine/ConstraintData.h>
#include <spine/PosedData.h>
#include <spine/SliderPose.h>
#include <spine/SpineString.h>
namespace spine {
class Animation;
class BoneData;
class FromProperty;
class Slider;
class Skeleton;
/// Stores the setup pose for a Slider
class SP_API SliderData : public ConstraintDataGeneric<Slider, SliderPose> {
friend class SkeletonBinary;
friend class SkeletonData;
friend class SkeletonJson;
friend class Slider;
friend class SliderMixTimeline;
friend class SliderTimeline;
RTTI_DECL
public:
explicit SliderData(const String &name);
~SliderData();
/// Creates a slider instance.
virtual Constraint &create(Skeleton &skeleton) override;
/// The animation the slider will apply.
Animation &getAnimation();
void setAnimation(Animation &animation);
/// When true, the animation is applied by adding it to the current pose rather than overwriting it.
bool getAdditive();
void setAdditive(bool additive);
/// When true, the animation repeats after its duration, otherwise the last frame is used.
bool getLoop();
void setLoop(bool loop);
/// When set, the bone's transform property is used to set the slider's SliderPose::getTime().
BoneData *getBone();
void setBone(BoneData *bone);
/// When a bone is set, the specified transform property is used to set the slider's SliderPose::getTime().
FromProperty *getProperty();
void setProperty(FromProperty *property);
/// When a bone is set, this is the scale of the property value in relation to the slider time.
float getScale();
void setScale(float scale);
/// When a bone is set, the offset is added to the property.
float getOffset();
void setOffset(float offset);
/// When a bone is set, the maximum slider time for the bone property range, or 0 if nonessential data was not exported.
float getMax();
void setMax(float max);
/// When true and a bone is set, the bone's local transform property is read instead of its world transform.
bool getLocal();
void setLocal(bool local);
private:
Animation *_animation;
bool _additive;
bool _loop;
BoneData *_bone;
FromProperty *_property;
float _offset;
float _scale;
float _max;
bool _local;
};
}
#endif /* Spine_SliderData_h */