mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2025-12-21 01:36:02 +08:00
Merge branch '3.7' into 3.8-beta
This commit is contained in:
commit
3c83810c43
@ -129,6 +129,7 @@
|
|||||||
## C++
|
## C++
|
||||||
* ** Additions **
|
* ** Additions **
|
||||||
* Added C++ Spine runtime. See the [spine-cpp Runtime Guide](https://esotericsoftware.com/spine-cpp) for more information on spine-cpp.
|
* Added C++ Spine runtime. See the [spine-cpp Runtime Guide](https://esotericsoftware.com/spine-cpp) for more information on spine-cpp.
|
||||||
|
* Added parsing of non-essential data (fps, images path, audio path) to for `.json`/`.skel` parsers.
|
||||||
|
|
||||||
### Cocos2d-x
|
### Cocos2d-x
|
||||||
* Added ETC1 alpha support, thanks @halx99! Does not work when two color tint is enabled.
|
* Added ETC1 alpha support, thanks @halx99! Does not work when two color tint is enabled.
|
||||||
|
|||||||
@ -716,6 +716,7 @@
|
|||||||
"\"cocos2d/external/ObjectAL\"/**",
|
"\"cocos2d/external/ObjectAL\"/**",
|
||||||
);
|
);
|
||||||
INFOPLIST_FILE = "Resources-ios/Info.plist";
|
INFOPLIST_FILE = "Resources-ios/Info.plist";
|
||||||
|
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
|
||||||
LIBRARY_SEARCH_PATHS = "$(inherited)";
|
LIBRARY_SEARCH_PATHS = "$(inherited)";
|
||||||
OTHER_CFLAGS = "";
|
OTHER_CFLAGS = "";
|
||||||
OTHER_LDFLAGS = (
|
OTHER_LDFLAGS = (
|
||||||
@ -744,6 +745,7 @@
|
|||||||
"\"cocos2d/external/ObjectAL\"/**",
|
"\"cocos2d/external/ObjectAL\"/**",
|
||||||
);
|
);
|
||||||
INFOPLIST_FILE = "Resources-ios/Info.plist";
|
INFOPLIST_FILE = "Resources-ios/Info.plist";
|
||||||
|
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
|
||||||
LIBRARY_SEARCH_PATHS = "$(inherited)";
|
LIBRARY_SEARCH_PATHS = "$(inherited)";
|
||||||
OTHER_CFLAGS = "";
|
OTHER_CFLAGS = "";
|
||||||
OTHER_LDFLAGS = (
|
OTHER_LDFLAGS = (
|
||||||
|
|||||||
@ -150,6 +150,10 @@ public:
|
|||||||
|
|
||||||
void setImagesPath(const String &inValue);
|
void setImagesPath(const String &inValue);
|
||||||
|
|
||||||
|
const String &getAudioPath();
|
||||||
|
|
||||||
|
void setAudioPath(const String &inValue);
|
||||||
|
|
||||||
/// The dopesheet FPS in Spine. Available only when nonessential data was exported.
|
/// The dopesheet FPS in Spine. Available only when nonessential data was exported.
|
||||||
float getFps();
|
float getFps();
|
||||||
|
|
||||||
@ -173,6 +177,7 @@ private:
|
|||||||
// Nonessential.
|
// Nonessential.
|
||||||
float _fps;
|
float _fps;
|
||||||
String _imagesPath;
|
String _imagesPath;
|
||||||
|
String _audioPath;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -138,9 +138,9 @@ SkeletonData *SkeletonBinary::readSkeletonData(const unsigned char *binary, cons
|
|||||||
|
|
||||||
if (nonessential) {
|
if (nonessential) {
|
||||||
/* Skip images path, audio path & fps */
|
/* Skip images path, audio path & fps */
|
||||||
readFloat(input);
|
skeletonData->_fps = readFloat(input);
|
||||||
String(readString(input), true);
|
skeletonData->_imagesPath.own(readString(input));
|
||||||
String(readString(input), true);
|
skeletonData->_audioPath.own(readString(input));
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Bones. */
|
/* Bones. */
|
||||||
|
|||||||
@ -204,6 +204,15 @@ void SkeletonData::setImagesPath(const String &inValue) {
|
|||||||
_imagesPath = inValue;
|
_imagesPath = inValue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
const String &SkeletonData::getAudioPath() {
|
||||||
|
return _audioPath;
|
||||||
|
}
|
||||||
|
|
||||||
|
void SkeletonData::setAudioPath(const String &inValue) {
|
||||||
|
_audioPath = inValue;
|
||||||
|
}
|
||||||
|
|
||||||
float SkeletonData::getFps() {
|
float SkeletonData::getFps() {
|
||||||
return _fps;
|
return _fps;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -137,6 +137,9 @@ SkeletonData *SkeletonJson::readSkeletonData(const char *json) {
|
|||||||
skeletonData->_version = Json::getString(skeleton, "spine", 0);
|
skeletonData->_version = Json::getString(skeleton, "spine", 0);
|
||||||
skeletonData->_width = Json::getFloat(skeleton, "width", 0);
|
skeletonData->_width = Json::getFloat(skeleton, "width", 0);
|
||||||
skeletonData->_height = Json::getFloat(skeleton, "height", 0);
|
skeletonData->_height = Json::getFloat(skeleton, "height", 0);
|
||||||
|
skeletonData->_fps = Json::getFloat(skeleton, "fps", 30);
|
||||||
|
skeletonData->_audioPath = Json::getString(skeleton, "audio", 0);
|
||||||
|
skeletonData->_imagesPath = Json::getString(skeleton, "images", 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Bones. */
|
/* Bones. */
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user