CubismNativeFramework but in Lua.
Provides both CubismNativeFramework-like API and Live2LOVE-compatible API.
C++ and Lua are completely different thing. Here are some differences between CubismNativeFramework and lua-live2d-framework:
-
lua-live2d-framework uses
lowerCamelCase
naming while CubismNativeFramework usesUpperCamelCase
. -
CubismId
andCubismIdHandle
does not exist. Lua string is used instead. -
Anything that uses numeric index ID are assumed to use 1-based indexing.
-
There's no
Delete
function. Lua has automatic garbage collection. -
CubismModel::GetDrawableVertexUvs
isModel:getDrawableVertexUVs
(notice the uppercaseV
) -
Model:getDrawableBlendMode
returns 2 strings, which maps to LOVE BlendMode and BlendAlphaMode respectively. -
CubismModel::GetModel
returns backend-specific model object. -
CubismMoc
equivalent class does not exist. Moc data string is passed directly toModel
object constructor. -
In
MotionJson
(CubismMotionJson
equivalent), anyIsExist*
method is replaced byhas*
method instead. -
All
is*
orhas*
method doesn't accept additional value to set the value. Useset*
function respectively to set it. -
Addition of
Model:getAllParameterValue
which returns 4 values: current parameter value, min, max, and default value.
Here's list of 3rd-party libraries used:
Most portion of the code falls into Live2D Open Software License which is incompatible with GPL and its friends. However, some part of the program like backend and third-party libraries are licensed under permissive license. See each file for more information.
Here are list of files (exclude 3p
folder) which falls under MIT license:
-
init.lua
-
Any files at
backend
folder. -
math/Math.lua
-
Live2LOVE.lua
Anything not stated, with exception of dummy.lua
falls into Live2D Open Software License.
This thread also worth checking: https://community.live2d.com/discussion/666/re-implementing-cubismnativeframework-is-it-allowed