mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-13 10:38:46 +08:00
[cpp] Removed // Empty
This commit is contained in:
parent
5af3d93403
commit
4234b17ffa
@ -10,7 +10,9 @@
|
||||
namespace Spine {
|
||||
class Color {
|
||||
public:
|
||||
Color() : _r(0), _g(0), _b(0), _a(0) {}
|
||||
Color() : _r(0), _g(0), _b(0), _a(0) {
|
||||
}
|
||||
|
||||
Color(float r, float g, float b, float a) : _r(r), _g(g), _b(b), _a(a) {
|
||||
clamp();
|
||||
}
|
||||
|
||||
@ -47,7 +47,6 @@ namespace Spine {
|
||||
|
||||
public:
|
||||
explicit Iterator(Entry* entry = NULL) : _entry(entry) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
Iterator& operator++() {
|
||||
@ -79,7 +78,6 @@ namespace Spine {
|
||||
_head(NULL),
|
||||
_hashFunction(),
|
||||
_size(0) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
~HashMap() {
|
||||
|
||||
@ -41,7 +41,6 @@ namespace Spine {
|
||||
class Pool : public SpineObject {
|
||||
public:
|
||||
Pool() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
~Pool() {
|
||||
|
||||
@ -35,6 +35,7 @@
|
||||
#include <spine/MathUtil.h>
|
||||
#include <spine/SpineObject.h>
|
||||
#include <spine/String.h>
|
||||
#include <spine/Color.h>
|
||||
|
||||
#include <limits> // std::numeric_limits
|
||||
|
||||
@ -154,14 +155,7 @@ namespace Spine {
|
||||
Vector<TransformConstraint*>& getTransformConstraints();
|
||||
|
||||
Skin* getSkin();
|
||||
float getR();
|
||||
void setR(float inValue);
|
||||
float getG();
|
||||
void setG(float inValue);
|
||||
float getB();
|
||||
void setB(float inValue);
|
||||
float getA();
|
||||
void setA(float inValue);
|
||||
Color& getColor();
|
||||
float getTime();
|
||||
void setTime(float inValue);
|
||||
float getX();
|
||||
@ -184,7 +178,7 @@ namespace Spine {
|
||||
Vector<Updatable*> _updateCache;
|
||||
Vector<Bone*> _updateCacheReset;
|
||||
Skin* _skin;
|
||||
float _r, _g, _b, _a;
|
||||
Color _color;
|
||||
float _time;
|
||||
bool _flipX, _flipY;
|
||||
float _x, _y;
|
||||
|
||||
@ -44,7 +44,6 @@ namespace Spine {
|
||||
class Vector : public SpineObject {
|
||||
public:
|
||||
Vector() : _size(0), _capacity(0), _buffer(NULL) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
Vector(const Vector& inVector) : _size(inVector._size), _capacity(inVector._capacity), _buffer(NULL) {
|
||||
|
||||
@ -48,11 +48,9 @@
|
||||
|
||||
namespace Spine {
|
||||
void dummyOnAnimationEventFunc(AnimationState* state, EventType type, TrackEntry* entry, Event* event = NULL) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
TrackEntry::TrackEntry() : _animation(NULL), _next(NULL), _mixingFrom(NULL), _trackIndex(0), _loop(false), _eventThreshold(0), _attachmentThreshold(0), _drawOrderThreshold(0), _animationStart(0), _animationEnd(0), _animationLast(0), _nextAnimationLast(0), _delay(0), _trackTime(0), _trackLast(0), _nextTrackLast(0), _trackEnd(0), _timeScale(1.0f), _alpha(0), _mixTime(0), _mixDuration(0), _interruptAlpha(0), _totalAlpha(0), _onAnimationEventFunc(dummyOnAnimationEventFunc) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
int TrackEntry::getTrackIndex() { return _trackIndex; }
|
||||
@ -210,7 +208,6 @@ namespace Spine {
|
||||
_type(eventType),
|
||||
_entry(trackEntry),
|
||||
_event(event) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
EventQueue* EventQueue::newEventQueue(AnimationState& state, Pool<TrackEntry>& trackEntryPool) {
|
||||
@ -222,7 +219,6 @@ namespace Spine {
|
||||
}
|
||||
|
||||
EventQueue::EventQueue(AnimationState& state, Pool<TrackEntry>& trackEntryPool) : _state(state), _trackEntryPool(trackEntryPool), _drainDisabled(false) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
EventQueue::~EventQueue() {
|
||||
@ -310,7 +306,6 @@ namespace Spine {
|
||||
_onAnimationEventFunc(dummyOnAnimationEventFunc),
|
||||
_timeScale(1),
|
||||
_rendererObject(NULL){
|
||||
// Empty
|
||||
}
|
||||
|
||||
AnimationState::~AnimationState() {
|
||||
|
||||
@ -35,7 +35,6 @@
|
||||
|
||||
namespace Spine {
|
||||
AnimationStateData::AnimationStateData(SkeletonData* skeletonData) : _skeletonData(skeletonData), _defaultMix(0) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
void AnimationStateData::setMix(const String& fromName, const String& toName, float duration) {
|
||||
@ -83,7 +82,6 @@ namespace Spine {
|
||||
}
|
||||
|
||||
AnimationStateData::AnimationPair::AnimationPair(Animation* a1, Animation* a2) : _a1(a1), _a2(a2) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
bool AnimationStateData::AnimationPair::operator==(const AnimationPair &other) const {
|
||||
|
||||
@ -44,7 +44,6 @@ namespace Spine {
|
||||
RTTI_IMPL(AtlasAttachmentLoader, AttachmentLoader);
|
||||
|
||||
AtlasAttachmentLoader::AtlasAttachmentLoader(Atlas* atlas) : AttachmentLoader(), _atlas(atlas) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
RegionAttachment* AtlasAttachmentLoader::newRegionAttachment(Skin& skin, const String& name, const String& path) {
|
||||
|
||||
@ -42,10 +42,8 @@ namespace Spine {
|
||||
RTTI_IMPL_NOPARENT(AttachmentLoader);
|
||||
|
||||
AttachmentLoader::AttachmentLoader() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
AttachmentLoader::~AttachmentLoader() {
|
||||
// Empty
|
||||
}
|
||||
}
|
||||
|
||||
@ -34,6 +34,5 @@ namespace Spine {
|
||||
RTTI_IMPL(BoundingBoxAttachment, VertexAttachment);
|
||||
|
||||
BoundingBoxAttachment::BoundingBoxAttachment(const String& name) : VertexAttachment(name) {
|
||||
// Empty
|
||||
}
|
||||
}
|
||||
|
||||
@ -36,7 +36,6 @@ namespace Spine {
|
||||
RTTI_IMPL(ClippingAttachment, VertexAttachment);
|
||||
|
||||
ClippingAttachment::ClippingAttachment(const String& name) : VertexAttachment(name), _endSlot(NULL) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
SlotData* ClippingAttachment::getEndSlot() {
|
||||
|
||||
@ -34,10 +34,8 @@ namespace Spine {
|
||||
RTTI_IMPL(Constraint, Updatable);
|
||||
|
||||
Constraint::Constraint() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
Constraint::~Constraint() {
|
||||
// Empty
|
||||
}
|
||||
}
|
||||
|
||||
@ -39,7 +39,6 @@ namespace Spine {
|
||||
_intValue(0),
|
||||
_floatValue(0),
|
||||
_stringValue() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
const EventData& Event::getData() {
|
||||
|
||||
@ -51,15 +51,12 @@ namespace Spine {
|
||||
}
|
||||
|
||||
SpineExtension::~SpineExtension() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
SpineExtension::SpineExtension() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
DefaultSpineExtension::~DefaultSpineExtension() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
void* DefaultSpineExtension::_alloc(size_t size, const char* file, int line) {
|
||||
@ -112,6 +109,5 @@ namespace Spine {
|
||||
}
|
||||
|
||||
DefaultSpineExtension::DefaultSpineExtension() : SpineExtension() {
|
||||
// Empty
|
||||
}
|
||||
}
|
||||
|
||||
@ -39,7 +39,6 @@ namespace Spine {
|
||||
_target(NULL),
|
||||
_bendDirection(1),
|
||||
_mix(1) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
const String& IkConstraintData::getName() {
|
||||
|
||||
@ -38,6 +38,5 @@ namespace Spine {
|
||||
_skin(skin),
|
||||
_slotIndex(slotIndex),
|
||||
_parent(parent) {
|
||||
// Empty
|
||||
}
|
||||
}
|
||||
|
||||
@ -54,7 +54,6 @@
|
||||
_hullLength(0),
|
||||
_inheritDeform(false),
|
||||
_regionRotate(false) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
void MeshAttachment::updateUVs() {
|
||||
|
||||
@ -34,7 +34,6 @@ namespace Spine {
|
||||
RTTI_IMPL(PathAttachment, VertexAttachment);
|
||||
|
||||
PathAttachment::PathAttachment(const String& name) : VertexAttachment(name), _closed(false), _constantSpeed(false) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
Vector<float>& PathAttachment::getLengths() {
|
||||
|
||||
@ -53,7 +53,6 @@ namespace Spine {
|
||||
}
|
||||
|
||||
PathConstraintPositionTimeline::~PathConstraintPositionTimeline() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
void PathConstraintPositionTimeline::apply(Skeleton& skeleton, float lastTime, float time, Vector<Event*>* pEvents, float alpha, MixPose pose, MixDirection direction) {
|
||||
|
||||
@ -44,7 +44,6 @@ namespace Spine {
|
||||
RTTI_IMPL(PathConstraintSpacingTimeline, PathConstraintPositionTimeline);
|
||||
|
||||
PathConstraintSpacingTimeline::PathConstraintSpacingTimeline(int frameCount) : PathConstraintPositionTimeline(frameCount) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
void PathConstraintSpacingTimeline::apply(Skeleton& skeleton, float lastTime, float time, Vector<Event*>* pEvents, float alpha, MixPose pose, MixDirection direction) {
|
||||
|
||||
@ -38,7 +38,6 @@ namespace Spine {
|
||||
RTTI_IMPL(PointAttachment, Attachment);
|
||||
|
||||
PointAttachment::PointAttachment(const String& name) : Attachment(name), _x(0), _y(0), _rotation(0) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
void PointAttachment::computeWorldPosition(Bone& bone, float& ox, float& oy) {
|
||||
|
||||
@ -33,11 +33,9 @@
|
||||
|
||||
namespace Spine {
|
||||
RTTI::RTTI(const std::string& className) : _className(className), _pBaseRTTI(NULL) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
RTTI::RTTI(const std::string& className, const RTTI& baseRTTI) : _className(className), _pBaseRTTI(&baseRTTI) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
const std::string& RTTI::getClassName() const {
|
||||
|
||||
@ -44,7 +44,6 @@ namespace Spine {
|
||||
RTTI_IMPL(ScaleTimeline, TranslateTimeline);
|
||||
|
||||
ScaleTimeline::ScaleTimeline(int frameCount) : TranslateTimeline(frameCount) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
void ScaleTimeline::apply(Skeleton& skeleton, float lastTime, float time, Vector<Event*>* pEvents, float alpha, MixPose pose, MixDirection direction) {
|
||||
|
||||
@ -44,7 +44,6 @@ namespace Spine {
|
||||
RTTI_IMPL(ShearTimeline, TranslateTimeline);
|
||||
|
||||
ShearTimeline::ShearTimeline(int frameCount) : TranslateTimeline(frameCount) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
void ShearTimeline::apply(Skeleton& skeleton, float lastTime, float time, Vector<Event*>* pEvents, float alpha, MixPose pose, MixDirection direction) {
|
||||
|
||||
@ -56,10 +56,7 @@ namespace Spine {
|
||||
Skeleton::Skeleton(SkeletonData* skeletonData) :
|
||||
_data(skeletonData),
|
||||
_skin(NULL),
|
||||
_r(1),
|
||||
_g(1),
|
||||
_b(1),
|
||||
_a(1),
|
||||
_color(1, 1, 1, 1),
|
||||
_time(0),
|
||||
_flipX(false),
|
||||
_flipY(false),
|
||||
@ -488,37 +485,9 @@ namespace Spine {
|
||||
return _skin;
|
||||
}
|
||||
|
||||
float Skeleton::getR() {
|
||||
return _r;
|
||||
}
|
||||
|
||||
void Skeleton::setR(float inValue) {
|
||||
_r = inValue;
|
||||
}
|
||||
|
||||
float Skeleton::getG() {
|
||||
return _g;
|
||||
}
|
||||
|
||||
void Skeleton::setG(float inValue) {
|
||||
_g = inValue;
|
||||
}
|
||||
|
||||
float Skeleton::getB() {
|
||||
return _b;
|
||||
}
|
||||
|
||||
void Skeleton::setB(float inValue) {
|
||||
_b = inValue;
|
||||
}
|
||||
|
||||
float Skeleton::getA() {
|
||||
return _a;
|
||||
}
|
||||
|
||||
void Skeleton::setA(float inValue) {
|
||||
_a = inValue;
|
||||
}
|
||||
Color& Skeleton::getColor() {
|
||||
return _color;
|
||||
}
|
||||
|
||||
float Skeleton::getTime() {
|
||||
return _time;
|
||||
|
||||
@ -38,7 +38,6 @@
|
||||
|
||||
namespace Spine {
|
||||
SkeletonBounds::SkeletonBounds() : _minX(0), _minY(0), _maxX(0), _maxY(0) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
void SkeletonBounds::update(Skeleton& skeleton, bool updateAabb) {
|
||||
|
||||
@ -53,7 +53,6 @@ namespace Spine {
|
||||
_hash(),
|
||||
_fps(0),
|
||||
_imagesPath() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
SkeletonData::~SkeletonData() {
|
||||
|
||||
@ -41,7 +41,6 @@ namespace Spine {
|
||||
Skin::AttachmentKey::AttachmentKey(int slotIndex, const String& name) :
|
||||
_slotIndex(slotIndex),
|
||||
_name(name) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
bool Skin::AttachmentKey::operator==(const AttachmentKey &other) const {
|
||||
|
||||
@ -46,6 +46,5 @@ namespace Spine {
|
||||
}
|
||||
|
||||
SpineObject::~SpineObject() {
|
||||
// Empty
|
||||
}
|
||||
}
|
||||
@ -32,10 +32,8 @@
|
||||
|
||||
namespace Spine {
|
||||
TextureLoader::TextureLoader() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
TextureLoader::~TextureLoader() {
|
||||
// Empty
|
||||
}
|
||||
}
|
||||
|
||||
@ -37,10 +37,8 @@ namespace Spine {
|
||||
RTTI_IMPL_NOPARENT(Timeline);
|
||||
|
||||
Timeline::Timeline() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
Timeline::~Timeline() {
|
||||
// Empty
|
||||
}
|
||||
}
|
||||
|
||||
@ -56,7 +56,6 @@ namespace Spine {
|
||||
}
|
||||
|
||||
TranslateTimeline::~TranslateTimeline() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
void TranslateTimeline::apply(Skeleton& skeleton, float lastTime, float time, Vector<Event*>* pEvents, float alpha, MixPose pose, MixDirection direction) {
|
||||
|
||||
@ -34,10 +34,8 @@ namespace Spine {
|
||||
RTTI_IMPL_NOPARENT(Updatable);
|
||||
|
||||
Updatable::Updatable() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
Updatable::~Updatable() {
|
||||
// Empty
|
||||
}
|
||||
}
|
||||
|
||||
@ -39,11 +39,9 @@ namespace Spine {
|
||||
RTTI_IMPL(VertexAttachment, Attachment);
|
||||
|
||||
VertexAttachment::VertexAttachment(const String& name) : Attachment(name), _worldVerticesLength(0), _id(getNextID()) {
|
||||
// Empty
|
||||
}
|
||||
|
||||
VertexAttachment::~VertexAttachment() {
|
||||
// Empty
|
||||
}
|
||||
|
||||
void VertexAttachment::computeWorldVertices(Slot& slot, Vector<float>& worldVertices) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user