mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-06 15:24:55 +08:00
Merge branch 'EsotericSoftware/3.6' into 3.6
This commit is contained in:
commit
20db47d4b7
@ -22,11 +22,11 @@ void RegisterMemoryLeakDetector()
|
||||
{
|
||||
// Register our malloc and free functions to track memory leaks
|
||||
#ifdef KANJI_MEMTRACE
|
||||
_setDebugMalloc(_kanjimalloc);
|
||||
_spSetDebugMalloc(_kanjimalloc);
|
||||
#endif
|
||||
_setMalloc(_kanjimalloc);
|
||||
_setRealloc(_kanjirealloc);
|
||||
_setFree(_kanjifree);
|
||||
_spSetMalloc(_kanjimalloc);
|
||||
_spSetRealloc(_kanjirealloc);
|
||||
_spSetFree(_kanjifree);
|
||||
}
|
||||
|
||||
int main(int argc, char* argv[])
|
||||
@ -74,6 +74,6 @@ extern "C" { // probably unnecessary
|
||||
}
|
||||
|
||||
char* _spUtil_readFile(const char* path, int* length) {
|
||||
return _readFile(path, length);
|
||||
return _spReadFile(path, length);
|
||||
}
|
||||
}
|
||||
|
||||
@ -30,7 +30,7 @@
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// Our memory system is thread-safe, but instead of linking massive libraries,
|
||||
// we attempt to use C++11 std::mutex.
|
||||
#ifdef USE_CPP11_MUTEX
|
||||
#ifdef USE_CPP11_MUTEX_DISABLED
|
||||
#include <mutex>
|
||||
typedef std::recursive_mutex KSysLock; // rentrant
|
||||
struct KAutoLock {
|
||||
@ -300,4 +300,4 @@ size_t KMemoryAllocated()
|
||||
size += info.size;
|
||||
}
|
||||
return size;
|
||||
}
|
||||
}
|
||||
|
||||
@ -44,13 +44,13 @@ The Spine SFML example works on Windows, Linux and Mac OS X.
|
||||
The entire example code is contained in [main.cpp](example/main.cpp#L61)
|
||||
|
||||
### Linux
|
||||
1. Install the SFML dependencies, e.g. on Ubuntu/Debian via `sudo apt-get install -y libpthread-stubs0-dev libgl1-mesa-dev libx11-dev libxrandr-dev libfreetype6-dev libglew1.5-dev libjpeg8-dev libsndfile1-dev libopenal-dev libudev-dev libxcb-image0-dev libjpeg-dev libflac-dev`
|
||||
1. Install the SFML dependencies, e.g. on Ubuntu/Debian via `sudo apt install libsfml-dev`
|
||||
2. Install CMake, e.g. on Ubuntu/Debian via `sudo apt-get install -y cmake`
|
||||
3. Download the Spine Runtimes repository using git (`git clone https://github.com/esotericsoftware/spine-runtimes`) or download it as a zip via the download button above.
|
||||
4. Open a terminal, and `cd` into the `spine-runtimes/spine-sfml` folder
|
||||
5. Type `mkdir build && cd build && cmake ../..` to generate Make files
|
||||
6. Type `make` to compile the example
|
||||
7. Run the example by `cd spine-sfml-example && ./spine-sfml-example`
|
||||
7. Run the example by `cd spine-sfml && ./spine-sfml-example`
|
||||
|
||||
### Mac OS X
|
||||
1. Install [Xcode](https://developer.apple.com/xcode/)
|
||||
|
||||
@ -457,7 +457,7 @@ namespace Spine.Unity {
|
||||
var skeleton = instruction.skeleton;
|
||||
var drawOrderItems = skeleton.drawOrder.Items;
|
||||
|
||||
Color32 color;
|
||||
Color32 color = default(Color32);
|
||||
float skeletonA = skeleton.a * 255, skeletonR = skeleton.r, skeletonG = skeleton.g, skeletonB = skeleton.b;
|
||||
Vector2 meshBoundsMin = this.meshBoundsMin, meshBoundsMax = this.meshBoundsMax;
|
||||
|
||||
@ -661,7 +661,7 @@ namespace Spine.Unity {
|
||||
}
|
||||
|
||||
// Populate Verts
|
||||
Color32 color;
|
||||
Color32 color = default(Color32);
|
||||
|
||||
int vertexIndex = 0;
|
||||
var tempVerts = this.tempVerts;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user