diff --git a/.editorconfig b/.editorconfig
index 8b68d775..f5134ac2 100644
--- a/.editorconfig
+++ b/.editorconfig
@@ -25,3 +25,6 @@ charset = unset
[*.md]
trim_trailing_whitespace = false
+
+[*.{cpp,hpp,h}]
+charset = utf-8-bom
diff --git a/.gitignore b/.gitignore
index 2958703e..f0c2ad0a 100644
--- a/.gitignore
+++ b/.gitignore
@@ -8,6 +8,8 @@
# Sample build directories
/Samples/**/build/
+# HarmonyOS files
+Samples/OpenGL/Demo/proj.harmonyos.cmake/Full/entry/src/main/resources/rawfile/
# Sample third party files
/Samples/**/thirdParty/*
!/Samples/**/thirdParty/scripts/*
diff --git a/CHANGELOG.md b/CHANGELOG.md
index e82bc5fb..a0d5e426 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -5,6 +5,59 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
+## [5-r.2] - 2024-12-19
+
+### Added
+
+* Add Vulkan support in Ubuntu 22.04 and AlmaLinux 9.
+* Add a function to notify when motion playback starts.
+* Add shader setup classes for D3D9, D3D11, OpenGL, Vulkan.
+* Add the sample for OpenGL API in HarmonyOS.
+
+### Changed
+
+* Change to overwrite motion fade by the value specified in .model3.json on Framework.
+* Change to use multi-buffering in Vulkan.
+* Change the screen orientation and rotation direction to be unified across Android, iPhone, and iPad.
+* Change specify the NDK version of the Android sample.
+* Change to read shader source codes from files.
+* Change the compile and target SDK version of Android OS to 15.0 (API 35).
+ * Upgrade the version of Android Gradle Plugin from 8.1.1 to 8.6.1.
+ * Upgrade the version of Gradle from 8.2 to 8.7.
+ * Upgrade the version of NDK from 25.2.9519653 to 26.3.11579264.
+ * Change the minimum version of Android Studio to Ladybug(2024.2.1 Patch 2).
+* Change the minimum support version of Java to 8.
+* Change the function for playing back expression motions from CubismExpressionMotionManager::StartMotionPriority() to CubismExpressionMotionManager::StartMotion().
+* Change to use GLSurfaceView event queues to handle touch events.
+
+### Fixed
+
+* Fix memory leak in Vulkan.
+* Fixed drawing failure when enabling `USE_RENDER_TARGET` macros in Vulkan samples.
+* Fix memory leak when exit in D3D9 and D3D11.
+* Fix exit error in Vulkan.
+* Fix the processing of anisotropy filtering in Vulkan to match that of other renderers.
+* Fix an issue on Windows where an error would occur if the model name contained certain characters.
+* Implement support for `MSVC19.40` in the VS2022 build. by [@tatsuya-shiozawa](https://github.com/Live2D/CubismNativeSamples/pull/46)
+* Fix an issue where a compile error occurred due to missing includes in the OpenGL iOS minimum sample.
+* Fix an issue in the Android sample where the model display would reset after performing certain operations.
+* Fix a memory leak in the compilation process of shader strings in OpenGL.
+* Fix an issue that could cause drawing errors when the application is restored from the background.
+* Fix an issue in the OpenGL sample where the textures are not released.
+* Fix a warning due to the initial value of programId being NULL.
+* Fix an issue that caused white edge-like objects to be drawn when enabling the `USE_RENDER_TARGET` or `USE_MODEL_RENDER_TARGET` flag in `LAppLive2DManager`.
+* Fix an issue causing a decrease in rendering resolution when using render targets in the Metal sample project.
+* Fix an issue where rendering would break when using the iPad with `USE_RENDER_TARGET` or `USE_MODEL_RENDER_TARGET` defined in OpenGL samples.
+
+### Removed
+
+* Remove Visual Studio 2013 samples.
+* Remove armeabi-v7a from architecture support.
+* Remove the Cocos2d-x sample project.
+* Remove the callback what motion playback finishes on the minimum sample.
+* Remove unnecessary declarations in the OpenGL Android sample.
+
+
## [5-r.1] - 2024-03-26
### Added
@@ -17,6 +70,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
* The log function was changed because it was ambiguous whether or not a newline was inserted.
* Change so that `LAppSprite` is not depend on `LAppDelegate` in D3D11 and D3D9, Metal, Vulkan.
* Some function arguments in `LAppSprite` are changed in D3D11 and D3D9, Metal, Vulkan.
+* Change to read shader source codes from files.
### Fixed
@@ -43,7 +97,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
* Change so that `LAppSprite` is not depend on `LAppDelegate` in Android.
* Change so that `ViewController` is not include on `LAppSprite` in iOS.
* Change the path acquisition process to a library function on OpenGL Mac and Linux.
-* Change the compile and target SDK version of Android OS to 14.0 (API 34).
+* Change the compile and target SDK version of Android OS to 14.0 (API 34).
* Upgrade the version of Android Gradle Plugin from 8.0.2 to 8.1.1.
* Upgrade the version of Gradle from 8.1.1 to 8.2.
* Change the minimum version of Android Studio to Hedgehog(2023.1.1).
@@ -407,6 +461,7 @@ See [Core Changelog] for details.
* What was `Package.json` is currently being changed to`cubism-info.yml`.
+[5-r.2]: https://github.com/Live2D/CubismNativeSamples/compare/5-r.1...5-r.2
[5-r.1]: https://github.com/Live2D/CubismNativeSamples/compare/5-r.1-beta.4...5-r.1
[5-r.1-beta.4]: https://github.com/Live2D/CubismNativeSamples/compare/5-r.1-beta.3...5-r.1-beta.4
[5-r.1-beta.3]: https://github.com/Live2D/CubismNativeSamples/compare/5-r.1-beta.2...5-r.1-beta.3
diff --git a/Core/CHANGELOG.md b/Core/CHANGELOG.md
index afe4260c..04b3de48 100644
--- a/Core/CHANGELOG.md
+++ b/Core/CHANGELOG.md
@@ -5,6 +5,31 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
+## 2024-12-19
+
+### Removed
+
+* [Native] Remove Visual Studio 2013 (MSVC 120) static library.
+
+
+## 2024-11-07
+
+### Added
+
+* [Native] Add experimental support `arm64` library for linux.
+
+### Removed
+
+* [Unity,Native,Java] Remove Android ARM v7 library.
+
+
+## 2024-04-04
+
+### Added
+
+* [Unity] Add library(.so) for HarmonyOS build.
+
+
## 2024-03-26
### Remove
diff --git a/Core/README.ja.md b/Core/README.ja.md
index 3898c395..92cd9654 100644
--- a/Core/README.ja.md
+++ b/Core/README.ja.md
@@ -29,12 +29,12 @@ Core
| プラットフォーム | アーキテクチャ | dll | lib | パス | 注記 |
| --- | --- | --- | --- | --- | --- |
| Android | ARM64 | ✓ | ✓ | android/arm64-v8a | |
-| Android | ARMv7 | ✓ | ✓ | android/armeabi-v7a | このライブラリは現在非推奨で、近日中に削除される予定です。 |
| Android | x86 | ✓ | ✓ | android/x86 | |
| Android | x86_64 | ✓ | ✓ | android/x86_64 | |
| iOS | ARM64 | | ✓ | ios/xxx-iphoneos | iOSデバイス |
| iOS | x86_64 | | ✓ | ios/xxx-iphonesimulator | iOS Simulator |
| Linux | x86_64 | ✓ | ✓ | linux/x86_64 | |
+| Linux | ARM64 | ✓ | ✓ | experimental/linux/ARM64 | |
| macOS | ARM64 | ✓ | ✓ | macos/arm64 | |
| macOS | x86_64 | ✓ | ✓ | macos/x86_64 | |
| Mac Catalyst | ARM64 | | ✓ | experimental/catalyst | Universal Binary |
@@ -59,7 +59,6 @@ Core
| VC++バージョン | Visual Studioバージョン |
| ---: | --- |
-| 120 | Visual Studio 2013 |
| 140 | Visual Studio 2015 |
| 141 | Visual Studio 2017 |
| 142 | Visual Studio 2019 |
diff --git a/Core/README.md b/Core/README.md
index 95b6f78a..e7832937 100644
--- a/Core/README.md
+++ b/Core/README.md
@@ -31,12 +31,12 @@ Core
| Platform | Architecture | dll | lib | Path | Note |
| --- | --- | --- | --- | --- | --- |
| Android | ARM64 | ✓ | ✓ | android/arm64-v8a | |
-| Android | ARMv7 | ✓ | ✓ | android/armeabi-v7a | This library is currently deprecated and will be removed in the near future. |
| Android | x86 | ✓ | ✓ | android/x86 | |
| Android | x86_64 | ✓ | ✓ | android/x86_64 | |
| iOS | ARM64 | | ✓ | ios/xxx-iphoneos | iOS Devices |
| iOS | x86_64 | | ✓ | ios/xxx-iphonesimulator | iOS Simulator |
| Linux | x86_64 | ✓ | ✓ | linux/x86_64 | |
+| Linux | ARM64 | ✓ | ✓ | experimental/linux/ARM64 | |
| macOS | ARM64 | ✓ | ✓ | macos/arm64 | |
| macOS | x86_64 | ✓ | ✓ | macos/x86_64 | |
| Mac Catalyst | ARM64 | | ✓ | experimental/catalyst | Universal Binary |
@@ -61,7 +61,6 @@ Below is the Visual Studio version for the VC++ version.
| VC++ version | Visual Studio version |
| ---: | --- |
-| 120 | Visual Studio 2013 |
| 140 | Visual Studio 2015 |
| 141 | Visual Studio 2017 |
| 142 | Visual Studio 2019 |
diff --git a/Core/RedistributableFiles.txt b/Core/RedistributableFiles.txt
index 6f02cc2d..c20397fb 100644
--- a/Core/RedistributableFiles.txt
+++ b/Core/RedistributableFiles.txt
@@ -2,7 +2,6 @@ The following is a list of files available for redistribution
under the terms of the Live2D Proprietary Software License Agreement:
- dll/android/arm64-v8a/libLive2DCubismCore.so
-- dll/android/armeabi-v7a/libLive2DCubismCore.so
- dll/android/x86/libLive2DCubismCore.so
- dll/android/x86_64/libLive2DCubismCore.so
- dll/experimental/rpi/libLive2DCubismCore.so
@@ -11,6 +10,7 @@ under the terms of the Live2D Proprietary Software License Agreement:
- dll/experimental/uwp/x64/Live2DCubismCore.dll
- dll/experimental/uwp/x86/Live2DCubismCore.dll
- dll/linux/x86_64/libLive2DCubismCore.so
+- dll/experimental/linux/arm64/libLive2DCubismCore.so
- dll/macos/Live2DCubismCore.bundle
- dll/macos/libLive2DCubismCore.dylib
- dll/windows/x86/Live2DCubismCore.dll
@@ -18,7 +18,6 @@ under the terms of the Live2D Proprietary Software License Agreement:
- dll/windows/x86_64/Live2DCubismCore.dll
- dll/windows/x86_64/Live2DCubismCore.lib
- lib/android/arm64-v8a/libLive2DCubismCore.a
-- lib/android/armeabi-v7a/libLive2DCubismCore.a
- lib/android/x86/libLive2DCubismCore.a
- lib/android/x86_64/libLive2DCubismCore.so
- lib/experimental/catalyst/libLive2DCubismCore.a
@@ -28,12 +27,9 @@ under the terms of the Live2D Proprietary Software License Agreement:
- lib/ios/Release-iphoneos/libLive2DCubismCore.a
- lib/ios/Release-iphonesimulator/libLive2DCubismCore.a
- lib/linux/x86_64/libLive2DCubismCore.a
+- lib/experimental/linux/arm64/libLive2DCubismCore.a
- lib/macos/arm64/libLive2DCubismCore.a
- lib/macos/x86_64/libLive2DCubismCore.a
-- lib/windows/x86/120/Live2DCubismCore_MD.lib
-- lib/windows/x86/120/Live2DCubismCore_MDd.lib
-- lib/windows/x86/120/Live2DCubismCore_MT.lib
-- lib/windows/x86/120/Live2DCubismCore_MTd.lib
- lib/windows/x86/140/Live2DCubismCore_MD.lib
- lib/windows/x86/140/Live2DCubismCore_MDd.lib
- lib/windows/x86/140/Live2DCubismCore_MT.lib
@@ -50,10 +46,6 @@ under the terms of the Live2D Proprietary Software License Agreement:
- lib/windows/x86/143/Live2DCubismCore_MDd.lib
- lib/windows/x86/143/Live2DCubismCore_MT.lib
- lib/windows/x86/143/Live2DCubismCore_MTd.lib
-- lib/windows/x86_64/120/Live2DCubismCore_MD.lib
-- lib/windows/x86_64/120/Live2DCubismCore_MDd.lib
-- lib/windows/x86_64/120/Live2DCubismCore_MT.lib
-- lib/windows/x86_64/120/Live2DCubismCore_MTd.lib
- lib/windows/x86_64/140/Live2DCubismCore_MD.lib
- lib/windows/x86_64/140/Live2DCubismCore_MDd.lib
- lib/windows/x86_64/140/Live2DCubismCore_MT.lib
diff --git a/Framework b/Framework
index 3d9f82a4..5a5e4923 160000
--- a/Framework
+++ b/Framework
@@ -1 +1 @@
-Subproject commit 3d9f82a47f3f9c8c89ae692703f2dad79296b61a
+Subproject commit 5a5e4923c245944d71fe93a875385bb15ba0e206
diff --git a/NOTICE.ja.md b/NOTICE.ja.md
index 2bc598e6..7db61234 100644
--- a/NOTICE.ja.md
+++ b/NOTICE.ja.md
@@ -4,6 +4,12 @@
# お知らせ
+## [注意事項] Cubism SDK for NativeのCocos2d-xサポートについて (2024-12-19)
+
+Cubism SDK for NativeのCocos2d-x対応につきまして、Cubism 5 SDK for Native R2でサポートを終了いたしました。
+本件のお問い合わせにつきましては、[お問合せフォーム]()からご連絡ください。
+
+
## [注意事項] Apple社のPrivacy Manifest Policy対応について
Apple社が対応を必要としているPrivacy Manifest Policyについて、本製品では指定されているAPI及びサードパーティ製品を使用しておりません。
@@ -36,26 +42,9 @@ MetalのMac Catalystのビルド時にエラーが発生する場合がござい
* cmakeを3.27未満のバージョンで使用する
-## [注意事項] Cocos2d-xセットアップのエラーについて (2022-03-15)
-
-Cocos2d-xサンプルプロジェクトのセットアップ時に実行するsetup-cocos2dバッチにおいてエラーが発生いたします。
-これはGitHubがGitプロトコルセキュリティを改善したことに起因し、GitにてCocos2d-xのsubmodule取得が失敗するためです。
-具体的には`git://`経由での接続ができなくなったためエラーが発生しています。
+## [注意事項] Metal の macOSサンプルビルドにおけるメモリリークについて (2021-12-09)
-詳しくはGitHub公式ブログをご確認ください。
-
-* [GitHub 公式ブログ](https://github.blog/2021-09-01-improving-git-protocol-security-github/)
-
-### 回避方法
-
-* ターミナルもしくはコマンドプロンプトにて以下のコマンドを実行することで、`git://`を用いた接続を`https://`に置き換える
- * `git config --global url."https://github.com/".insteadOf git://github.com/`
- * このコマンドは実行端末の全ユーザのgitconfigに影響します。ご了承ください。
-
-
-## [注意事項] Metal及びCocos2d-x v4.0 の macOSサンプルビルドにおけるメモリリークについて (2021-12-09)
-
-Metal及びCocos2d-x v4.0 の macOSサンプルビルドにおいてメモリリークが発生いたします。
+Metal の macOSサンプルビルドにおいてメモリリークが発生いたします。
これはMetalフレームワーク内で発生するため、公式の対応をお待ち下さい。
本件のお問い合わせについて弊社ではお答えいたしかねますので、ご了承ください。
@@ -64,35 +53,6 @@ Metal及びCocos2d-x v4.0 の macOSサンプルビルドにおいてメモリリ
* [Apple Developer Forums - Memory leak in MTLCommandBuffer?](https://developer.apple.com/forums/thread/120931)
-## [制限事項] Cocos2d-x v4.0 の Linux(Ubuntu)サンプルビルドについて (2021-04-15)
-
-Cocos2d-x v4.0 は `Ubuntu 20.04` ビルドに対応しておりません。
-使用する際は以下の回避方法を確認し、いずれかを適用してご利用いただきますようお願いいたします。
-
-### 回避方法
-
-* `Ubuntu 16.04` または `Ubuntu 18.04` を使用する
-
-* 以下issueを確認し、`Cocos2d-x v4.0` で使用されている `libchipmunk` ライブラリを差し替える
- * [cocos2d/cocos2d-x linking error when integrating with libchipmunk on linux#20471](https://github.com/cocos2d/cocos2d-x/issues/20471)
- * WARNING: この回避方法を使用してビルドしたプロジェクトはいかなる場合でも保守いたしかねます
-
-
-## [注意事項] Visual Studio 2013 ご利用時の OpenGL サンプルビルドについて (2021-02-17)
-
-`Visual Studio 2013` を使用した `OpenGL` サンプルビルドでは、`setup_glew_glfw.bat` をそのまま使用してビルドすると `GLEW` にてリンクエラーが発生します。
-以下回避方法を確認し、ご利用いただきますようお願いいたします。
-
-### 回避方法
-
-* `GLEW 2.2.0` を使用する場合
- * `glew` プロジェクトから `libvcruntime.lib` の参照を削除する
- * `Visual Studio 2013` 以降の Visual Studio を使用する
-
-* `GLEW 2.1.0` を使用する場合
- * `setup_glew_glfw_vs2013.bat` を使用して `thirdParty` のセットアップを行う
-
-
## Cubism Core
### [注意事項] macOS Catalina 以降のバージョンでの `.bundle` と `.dylib` の利用について
diff --git a/NOTICE.md b/NOTICE.md
index 36f2b7e6..069c60c9 100644
--- a/NOTICE.md
+++ b/NOTICE.md
@@ -4,6 +4,12 @@
# Notices
+## [Caution] Regarding Cubism SDK for Native Cocos2d-x Support (2024-12-19)
+
+Support for Cocos2d-x in the Cubism SDK for Native has been discontinued starting with Cubism 5 SDK for Native R2.
+For any inquiries regarding this matter, please contact us through the [contact form]]().
+
+
## [Caution] Support for Apple's Privacy Manifest Policy
This product does not use the APIs or third-party products specified in Apple's privacy manifest policy.
@@ -36,26 +42,9 @@ We will continue to investigate the details.
* Use cmake with versions less than 3.27
-## [Caution] About Cocos2d-x setup error (2022-03-15)
-
-An error occurs in the setup-cocos2d batch that is executed when setting up the Cocos2d-x sample project.
-This is because GitHub has improved the security of the Git protocol, and Git fails to get the Cocos2d-x submodule.
-Specifically, an error has occurred because the connection via `git://` is no longer possible.
+## [Caution] Memory leak in macOS sample builds of Metal (2021-12-09)
-Please check the official GitHub blog for details.
-
-* [GitHub Official Blog](https://github.blog/2021-09-01-improving-git-protocol-security-github/)
-
-### Workaround
-
-* Replace the connection using `git://` with `https://` by executing the following command in the terminal or command prompt.
- * `git config --global url."https://github.com/".insteadOf git://github.com/`
- * Please note that this command affects gitconfig for all users of the execution terminal.
-
-
-## [Caution] Memory leak in macOS sample builds of Metal and Cocos2d-x v4.0 (2021-12-09)
-
-A memory leak occurs in the macOS sample builds of Metal and Cocos2d-x v4.0.
+A memory leak occurs in the macOS sample builds of Metal.
This happens within the Metal framework, so please wait for official support.
Note that we cannot answer inquiries regarding this matter.
@@ -64,35 +53,6 @@ Please check the Apple Developer Forums for more information.
* [Apple Developer Forums - Memory leak in MTLCommandBuffer?](https://developer.apple.com/forums/thread/120931)
-## [Limitation] About the Linux (Ubuntu) sample builds of Cocos2d-x v4.0 (2021-04-15)
-
-Cocos2d-x v4.0 does not support `Ubuntu 20.04` builds.
-Please check and apply one of the following workarounds when using it.
-
-### Workaround
-
-* Use `Ubuntu 16.04` or `Ubuntu 18.04`
-
-* Check the following issue and replace the `libchipmunk` library used in `Cocos2d-x v4.0`
- * [cocos2d/cocos2d-x linking error when integrating with libchipmunk on linux#20471](https://github.com/cocos2d/cocos2d-x/issues/20471)
- * WARNING: Projects built using this workaround cannot be maintained under any circumstances.
-
-
-## [Caution] About OpenGL sample builds when using Visual Studio 2013 (2021-02-17)
-
-In the `OpenGL` sample builds using `Visual Studio 2013`, a link error will occur in `GLEW` if you build using `setup_glew_glfw.bat` as is.
-Please check and use the workaround below.
-
-### Workaround
-
-* When using `GLEW 2.2.0`
- * Remove the reference to `libvcruntime.lib` from the `glew` project
- * Use Visual Studio later than `Visual Studio 2013`
-
-* When using `GLEW 2.1.0`
- * Use `setup_glew_glfw_vs2013.bat` to set up `thirdParty`
-
-
## Cubism Core
### [Caution] About using `.bundle` and `.dylib` on macOS Catalina or later
diff --git a/README.ja.md b/README.ja.md
index 0143fc25..0b105a06 100644
--- a/README.ja.md
+++ b/README.ja.md
@@ -35,7 +35,6 @@ Cubism 5 Editorに搭載された新機能のSDK対応については [こちら
├─ Core # Live2D Cubism Core が含まれるディレクトリ
├─ Framework # レンダリングやアニメーション機能などのソースコードが含まれるディレクトリ
└─ Samples
- ├─ Cocos2d-x # Cocos2d-x のサンプルプロジェクトが含まれるディレクトリ
├─ D3D9 # DirectX 9.0c のサンプルプロジェクトが含まれるディレクトリ
├─ D3D11 # DirectX 11 のサンプルプロジェクトが含まれるディレクトリ
├─ Metal # Metal のサンプルプロジェクトが含まれるディレクトリ
@@ -111,36 +110,37 @@ Core : [CHANGELOG.md](Core/CHANGELOG.md)
| 開発ツール | バージョン |
| --- | --- |
-| Android Studio | Iguana 2023.2.1 |
-| CMake | 3.28.3 |
-| Visual Studio 2013 | Update 5 |
+| Android Studio | Ladybug 2024.2.1 Patch 3 |
+| DevEco Studio | 5.0.5.306 |
+| CMake | 3.31.2 |
| Visual Studio 2015 | Update 3 |
-| Visual Studio 2017 | 15.9.60 |
-| Visual Studio 2019 | 16.11.34 |
-| Visual Studio 2022 | 17.9.4 |
-| Xcode | 15.3 |
+| Visual Studio 2017 | 15.9.68 |
+| Visual Studio 2019 | 16.11.42 |
+| Visual Studio 2022 | 17.12.3 |
+| Xcode | 16.2 |
### Android
| Android SDK tools | バージョン |
| --- | --- |
-| Android NDK | 26.2.11394342 |
-| Android SDK | 34.0.0 |
+| Android NDK | 26.3.11579264 |
+| Android SDK | 35.0.0 |
| CMake | 3.22.1 |
+### HarmonyOS
+
+| HarmonyOS SDK tools | バージョン |
+| --- | --- |
+| HarmonyOS SDK | 5.0.1.112 |
+
### Linux
| 系統 | ディストリビューション・バージョン | Docker イメージ | GCC |
| --- | --- | --- | --- |
| Red Hat | Amazon Linux 2 | `amazonlinux:2` | 7.3.1 |
-| Red Hat | CentOS 7 | `centos:7` | 4.8.5 |
-| Red Hat | CentOS Stream 8 *1 | `centos:latest` | 8.5.0 |
-| Red Hat | CentOS Stream 9 | - | 12.2.1 |
| Red Hat | AlmaLinux | `almalinux:latest` | 11.4.1 |
-| Debian | Ubuntu 18.04 | `ubuntu:18.04` | 7.5.0 |
| Debian | Ubuntu 22.04.4 | `ubuntu:22.04` | 11.4.0 |
-
-*1 CentOS 8はサポートしておりません
+| Debian | Ubuntu 24.04.1 | `ubuntu:24.04` | 13.3.0 |
#### Mesa ライブラリ
@@ -156,25 +156,31 @@ Core : [CHANGELOG.md](Core/CHANGELOG.md)
| プラットフォーム | バージョン |
| --- | --- |
-| iOS / iPadOS | 17.4 |
-| macOS | 14.4 |
-| Windows 10 | 22H2 |
-| Windows 11 | 22H2 |
+| iOS / iPadOS | 18.2 |
+| macOS | 15.2 |
+| Windows 10 | 23H2 |
+| Windows 11 | 23H2 |
### Android
| バージョン | デバイス | Tegra |
| --- | --- | --- |
-| 13 | Pixel 7a | |
+| 15 | Pixel 7a | |
| 7.1.1 | Nexus 9 | ✔︎ |
+### HarmonyOS
+
+| バージョン | デバイス |
+| --- | --- |
+| NEXT.0.0.71 | HUAWEI Mate 60 Pro |
+
### Linux
| 系統 | ディストリビューション | バージョン |
| --- | --- | --- |
| Red Hat | Amazon Linux | 2 |
| Red Hat | AlmaLinux | 9 |
-| Debian | Ubuntu | 22.04.4 |
+| Debian | Ubuntu | 24.04.1 |
## プロジェクトへの貢献
diff --git a/README.md b/README.md
index f047544b..c277c656 100644
--- a/README.md
+++ b/README.md
@@ -35,7 +35,6 @@ For compatibility with previous versions of Cubism SDK, please refer to [here](h
├─ Core # Directory containing Live2D Cubism Core
├─ Framework # Directory containing source code for rendering and animation functions
└─ Samples
- ├─ Cocos2d-x # Directory containing the Cocos2d-x sample project
├─ D3D9 # Directory containing the DirectX 9.0c sample project
├─ D3D11 # Directory containing the DirectX 11 sample project
├─ Metal # Directory containing the Metal sample project
@@ -110,36 +109,37 @@ Core : [CHANGELOG.md](Core/CHANGELOG.md)
| Development Tool | Version |
| --- | --- |
-| Android Studio | Iguana 2023.2.1 |
-| CMake | 3.28.3 |
-| Visual Studio 2013 | Update 5 |
+| Android Studio | Ladybug 2024.2.1 Patch 3 |
+| DevEco Studio | 5.0.5.306 |
+| CMake | 3.31.2 |
| Visual Studio 2015 | Update 3 |
-| Visual Studio 2017 | 15.9.60 |
-| Visual Studio 2019 | 16.11.34 |
-| Visual Studio 2022 | 17.9.4 |
-| Xcode | 15.3 |
+| Visual Studio 2017 | 15.9.68 |
+| Visual Studio 2019 | 16.11.42 |
+| Visual Studio 2022 | 17.12.3 |
+| Xcode | 16.2 |
### Android
| Android SDK tools | Version |
| --- | --- |
-| Android NDK | 26.2.11394342 |
-| Android SDK | 34.0.0 |
+| Android NDK | 26.3.11579264 |
+| Android SDK | 35.0.0 |
| CMake | 3.22.1 |
+### HarmonyOS
+
+| HarmonyOS SDK tools | Version |
+| --- | --- |
+| HarmonyOS SDK | 5.0.1.112 |
+
### Linux
| System | Distribution version | Docker image | GCC |
| --- | --- | --- | --- |
| Red Hat | Amazon Linux 2 | `amazonlinux:2` | 7.3.1 |
-| Red Hat | CentOS 7 | `centos:7` | 4.8.5 |
-| Red Hat | CentOS Stream 8 *1 | `centos:latest` | 8.5.0 |
-| Red Hat | CentOS Stream 9 | - | 12.2.1 |
| Red Hat | AlmaLinux | `almalinux:latest` | 11.4.1 |
-| Debian | Ubuntu 18.04 | `ubuntu:18.04` | 7.5.0 |
| Debian | Ubuntu 22.04.4 | `ubuntu:22.04` | 11.4.0 |
-
-*1 CentOS 8 is not supported
+| Debian | Ubuntu 24.04.1 | `ubuntu:24.04` | 13.3.0 |
#### Mesa library
@@ -155,25 +155,31 @@ Core : [CHANGELOG.md](Core/CHANGELOG.md)
| Platform | Version |
| --- | --- |
-| iOS / iPadOS | 17.4 |
-| macOS | 14.4 |
-| Windows 10 | 22H2 |
-| Windows 11 | 22H2 |
+| iOS / iPadOS | 18.2 |
+| macOS | 15.2 |
+| Windows 10 | 23H2 |
+| Windows 11 | 23H2 |
### Android
| Version | Device | Tegra |
| --- | --- | --- |
-| 13 | Pixel 7a | |
+| 15 | Pixel 7a | |
| 7.1.1 | Nexus 9 | ✔︎ |
+### HarmonyOS
+
+| Version | Device |
+| --- | --- |
+| NEXT.0.0.71 | HUAWEI Mate 60 Pro |
+
### Linux
| System | Distribution | Version |
| --- | --- | --- |
| Red Hat | Amazon Linux | 2 |
| Red Hat | AlmaLinux | 9 |
-| Debian | Ubuntu | 22.04.4 |
+| Debian | Ubuntu | 24.04.1 |
## Contributing
diff --git a/Samples/Cocos2d-x/.editorconfig b/Samples/Cocos2d-x/.editorconfig
deleted file mode 100644
index 08ffcc45..00000000
--- a/Samples/Cocos2d-x/.editorconfig
+++ /dev/null
@@ -1,5 +0,0 @@
-[/Demo/Classes/**/*.{h,cpp,hpp}]
-charset = utf-8-bom
-
-[/Demo/proj.win/src/**/*.{h,cpp}]
-charset = utf-8-bom
diff --git a/Samples/Cocos2d-x/Demo/CMakeLists.txt b/Samples/Cocos2d-x/Demo/CMakeLists.txt
deleted file mode 100644
index 2152daae..00000000
--- a/Samples/Cocos2d-x/Demo/CMakeLists.txt
+++ /dev/null
@@ -1,306 +0,0 @@
-cmake_minimum_required(VERSION 3.10)
-
-option(
- CORE_CRL_MD
- "Use Cubism Core that is multithread-specific and DLL-specific version"
- OFF
-)
-
-# Set app name.
-set(APP_NAME Demo)
-# Set directory paths.
-set(COCOS2DX_ROOT_PATH ${CMAKE_CURRENT_SOURCE_DIR}/../thirdParty/cocos2d)
-set(CMAKE_MODULE_PATH ${COCOS2DX_ROOT_PATH}/cmake/Modules)
-set(SDK_ROOT_PATH ${CMAKE_CURRENT_SOURCE_DIR}/../../..)
-set(CORE_PATH ${SDK_ROOT_PATH}/Core)
-set(FRAMEWORK_PATH ${SDK_ROOT_PATH}/Framework)
-set(CLASSES_PATH ${CMAKE_CURRENT_SOURCE_DIR}/Classes)
-set(RES_PATH ${SDK_ROOT_PATH}/Samples/Resources)
-
-# Set project.
-project(${APP_NAME})
-
-# Set Visual Studio startup project.
-set_property(DIRECTORY PROPERTY VS_STARTUP_PROJECT ${APP_NAME})
-
-# Define output directory.
-set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/bin/${APP_NAME})
-# Set configuration (Release and Debug only).
-set(CMAKE_CONFIGURATION_TYPES Debug Release
- CACHE STRING "Configurations" FORCE
-)
-# Suppress generation of ZERO_CHECK project.
-set(CMAKE_SUPPRESS_REGENERATION ON)
-
-# Specify version of compiler.
-set(CMAKE_CXX_STANDARD 11)
-set(CMAKE_CXX_STANDARD_REQUIRED ON)
-set(CMAKE_CXX_EXTENSIONS OFF)
-
-# Add cocos libs.
-include(CocosBuildSet)
-add_subdirectory(
- ${COCOS2DX_ROOT_PATH}/cocos
- ${ENGINE_BINARY_PATH}/cocos/core
-)
-
-# Record sources, headers, resources...
-set(GAME_SOURCE)
-set(GAME_HEADER)
-
-# Add resource directories.
-set(GAME_RES_FOLDER ${CMAKE_CURRENT_SOURCE_DIR}/Resources ${RES_PATH})
-if(APPLE OR WINDOWS)
- cocos_mark_multi_resources(common_res_files
- RES_TO Resources FOLDERS ${GAME_RES_FOLDER}
- )
-endif()
-
-# Add cross-platforms source files and header files.
-list(APPEND GAME_SOURCE
- ${CLASSES_PATH}/AppDelegate.cpp
- ${CLASSES_PATH}/LAppAllocator.cpp
- ${CLASSES_PATH}/LAppDefine.cpp
- ${CLASSES_PATH}/LAppLive2DManager.cpp
- ${CLASSES_PATH}/LAppModel.cpp
- ${CLASSES_PATH}/LAppPal.cpp
- ${CLASSES_PATH}/LAppSprite.cpp
- ${CLASSES_PATH}/LAppView.cpp
- ${CLASSES_PATH}/SampleScene.cpp
- ${CLASSES_PATH}/TouchManager.cpp
- ${CLASSES_PATH}/LAppLive2DManagerInternal.cpp
-)
-
-list(APPEND GAME_HEADER
- ${CLASSES_PATH}/AppDelegate.h
- ${CLASSES_PATH}/AppMacros.h
- ${CLASSES_PATH}/LAppAllocator.hpp
- ${CLASSES_PATH}/LAppDefine.hpp
- ${CLASSES_PATH}/LAppLive2DManager.hpp
- ${CLASSES_PATH}/LAppModel.hpp
- ${CLASSES_PATH}/LAppPal.hpp
- ${CLASSES_PATH}/LAppSprite.hpp
- ${CLASSES_PATH}/LAppView.hpp
- ${CLASSES_PATH}/SampleScene.h
- ${CLASSES_PATH}/TouchManager.h
- ${CLASSES_PATH}/LAppLive2DManagerInternal.h
-)
-
-# Add Cubism Core as static library.
-add_library(Live2DCubismCore STATIC IMPORTED)
-# Specify Cubism Core library path for each platform and add source files.
-if(ANDROID)
- list(APPEND GAME_SOURCE
- proj.android/app/jni/demo/main.cpp
- )
- set_target_properties(Live2DCubismCore
- PROPERTIES
- IMPORTED_LOCATION
- ${CORE_PATH}/lib/android/${ANDROID_ABI}/libLive2DCubismCore.a
- )
-
-elseif(LINUX)
- list(APPEND GAME_SOURCE
- proj.linux/src/main.cpp)
- set_target_properties(Live2DCubismCore
- PROPERTIES
- IMPORTED_LOCATION
- ${CORE_PATH}/lib/linux/x86_64/libLive2DCubismCore.a
- )
-
-elseif(WINDOWS)
- list(APPEND GAME_HEADER
- proj.win/src/main.h
- proj.win/src/resource.h
- )
- list(APPEND GAME_SOURCE
- proj.win/src/main.cpp
- proj.win/src/game.rc
- ${common_res_files}
- )
-
- # Detect compiler.
- if(MSVC_VERSION MATCHES 1900)
- # Visual Studio 2015
- set(MSVC_NUM 140)
- elseif(MSVC_VERSION GREATER_EQUAL 1910 AND MSVC_VERSION LESS 1920)
- # Visual Studio 2017
- set(MSVC_NUM 141)
- elseif(MSVC_VERSION GREATER_EQUAL 1920 AND MSVC_VERSION LESS 1930)
- # Visual Studio 2019
- set(MSVC_NUM 142)
- elseif(MSVC_VERSION GREATER_EQUAL 1930 AND MSVC_VERSION LESS 1940)
- # Visual Studio 2022
- set(MSVC_NUM 143)
- elseif(MSVC)
- message(FATAL_ERROR "[${APP_NAME}] Unsupported Visual C++ compiler used.")
- else()
- message(FATAL_ERROR "[${APP_NAME}] Unsupported compiler used.")
- endif()
-
- # Detect core crt.
- if(CORE_CRL_MD)
- set(CRT MD)
- else()
- set(CRT MT)
- endif()
-
- set_target_properties(Live2DCubismCore
- PROPERTIES
- IMPORTED_LOCATION_DEBUG
- ${CORE_PATH}/lib/windows/x86/${MSVC_NUM}/Live2DCubismCore_${CRT}d.lib
- IMPORTED_LOCATION_RELEASE
- ${CORE_PATH}/lib/windows/x86/${MSVC_NUM}/Live2DCubismCore_${CRT}.lib
- )
-
-elseif(APPLE)
- if(IOS)
- list(APPEND GAME_HEADER
- proj.ios/src/AppController.h
- proj.ios/src/RootViewController.h
- )
- set(APP_UI_RES
- proj.ios/src/LaunchScreen.storyboard
- proj.ios/src/LaunchScreenBackground.png
- proj.ios/src/Images.xcassets
- )
- list(APPEND GAME_SOURCE
- proj.ios/src/main.m
- proj.ios/src/AppController.mm
- proj.ios/src/RootViewController.mm
- proj.ios/src/Prefix.pch
- ${APP_UI_RES}
- )
-
- # iPhone Simulator (i386) is not support on Cubism Core.
- if(IOS_PLATFORM STREQUAL "SIMULATOR")
- message(FATAL_ERROR
- "[CubismNativeSamples] Cubism Core does not support i386 iOS architecture."
- )
- endif()
-
- set_target_properties(Live2DCubismCore
- PROPERTIES
- IMPORTED_LOCATION_DEBUG
- ${CORE_PATH}/lib/ios/Debug-iphoneos/libLive2DCubismCore.a
- IMPORTED_LOCATION_RELEASE
- ${CORE_PATH}/lib/ios/Release-iphoneos/libLive2DCubismCore.a
- )
-
- elseif(MACOSX)
- set(APP_UI_RES
- proj.mac/src/Icon.icns
- proj.mac/src/Info.plist
- )
- list(APPEND GAME_SOURCE
- proj.mac/src/main.cpp
- proj.mac/src/Prefix.pch
- ${APP_UI_RES}
- )
- EXECUTE_PROCESS( COMMAND uname -m COMMAND tr -d '\n' OUTPUT_VARIABLE ARCHITECTURE )
- set_target_properties(Live2DCubismCore
- PROPERTIES
- IMPORTED_LOCATION
- ${CORE_PATH}/lib/macos/${ARCHITECTURE}/libLive2DCubismCore.a
- )
-
- endif()
- list(APPEND GAME_SOURCE ${common_res_files})
-endif()
-# Set core include directory.
-set_target_properties(Live2DCubismCore
- PROPERTIES
- INTERFACE_INCLUDE_DIRECTORIES ${CORE_PATH}/include
-)
-
-# Specify Cubism Framework rendering.
-set(FRAMEWORK_SOURCE Cocos2d)
-# Add Cubism Framework.
-add_subdirectory(${FRAMEWORK_PATH} ${CMAKE_CURRENT_BINARY_DIR}/Framework)
-# Add definitions for Cubism Framework.
-target_compile_definitions(Framework PUBLIC CSM_TARGET_COCOS)
-use_cocos2dx_compile_define(Framework)
-use_cocos2dx_compile_options(Framework)
-
-# Mark app complie info and libs info.
-set(all_code_files ${GAME_HEADER} ${GAME_SOURCE})
-if(NOT ANDROID)
- add_executable(${APP_NAME} ${all_code_files})
-else()
- add_library(${APP_NAME} SHARED ${all_code_files})
- add_subdirectory(
- ${COCOS2DX_ROOT_PATH}/cocos/platform/android
- ${ENGINE_BINARY_PATH}/cocos/platform
- )
- target_link_libraries(${APP_NAME}
- -Wl,--whole-archive
- cpp_android_spec
- -Wl,--no-whole-archive
- )
-endif()
-
-# Link libraries.
-target_link_libraries(${APP_NAME} Framework Live2DCubismCore cocos2d)
-# Specify include directories.
-target_include_directories(${APP_NAME} PRIVATE ${CLASSES_PATH})
-
-# Mark app resources and add definitions for Cubism Framework.
-setup_cocos_app_config(${APP_NAME})
-if(APPLE)
- set_target_properties(${APP_NAME} PROPERTIES RESOURCE "${APP_UI_RES}")
- if(MACOSX)
- set_xcode_property(${APP_NAME} INFOPLIST_FILE "${COCOS2DX_ROOT_PATH}/templates/cpp-template-default/proj.ios_mac/mac/Info.plist")
- target_compile_definitions(${APP_NAME} PRIVATE CSM_TARGET_MACOSX)
- target_compile_definitions(Framework PUBLIC CSM_TARGET_MAC_GL)
- set(COCOS_GLFW3 ${COCOS2DX_ROOT_PATH}/external/glfw3)
- target_include_directories(Framework PUBLIC ${COCOS_GLFW3}/include/Mac)
- target_include_directories(Framework PUBLIC ${COCOS2DX_ROOT_PATH}/cocos)
- elseif(IOS)
- # Add information aboud XCode project.
- set_xcode_property(${APP_NAME} INFOPLIST_FILE "${COCOS2DX_ROOT_PATH}/templates/cpp-template-default/proj.ios_mac/ios/Info.plist")
- set_xcode_property(${APP_NAME} ASSETCATALOG_COMPILER_APPICON_NAME "AppIcon")
- set_xcode_property(${APP_NAME} DEVELOPMENT_TEAM "")
- set_xcode_property(${APP_NAME} CODE_SIGN_IDENTITY "iPhone Developer")
- set_xcode_property(${APP_NAME} PRODUCT_BUNDLE_IDENTIFIER "com.live2d.demo-4-r7-cocos2dx")
- set_xcode_property(${APP_NAME} TARGETED_DEVICE_FAMILY "1,2")
- set_xcode_property(${APP_NAME} ONLY_ACTIVE_ARCH "NO")
- set_xcode_property(${APP_NAME} ARCHS "arm64")
- target_compile_definitions(${APP_NAME} PRIVATE CSM_TARGET_IOS)
- target_compile_definitions(Framework PUBLIC CSM_TARGET_IPHONE_ES2)
- target_include_directories(Framework PUBLIC ${COCOS2DX_ROOT_PATH}/cocos)
- endif()
-elseif(WINDOWS)
- cocos_copy_target_dll(${APP_NAME})
- target_compile_definitions(Framework PUBLIC CSM_TARGET_WIN_GL)
- # Specify glew directories for Cubism Framework.
- set(COCOS_GLEW ${COCOS2DX_ROOT_PATH}/external/win32-specific/gles)
- set(COCOS_GLFW3 ${COCOS2DX_ROOT_PATH}/external/glfw3)
- target_include_directories(Framework PUBLIC ${COCOS_GLEW}/include/OGLES)
- target_include_directories(Framework PUBLIC ${COCOS_GLFW3}/include/win32)
- target_include_directories(Framework PUBLIC ${COCOS2DX_ROOT_PATH}/cocos)
-elseif(ANDROID)
- target_compile_definitions(Framework PUBLIC CSM_TARGET_ANDROID_ES2)
- target_include_directories(Framework PUBLIC ${COCOS2DX_ROOT_PATH}/cocos)
-elseif(LINUX)
- set(COCOS_GLFW3 ${COCOS2DX_ROOT_PATH}/external/glfw3)
- target_include_directories(Framework PUBLIC ${COCOS_GLFW3}/include/linux)
- target_compile_definitions(Framework PUBLIC CSM_TARGET_LINUX_GL)
- target_include_directories(Framework PUBLIC ${COCOS2DX_ROOT_PATH}/cocos)
-endif()
-
-# Copy resources.
-if(LINUX OR WINDOWS)
- cocos_get_resource_path(APP_RES_DIR ${APP_NAME})
- cocos_copy_target_res(${APP_NAME}
- LINK_TO ${APP_RES_DIR} FOLDERS ${GAME_RES_FOLDER}
- )
-endif()
-
-# When this flag is turned on, the renderer will draw for each texture that has LAppModel.
-# Otherwise, will draw to the main framebuffer.
-# target_compile_definitions(${APP_NAME} PRIVATE USE_MODEL_RENDER_TARGET)
-
-# When this flag is turned on, the renderer will draw to the texture.
-# The texture only has LAppView.
-# This flag has higher priority than USE_MODEL_RENDER_TARGET.
-# target_compile_definitions(${APP_NAME} PRIVATE USE_RENDER_TARGET)
diff --git a/Samples/Cocos2d-x/Demo/Classes/AppDelegate.cpp b/Samples/Cocos2d-x/Demo/Classes/AppDelegate.cpp
deleted file mode 100644
index 175b72c1..00000000
--- a/Samples/Cocos2d-x/Demo/Classes/AppDelegate.cpp
+++ /dev/null
@@ -1,154 +0,0 @@
-/**
- * Copyright(c) Live2D Inc. All rights reserved.
- *
- * Use of this source code is governed by the Live2D Open Software license
- * that can be found at https://www.live2d.com/eula/live2d-open-software-license-agreement_en.html.
- */
-
-#include "AppDelegate.h"
-#include "SampleScene.h"
-#include "LAppLive2DManager.hpp"
-#include "LAppDefine.hpp"
-#include "LAppPal.hpp"
-
-#if USE_AUDIO_ENGINE && USE_SIMPLE_AUDIO_ENGINE
-#error "Don't use AudioEngine and SimpleAudioEngine at the same time. Please just select one in your game!"
-#endif
-
-#if USE_AUDIO_ENGINE
-#include "audio/include/AudioEngine.h"
-using namespace cocos2d::experimental;
-#elif USE_SIMPLE_AUDIO_ENGINE
-#include "audio/include/SimpleAudioEngine.h"
-using namespace CocosDenshion;
-#endif
-
-USING_NS_CC;
-
-static cocos2d::Size designResolutionSize = cocos2d::Size(LAppDefine::RenderTargetWidth, LAppDefine::RenderTargetHeight);
-static cocos2d::Size smallResolutionSize = cocos2d::Size(480, 320);
-static cocos2d::Size mediumResolutionSize = cocos2d::Size(1024, 768);
-static cocos2d::Size largeResolutionSize = cocos2d::Size(2048, 1536);
-
-AppDelegate::AppDelegate()
-{
-}
-
-AppDelegate::~AppDelegate()
-{
- Director::getInstance()->getEventDispatcher()->removeEventListener(_recreatedEventlistener);
-
- LAppLive2DManager::ReleaseInstance();
-
-#if USE_AUDIO_ENGINE
- AudioEngine::end();
-#elif USE_SIMPLE_AUDIO_ENGINE
- SimpleAudioEngine::end();
-#endif
-}
-
-// if you want a different context, modify the value of glContextAttrs
-// it will affect all platforms
-void AppDelegate::initGLContextAttrs()
-{
- // set OpenGL context attributes: red,green,blue,alpha,depth,stencil,multisamplesCount
- GLContextAttrs glContextAttrs = {8, 8, 8, 8, 24, 8, 0};
-
- GLView::setGLContextAttrs(glContextAttrs);
-}
-
-// if you want to use the package manager to install more packages,
-// don't modify or remove this function
-static int register_all_packages()
-{
- return 0; //flag for packages manager
-}
-
-bool AppDelegate::applicationDidFinishLaunching()
-{
- // initialize director
- auto director = Director::getInstance();
- auto glview = director->getOpenGLView();
- if(!glview)
- {
-#if (CC_TARGET_PLATFORM == CC_PLATFORM_WIN32) || (CC_TARGET_PLATFORM == CC_PLATFORM_MAC) || (CC_TARGET_PLATFORM == CC_PLATFORM_LINUX)
- glview = GLViewImpl::createWithRect("Demo", cocos2d::Rect(0, 0, designResolutionSize.width, designResolutionSize.height));
-#else
- glview = GLViewImpl::create("Demo");
-#endif
- director->setOpenGLView(glview);
- }
-
- // turn on display FPS
- director->setDisplayStats(true);
-
- // set FPS. the default value is 1.0/60 if you don't call this
- director->setAnimationInterval(1.0f / 60);
-
- // Set the design resolution
- glview->setDesignResolutionSize(designResolutionSize.width, designResolutionSize.height, ResolutionPolicy::NO_BORDER);
- auto frameSize = glview->getFrameSize();
- // if the frame's height is larger than the height of medium size.
- if (frameSize.height > mediumResolutionSize.height)
- {
- director->setContentScaleFactor(MIN(largeResolutionSize.height/designResolutionSize.height, largeResolutionSize.width/designResolutionSize.width));
- }
- // if the frame's height is larger than the height of small size.
- else if (frameSize.height > smallResolutionSize.height)
- {
- director->setContentScaleFactor(MIN(mediumResolutionSize.height/designResolutionSize.height, mediumResolutionSize.width/designResolutionSize.width));
- }
- // if the frame's height is smaller than the height of medium size.
- else
- {
- director->setContentScaleFactor(MIN(smallResolutionSize.height/designResolutionSize.height, smallResolutionSize.width/designResolutionSize.width));
- }
-
- register_all_packages();
-
- // prepare for Cubism Framework API.
- _cubismOption.LogFunction = LAppPal::PrintMessageLn;
- _cubismOption.LoggingLevel = LAppDefine::CubismLoggingLevel;
- Csm::CubismFramework::StartUp(&_cubismAllocator, &_cubismOption);
-
- _recreatedEventlistener = cocos2d::EventListenerCustom::create(EVENT_RENDERER_RECREATED, [this](EventCustom*)
- {
- LAppLive2DManager::GetInstance()->RecreateRenderer();
- });
- director->getEventDispatcher()->addEventListenerWithFixedPriority(_recreatedEventlistener, -1);
-
- // create a scene. it's an autorelease object
- auto scene = SampleScene::createScene();
-
- // run
- director->runWithScene(scene);
-
- return true;
-}
-
-// This function will be called when the app is inactive. Note, when receiving a phone call it is invoked.
-void AppDelegate::applicationDidEnterBackground()
-{
- Director::getInstance()->stopAnimation();
-
-#if USE_AUDIO_ENGINE
- AudioEngine::pauseAll();
-#elif USE_SIMPLE_AUDIO_ENGINE
- SimpleAudioEngine::getInstance()->pauseBackgroundMusic();
- SimpleAudioEngine::getInstance()->pauseAllEffects();
-#endif
-}
-
-// this function will be called when the app is active again
-void AppDelegate::applicationWillEnterForeground()
-{
- Director::getInstance()->startAnimation();
-
-#if USE_AUDIO_ENGINE
- AudioEngine::resumeAll();
-#elif USE_SIMPLE_AUDIO_ENGINE
- SimpleAudioEngine::getInstance()->resumeBackgroundMusic();
- SimpleAudioEngine::getInstance()->resumeAllEffects();
-#endif
- // Director::getInstance()->startAnimation();
-}
diff --git a/Samples/Cocos2d-x/Demo/Classes/AppDelegate.h b/Samples/Cocos2d-x/Demo/Classes/AppDelegate.h
deleted file mode 100644
index 2cc1cfb4..00000000
--- a/Samples/Cocos2d-x/Demo/Classes/AppDelegate.h
+++ /dev/null
@@ -1,58 +0,0 @@
-/**
- * Copyright(c) Live2D Inc. All rights reserved.
- *
- * Use of this source code is governed by the Live2D Open Software license
- * that can be found at https://www.live2d.com/eula/live2d-open-software-license-agreement_en.html.
- */
-
-#ifndef _APP_DELEGATE_H_
-#define _APP_DELEGATE_H_
-
-#include "cocos2d.h"
-#include "LAppAllocator.hpp"
-#include
-
-// #define USE_AUDIO_ENGINE 1
-// #define USE_SIMPLE_AUDIO_ENGINE 1
-
-/**
-@brief The cocos2d Application.
-
-Private inheritance here hides part of interface from Director.
-*/
-class AppDelegate : private cocos2d::Application
-{
-public:
- AppDelegate();
- virtual ~AppDelegate();
-
- virtual void initGLContextAttrs();
-
- /**
- @brief Implement Director and Scene init code here.
- @return true Initialize success, app continue.
- @return false Initialize failed, app terminate.
- */
- virtual bool applicationDidFinishLaunching();
-
- /**
- @brief Called when the application moves to the background
- @param the pointer of the application
- */
- virtual void applicationDidEnterBackground();
-
- /**
- @brief Called when the application reenters the foreground
- @param the pointer of the application
- */
- virtual void applicationWillEnterForeground();
-
-private:
- cocos2d::EventListenerCustom* _recreatedEventlistener;
-
- LAppAllocator _cubismAllocator;
- Csm::CubismFramework::Option _cubismOption;
-};
-
-#endif // _APP_DELEGATE_H_
-
diff --git a/Samples/Cocos2d-x/Demo/Classes/AppMacros.h b/Samples/Cocos2d-x/Demo/Classes/AppMacros.h
deleted file mode 100644
index 5a75936c..00000000
--- a/Samples/Cocos2d-x/Demo/Classes/AppMacros.h
+++ /dev/null
@@ -1,56 +0,0 @@
-#ifndef __APPMACROS_H__
-#define __APPMACROS_H__
-
-#include "cocos2d.h"
-
-/* For demonstrating using one design resolution to match different resources,
- or one resource to match different design resolutions.
-
- [Situation 1] Using one design resolution to match different resources.
- Please look into Appdelegate::applicationDidFinishLaunching.
- We check current device frame size to decide which resource need to be selected.
- So if you want to test this situation which said in title '[Situation 1]',
- you should change ios simulator to different device(e.g. iphone, iphone-retina3.5, iphone-retina4.0, ipad, ipad-retina),
- or change the window size in "proj.XXX/main.cpp" by "CCEGLView::setFrameSize" if you are using win32 or linux plaform
- and modify "proj.mac/AppController.mm" by changing the window rectangle.
-
- [Situation 2] Using one resource to match different design resolutions.
- The coordinates in your codes is based on your current design resolution rather than resource size.
- Therefore, your design resolution could be very large and your resource size could be small.
- To test this, just define the marco 'TARGET_DESIGN_RESOLUTION_SIZE' to 'DESIGN_RESOLUTION_2048X1536'
- and open iphone simulator or create a window of 480x320 size.
-
- [Note] Normally, developer just need to define one design resolution(e.g. 960x640) with one or more resources.
- */
-
-#define DESIGN_RESOLUTION_480X320 0
-#define DESIGN_RESOLUTION_1024X768 1
-#define DESIGN_RESOLUTION_2048X1536 2
-
-/* If you want to switch design resolution, change next line */
-#define TARGET_DESIGN_RESOLUTION_SIZE DESIGN_RESOLUTION_480X320
-
-typedef struct tagResource
-{
- cocos2d::CCSize size;
- char directory[100];
-} Resource;
-
-static Resource smallResource = {cocos2d::CCSizeMake(480, 320), "iphone"};
-static Resource mediumResource = {cocos2d::CCSizeMake(1024, 768), "ipad"};
-static Resource largeResource = {cocos2d::CCSizeMake(2048, 1536), "ipadhd"};
-
-#if (TARGET_DESIGN_RESOLUTION_SIZE == DESIGN_RESOLUTION_480X320)
-static cocos2d::CCSize designResolutionSize = cocos2d::CCSizeMake(480, 320);
-#elif (TARGET_DESIGN_RESOLUTION_SIZE == DESIGN_RESOLUTION_1024X768)
-static cocos2d::CCSize designResolutionSize = cocos2d::CCSizeMake(1024, 768);
-#elif (TARGET_DESIGN_RESOLUTION_SIZE == DESIGN_RESOLUTION_2048X1536)
-static cocos2d::CCSize designResolutionSize = cocos2d::CCSizeMake(2048, 1536);
-#else
-#error unknown target design resolution!
-#endif
-
-// The font size 24 is designed for small resolution, so we should change it to fit for current design resolution
-#define TITLE_FONT_SIZE (cocos2d::CCEGLView::sharedOpenGLView()->getDesignResolutionSize().width / smallResource.size.width * 24)
-
-#endif /* __APPMACROS_H__ */
diff --git a/Samples/Cocos2d-x/Demo/Classes/LAppAllocator.hpp b/Samples/Cocos2d-x/Demo/Classes/LAppAllocator.hpp
deleted file mode 100644
index 7be4d006..00000000
--- a/Samples/Cocos2d-x/Demo/Classes/LAppAllocator.hpp
+++ /dev/null
@@ -1,29 +0,0 @@
-/**
- * Copyright(c) Live2D Inc. All rights reserved.
- *
- * Use of this source code is governed by the Live2D Open Software license
- * that can be found at https://www.live2d.com/eula/live2d-open-software-license-agreement_en.html.
- */
-
-#pragma once
-
-#include
-#include
-
-/**
- * @brief メモリアロケーションを実装するクラス。
- *
- * メモリ確保・解放処理のインターフェースの実装。
- * フレームワークから呼び出される。
- *
- */
-class LAppAllocator : public Csm::ICubismAllocator
-{
- void* Allocate(const Csm::csmSizeType size);
-
- void Deallocate(void* memory);
-
- void* AllocateAligned(const Csm::csmSizeType size, const Csm::csmUint32 alignment);
-
- void DeallocateAligned(void* alignedMemory);
-};
diff --git a/Samples/Cocos2d-x/Demo/Classes/LAppLive2DManager.cpp b/Samples/Cocos2d-x/Demo/Classes/LAppLive2DManager.cpp
deleted file mode 100644
index c2d0f9db..00000000
--- a/Samples/Cocos2d-x/Demo/Classes/LAppLive2DManager.cpp
+++ /dev/null
@@ -1,474 +0,0 @@
-/**
- * Copyright(c) Live2D Inc. All rights reserved.
- *
- * Use of this source code is governed by the Live2D Open Software license
- * that can be found at https://www.live2d.com/eula/live2d-open-software-license-agreement_en.html.
- */
-
-#include "SampleScene.h"
-#include
-
-//cocos2d-x
-#include "base/CCDirector.h"
-#include "renderer/backend/Device.h"
-
-//Cubism
-#include "LAppLive2DManager.hpp"
-#include "LAppPal.hpp"
-#include "LAppDefine.hpp"
-#include "LAppView.hpp"
-#include "LAppSprite.hpp"
-
-#if defined(_WIN32)
-#include
-#elif defined(CSM_TARGET_IOS) || defined(CSM_TARGET_MACOSX) || defined(__ANDROID__)
-#include "LAppLive2DManagerInternal.h"
-#else
-#include
-#endif
-
-#ifdef CSM_TARGET_ANDROID_ES2
-#include
-#endif
-
-using namespace Csm;
-using namespace LAppDefine;
-
-USING_NS_CC;
-
-namespace {
- LAppLive2DManager* s_instance = NULL;
-
- void FinishedMotion(ACubismMotion* self)
- {
- LAppPal::PrintLogLn("Motion Finished: %x", self);
- }
-
- int CompareCsmString(const void* a, const void* b)
- {
- return strcmp(reinterpret_cast(a)->GetRawString(),
- reinterpret_cast(b)->GetRawString());
- }
-}
-
-LAppLive2DManager* LAppLive2DManager::GetInstance()
-{
- if (s_instance == NULL)
- {
- s_instance = new LAppLive2DManager();
- }
-
- return s_instance;
-}
-
-void LAppLive2DManager::ReleaseInstance()
-{
- if (s_instance != NULL)
- {
- delete s_instance;
- }
-
- s_instance = NULL;
-}
-
-LAppLive2DManager::LAppLive2DManager()
- : _sceneIndex(0)
- , _viewMatrix(NULL)
- , _renderTarget(SelectTarget_None)
- , _program(NULL)
- , _sprite(NULL)
- , _renderBuffer(NULL)
-{
- assert(CubismFramework::IsStarted());
-
- CubismFramework::Initialize();
-
- CreateShader();
- SetUpModel();
-
- int width = static_cast(cocos2d::Director::getInstance()->getOpenGLView()->getFrameSize().width);
- int height = static_cast(cocos2d::Director::getInstance()->getOpenGLView()->getFrameSize().height);
-
- // 画面全体を覆うサイズ
- _sprite = new LAppSprite(_program);
-
- _viewMatrix = new CubismMatrix44();
-
- // 使用するターゲット
- _renderBuffer = new Csm::Rendering::CubismOffscreenSurface_Cocos2dx;
- if (_renderBuffer)
- {// 描画ターゲット作成
-
-#if (CC_TARGET_PLATFORM == CC_PLATFORM_MAC)
- // Retina対策でこっちからとる
- GLViewImpl *glimpl = (GLViewImpl *)Director::getInstance()->getOpenGLView();
- glfwGetFramebufferSize(glimpl->getWindow(), &width, &height);
-#endif
-
- // モデル描画キャンバス
- _renderBuffer->CreateOffscreenSurface(static_cast(width), static_cast(height));
- }
-
-#ifdef CSM_TARGET_ANDROID_ES2
- char *exts = (char*)backend::Device::getInstance()->getDeviceInfo()->getExtension();
- if(strstr(exts, "GL_NV_shader_framebuffer_fetch ")){
- Rendering::CubismRenderer_Cocos2dx::SetExtShaderMode( true , true );
- }
-#endif
-
- ChangeScene(_sceneIndex);
-}
-
-LAppLive2DManager::~LAppLive2DManager()
-{
- if (_renderBuffer)
- {
- _renderBuffer->DestroyOffscreenSurface();
- delete _renderBuffer;
- _renderBuffer = NULL;
- }
- delete _sprite;
- _sprite = NULL;
-
- ReleaseAllModel();
-
- CubismFramework::Dispose();
-}
-
-void LAppLive2DManager::ReleaseAllModel()
-{
- for (csmUint32 i = 0; i < _models.GetSize(); i++)
- {
- delete _models[i];
- }
-
- _models.Clear();
-}
-
-LAppModel* LAppLive2DManager::GetModel(csmUint32 no) const
-{
- if(no < _models.GetSize())
- {
- return _models[no];
- }
-
- return NULL;
-}
-
-csmUint32 LAppLive2DManager::GetModelCount() const
-{
- return _models.GetSize();
-}
-
-void LAppLive2DManager::RecreateRenderer() const
-{
- Rendering::CubismRenderer::StaticRelease();
-
- for (csmUint32 i = 0; i < _models.GetSize(); i++)
- {
- LAppModel* model = GetModel(i);
- model->ReloadRnederer();
- }
-}
-
-void LAppLive2DManager::SetViewMatrix(Csm::CubismMatrix44* matrix)
-{
- _viewMatrix = matrix;
-}
-
-void LAppLive2DManager::OnDrag(csmFloat32 x, csmFloat32 y) const
-{
- for (csmUint32 i = 0; i < _models.GetSize(); i++)
- {
- LAppModel* model = GetModel(i);
-
- model->SetDragging(x, y);
- }
-}
-
-void LAppLive2DManager::OnTap(csmFloat32 x, csmFloat32 y)
-{
- if (DebugLogEnable) LAppPal::PrintLogLn("[APP]tap point: {x:%.2f y:%.2f}", x, y);
-
- for (csmUint32 i = 0; i < _models.GetSize(); i++)
- {
- if (_models[i]->HitTest(HitAreaNameHead, x, y))
- {
- if (DebugLogEnable) LAppPal::PrintLogLn("[APP]hit area: [%s]", HitAreaNameHead);
- _models[i]->SetRandomExpression();
- }
- else if (_models[i]->HitTest(HitAreaNameBody, x, y))
- {
- if (DebugLogEnable) LAppPal::PrintLogLn("[APP]hit area: [%s]", HitAreaNameBody);
- _models[i]->StartRandomMotion(MotionGroupTapBody, PriorityNormal, FinishedMotion);
- }
- }
-}
-
-void LAppLive2DManager::OnUpdate(Csm::Rendering::CubismCommandBuffer_Cocos2dx* commandBuffer) const
-{
- Director* director = Director::getInstance();
- Size window = director->getWinSize();
-
- Csm::Rendering::CubismRenderer_Cocos2dx::StartFrame(commandBuffer);
-
- for (csmUint32 i = 0; i < _models.GetSize(); ++i)
- {
- CubismMatrix44 projection;
- LAppModel* model = GetModel(i);
-
- if (model->GetModel() == NULL)
- {
- LAppPal::PrintLogLn("Failed to model->GetModel().");
- continue;
- }
-
- if (model->GetModel()->GetCanvasWidth() > 1.0f && window.width < window.height)
- {
- // 横に長いモデルを縦長ウィンドウに表示する際モデルの横サイズでscaleを算出する
- model->GetModelMatrix()->SetWidth(2.0f);
- projection.Scale(1.0f, static_cast(window.width) / static_cast(window.height));
- }
- else
- {
- projection.Scale(static_cast(window.height) / static_cast(window.width), 1.0f);
- }
-
- // 必要があればここで乗算
- if (_viewMatrix != NULL)
- {
- projection.MultiplyByMatrix(_viewMatrix);
- }
-
- if (_renderTarget == SelectTarget_ViewFrameBuffer && _renderBuffer && _sprite)
- {// レンダリングターゲット使いまわしの場合
- // レンダリング開始
- _renderBuffer->BeginDraw(commandBuffer, NULL);
- _renderBuffer->Clear(commandBuffer, _clearColor[0], _clearColor[1], _clearColor[2], _clearColor[3]); // 背景クリアカラー
- }
-
- model->Update();
- model->Draw(commandBuffer, projection);///< 参照渡しなのでprojectionは変質する
-
- // 各モデルが持つ描画ターゲットをテクスチャとする場合
- if (_renderTarget == SelectTarget_ModelFrameBuffer)
- {
- // レンダリング先とスプライトを作成
- model->MakeRenderingTarget();
- // αを付ける
- float alpha = i < 1 ? 1.0f : model->GetOpacity(); // 片方のみ不透明度を取得できるようにする
- model->SetSpriteColor(1.0f, 1.0f, 1.0f, alpha);
- }
-
- if (_renderTarget == SelectTarget_ViewFrameBuffer && _renderBuffer && _sprite)
- {// レンダリングターゲット使いまわしの場合
- // レンダリング終了
- _renderBuffer->EndDraw(commandBuffer);
-
- float uvVertex[] =
- {
- 1.0f, 1.0f,
- 0.0f, 1.0f,
- 0.0f, 0.0f,
- 1.0f, 0.0f,
- };
-
- // program退避
- Csm::Rendering::CubismCommandBuffer_Cocos2dx* lastCommandBuffer = commandBuffer;
-
- _sprite->SetColor(1.0f, 1.0f, 1.0f, 0.25f + (float)i * 0.5f);
- _sprite->RenderImmidiate(commandBuffer, _renderBuffer->GetColorBuffer(), uvVertex);
-
- // 元に戻す
- commandBuffer = lastCommandBuffer;
- }
- }
-}
-
-void LAppLive2DManager::NextScene()
-{
- csmInt32 no = (_sceneIndex + 1) % GetModelDirSize();
- ChangeScene(no);
-}
-
-void LAppLive2DManager::ChangeScene(Csm::csmInt32 index)
-{
- _sceneIndex = index;
- if (DebugLogEnable) LAppPal::PrintLogLn("[APP]model index: %d", _sceneIndex);
-
- // ModelDir[]に保持したディレクトリ名から
- // model3.jsonのパスを決定する.
- // ディレクトリ名とmodel3.jsonの名前を一致させておくこと.
- const csmString& model = _modelDir[index];
-
- csmString dir(model);;
- dir.Append(1, '/');
-
- csmString modelJsonName(model);
- modelJsonName += ".model3.json";
-
- ReleaseAllModel();
- _models.PushBack(new LAppModel());
- _models[0]->LoadAssets(dir.GetRawString(), modelJsonName.GetRawString());
-
- /*
- * モデル半透明表示を行うサンプルを提示する。
- * ここでUSE_RENDER_TARGET、USE_MODEL_RENDER_TARGETが定義されている場合
- * 別のレンダリングターゲットにモデルを描画し、描画結果をテクスチャとして別のスプライトに張り付ける。
- */
- {
-#if defined(USE_RENDER_TARGET)
- // Live2DManagerの持つターゲットに描画を行う場合、こちらを選択
- _renderTarget = SelectTarget_ViewFrameBuffer;
-#elif defined(USE_MODEL_RENDER_TARGET)
- // 各LAppModelの持つターゲットに描画を行う場合、こちらを選択
- _renderTarget = SelectTarget_ModelFrameBuffer;
-#else
- // デフォルトのメインフレームバッファへレンダリングする(通常)
- _renderTarget = SelectTarget_None;
-#endif
-
-#if defined(USE_RENDER_TARGET) || defined(USE_MODEL_RENDER_TARGET)
- // モデル個別にαを付けるサンプルとして、もう1体モデルを作成し、少し位置をずらす
- _models.PushBack(new LAppModel());
- _models[1]->LoadAssets(dir.GetRawString(), modelJsonName.GetRawString());
- _models[1]->GetModelMatrix()->TranslateX(0.2f);
-#endif
-
- if(_renderTarget == SelectTarget_ModelFrameBuffer)
- {
- for(Csm::csmUint32 i=0;i<_models.GetSize(); i++)
- {
- // レンダリング先とスプライトを作成
- _models[i]->MakeRenderingTarget();
- // αを付ける
- LAppModel* model = _models[i];
- float alpha = i < 1 ? 1.0f : model->GetOpacity(); // 片方のみ不透明度を取得できるようにする
- _models[i]->SetSpriteColor(1.0f, 1.0f, 1.0f, alpha);
- }
- }
- }
-}
-
-void LAppLive2DManager::CreateShader()
-{
- const char* vertexShader =
- "attribute vec3 position;"
- "attribute vec2 uv;"
- "varying vec2 vuv;"
- "void main(void){"
-#if defined(CC_USE_METAL)
- " gl_Position = vec4(position.x, -position.y, position.z, 1.0);"
-#else
- " gl_Position = vec4(position, 1.0);"
-#endif
- " vuv = uv;"
- "}";
-
- const char* fragmentShader =
-#if (CC_TARGET_PLATFORM == CC_PLATFORM_ANDROID)
- "precision mediump float;"
-#endif
- "varying vec2 vuv;"
- "uniform sampler2D texture;"
- "uniform vec4 baseColor;"
- "void main(void){"
- " gl_FragColor = texture2D(texture, vuv) * baseColor;"
- " gl_FragColor = vec4(gl_FragColor.rgb * gl_FragColor.a, gl_FragColor.a);"
- "}";
-
- auto program = cocos2d::backend::Device::getInstance()->newProgram(vertexShader, fragmentShader);
- _program = program;
-
-}
-
-void LAppLive2DManager::SetUpModel()
-{
- _modelDir.Clear();
-
- // ResourcesPathの中にあるフォルダ名を全てクロールし、モデルが存在するフォルダを定義する。
- // フォルダはあるが同名の.model3.jsonが見つからなかった場合はリストに含めない。
-#if defined(CSM_TARGET_IOS) || defined(CSM_TARGET_MACOSX) || defined(__ANDROID__)
- LAppLive2DManagerInternal::SetUpModel(_modelDir);
-#else
- const csmString resourcePath(FileUtils::getInstance()->getDefaultResourceRootPath().c_str());
-#if defined(_WIN32)
- struct _finddata_t fdata;
- csmString crawlPath(resourcePath);
- crawlPath += "*.*";
-
- intptr_t fh = _findfirst(crawlPath.GetRawString(), &fdata);
- if (fh == -1) return;
-
- while (_findnext(fh, &fdata) == 0)
- {
- if ((fdata.attrib & _A_SUBDIR) && strcmp(fdata.name, "..") != 0)
- {
- // フォルダと同名の.model3.jsonがあるか探索する
- csmString modelName(fdata.name);
- csmString model3jsonPath(resourcePath);
- model3jsonPath += modelName;
- model3jsonPath.Append(1, '/');
- model3jsonPath += modelName;
- model3jsonPath += ".model3.json";
-
- struct _finddata_t fdata2;
- if (_findfirst(model3jsonPath.GetRawString(), &fdata2) != -1)
- {
- _modelDir.PushBack(csmString(fdata.name));
- }
- }
- }
-#else
- DIR* pDir = opendir(resourcePath.GetRawString());
- if (pDir == NULL) return;
-
- struct dirent* dirent;
- while ((dirent = readdir(pDir)) != NULL)
- {
- if ((dirent->d_type & DT_DIR) && strcmp(dirent->d_name, "..") != 0)
- {
- // フォルダと同名の.model3.jsonがあるか探索する
- csmString modelName(dirent->d_name);
- csmString modelPath(resourcePath);
- modelPath += modelName;
- modelPath.Append(1, '/');
-
- csmString model3jsonName(modelName);
- model3jsonName += ".model3.json";
-
- DIR* pDir2 = opendir(modelPath.GetRawString());
-
- struct dirent* dirent2;
- while ((dirent2 = readdir(pDir2)) != NULL)
- {
- if (strcmp(dirent2->d_name, model3jsonName.GetRawString()) == 0)
- {
- _modelDir.PushBack(csmString(dirent->d_name));
- }
- }
- closedir(pDir2);
- }
- }
- closedir(pDir);
-#endif
-#endif
- qsort(_modelDir.GetPtr(), _modelDir.GetSize(), sizeof(csmString), CompareCsmString);
-}
-
-Csm::csmVector LAppLive2DManager::GetModelDir() const
-{
- return _modelDir;
-}
-
-Csm::csmInt32 LAppLive2DManager::GetModelDirSize() const
-{
- return _modelDir.GetSize();
-}
-
-void LAppLive2DManager::SetRenderTargetClearColor(float r, float g, float b)
-{
- _clearColor[0] = r;
- _clearColor[1] = g;
- _clearColor[2] = b;
-}
diff --git a/Samples/Cocos2d-x/Demo/Classes/LAppLive2DManager.hpp b/Samples/Cocos2d-x/Demo/Classes/LAppLive2DManager.hpp
deleted file mode 100644
index 754ae7de..00000000
--- a/Samples/Cocos2d-x/Demo/Classes/LAppLive2DManager.hpp
+++ /dev/null
@@ -1,171 +0,0 @@
-/**
- * Copyright(c) Live2D Inc. All rights reserved.
- *
- * Use of this source code is governed by the Live2D Open Software license
- * that can be found at https://www.live2d.com/eula/live2d-open-software-license-agreement_en.html.
- */
-
-#pragma once
-
-#include
-#include