mirror of https://github.com/axmolengine/axmol.git
[ci skip][AUTO]: updating luabinding & jsbinding automatically
This commit is contained in:
parent
cd4d8b7880
commit
7a73c65208
|
@ -19732,9 +19732,17 @@ GLProgram : function (
|
|||
cc.ShaderCache = {
|
||||
|
||||
/**
|
||||
* @method reloadDefaultGLPrograms
|
||||
* @method loadDefaultGLPrograms
|
||||
*/
|
||||
reloadDefaultGLPrograms : function (
|
||||
loadDefaultGLPrograms : function (
|
||||
)
|
||||
{
|
||||
},
|
||||
|
||||
/**
|
||||
* @method reloadDefaultGLProgramsRelativeToLights
|
||||
*/
|
||||
reloadDefaultGLProgramsRelativeToLights : function (
|
||||
)
|
||||
{
|
||||
},
|
||||
|
@ -19751,6 +19759,14 @@ str
|
|||
{
|
||||
},
|
||||
|
||||
/**
|
||||
* @method reloadDefaultGLPrograms
|
||||
*/
|
||||
reloadDefaultGLPrograms : function (
|
||||
)
|
||||
{
|
||||
},
|
||||
|
||||
/**
|
||||
* @method getGLProgram
|
||||
* @param {String} arg0
|
||||
|
@ -19763,14 +19779,6 @@ str
|
|||
return cc.GLProgram;
|
||||
},
|
||||
|
||||
/**
|
||||
* @method loadDefaultGLPrograms
|
||||
*/
|
||||
loadDefaultGLPrograms : function (
|
||||
)
|
||||
{
|
||||
},
|
||||
|
||||
/**
|
||||
* @method destroyInstance
|
||||
*/
|
||||
|
|
|
@ -60822,20 +60822,36 @@ void js_register_cocos2dx_GLProgram(JSContext *cx, JS::HandleObject global) {
|
|||
JSClass *jsb_cocos2d_GLProgramCache_class;
|
||||
JSObject *jsb_cocos2d_GLProgramCache_prototype;
|
||||
|
||||
bool js_cocos2dx_GLProgramCache_reloadDefaultGLPrograms(JSContext *cx, uint32_t argc, jsval *vp)
|
||||
bool js_cocos2dx_GLProgramCache_loadDefaultGLPrograms(JSContext *cx, uint32_t argc, jsval *vp)
|
||||
{
|
||||
JS::CallArgs args = JS::CallArgsFromVp(argc, vp);
|
||||
JS::RootedObject obj(cx, args.thisv().toObjectOrNull());
|
||||
js_proxy_t *proxy = jsb_get_js_proxy(obj);
|
||||
cocos2d::GLProgramCache* cobj = (cocos2d::GLProgramCache *)(proxy ? proxy->ptr : NULL);
|
||||
JSB_PRECONDITION2( cobj, cx, false, "js_cocos2dx_GLProgramCache_reloadDefaultGLPrograms : Invalid Native Object");
|
||||
JSB_PRECONDITION2( cobj, cx, false, "js_cocos2dx_GLProgramCache_loadDefaultGLPrograms : Invalid Native Object");
|
||||
if (argc == 0) {
|
||||
cobj->reloadDefaultGLPrograms();
|
||||
cobj->loadDefaultGLPrograms();
|
||||
args.rval().setUndefined();
|
||||
return true;
|
||||
}
|
||||
|
||||
JS_ReportError(cx, "js_cocos2dx_GLProgramCache_reloadDefaultGLPrograms : wrong number of arguments: %d, was expecting %d", argc, 0);
|
||||
JS_ReportError(cx, "js_cocos2dx_GLProgramCache_loadDefaultGLPrograms : wrong number of arguments: %d, was expecting %d", argc, 0);
|
||||
return false;
|
||||
}
|
||||
bool js_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights(JSContext *cx, uint32_t argc, jsval *vp)
|
||||
{
|
||||
JS::CallArgs args = JS::CallArgsFromVp(argc, vp);
|
||||
JS::RootedObject obj(cx, args.thisv().toObjectOrNull());
|
||||
js_proxy_t *proxy = jsb_get_js_proxy(obj);
|
||||
cocos2d::GLProgramCache* cobj = (cocos2d::GLProgramCache *)(proxy ? proxy->ptr : NULL);
|
||||
JSB_PRECONDITION2( cobj, cx, false, "js_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights : Invalid Native Object");
|
||||
if (argc == 0) {
|
||||
cobj->reloadDefaultGLProgramsRelativeToLights();
|
||||
args.rval().setUndefined();
|
||||
return true;
|
||||
}
|
||||
|
||||
JS_ReportError(cx, "js_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights : wrong number of arguments: %d, was expecting %d", argc, 0);
|
||||
return false;
|
||||
}
|
||||
bool js_cocos2dx_GLProgramCache_addGLProgram(JSContext *cx, uint32_t argc, jsval *vp)
|
||||
|
@ -60868,6 +60884,22 @@ bool js_cocos2dx_GLProgramCache_addGLProgram(JSContext *cx, uint32_t argc, jsval
|
|||
JS_ReportError(cx, "js_cocos2dx_GLProgramCache_addGLProgram : wrong number of arguments: %d, was expecting %d", argc, 2);
|
||||
return false;
|
||||
}
|
||||
bool js_cocos2dx_GLProgramCache_reloadDefaultGLPrograms(JSContext *cx, uint32_t argc, jsval *vp)
|
||||
{
|
||||
JS::CallArgs args = JS::CallArgsFromVp(argc, vp);
|
||||
JS::RootedObject obj(cx, args.thisv().toObjectOrNull());
|
||||
js_proxy_t *proxy = jsb_get_js_proxy(obj);
|
||||
cocos2d::GLProgramCache* cobj = (cocos2d::GLProgramCache *)(proxy ? proxy->ptr : NULL);
|
||||
JSB_PRECONDITION2( cobj, cx, false, "js_cocos2dx_GLProgramCache_reloadDefaultGLPrograms : Invalid Native Object");
|
||||
if (argc == 0) {
|
||||
cobj->reloadDefaultGLPrograms();
|
||||
args.rval().setUndefined();
|
||||
return true;
|
||||
}
|
||||
|
||||
JS_ReportError(cx, "js_cocos2dx_GLProgramCache_reloadDefaultGLPrograms : wrong number of arguments: %d, was expecting %d", argc, 0);
|
||||
return false;
|
||||
}
|
||||
bool js_cocos2dx_GLProgramCache_getGLProgram(JSContext *cx, uint32_t argc, jsval *vp)
|
||||
{
|
||||
JS::CallArgs args = JS::CallArgsFromVp(argc, vp);
|
||||
|
@ -60897,22 +60929,6 @@ bool js_cocos2dx_GLProgramCache_getGLProgram(JSContext *cx, uint32_t argc, jsval
|
|||
JS_ReportError(cx, "js_cocos2dx_GLProgramCache_getGLProgram : wrong number of arguments: %d, was expecting %d", argc, 1);
|
||||
return false;
|
||||
}
|
||||
bool js_cocos2dx_GLProgramCache_loadDefaultGLPrograms(JSContext *cx, uint32_t argc, jsval *vp)
|
||||
{
|
||||
JS::CallArgs args = JS::CallArgsFromVp(argc, vp);
|
||||
JS::RootedObject obj(cx, args.thisv().toObjectOrNull());
|
||||
js_proxy_t *proxy = jsb_get_js_proxy(obj);
|
||||
cocos2d::GLProgramCache* cobj = (cocos2d::GLProgramCache *)(proxy ? proxy->ptr : NULL);
|
||||
JSB_PRECONDITION2( cobj, cx, false, "js_cocos2dx_GLProgramCache_loadDefaultGLPrograms : Invalid Native Object");
|
||||
if (argc == 0) {
|
||||
cobj->loadDefaultGLPrograms();
|
||||
args.rval().setUndefined();
|
||||
return true;
|
||||
}
|
||||
|
||||
JS_ReportError(cx, "js_cocos2dx_GLProgramCache_loadDefaultGLPrograms : wrong number of arguments: %d, was expecting %d", argc, 0);
|
||||
return false;
|
||||
}
|
||||
bool js_cocos2dx_GLProgramCache_destroyInstance(JSContext *cx, uint32_t argc, jsval *vp)
|
||||
{
|
||||
JS::CallArgs args = JS::CallArgsFromVp(argc, vp);
|
||||
|
@ -61000,10 +61016,11 @@ void js_register_cocos2dx_GLProgramCache(JSContext *cx, JS::HandleObject global)
|
|||
};
|
||||
|
||||
static JSFunctionSpec funcs[] = {
|
||||
JS_FN("reloadDefaultShaders", js_cocos2dx_GLProgramCache_reloadDefaultGLPrograms, 0, JSPROP_PERMANENT | JSPROP_ENUMERATE),
|
||||
JS_FN("addProgram", js_cocos2dx_GLProgramCache_addGLProgram, 2, JSPROP_PERMANENT | JSPROP_ENUMERATE),
|
||||
JS_FN("getProgram", js_cocos2dx_GLProgramCache_getGLProgram, 1, JSPROP_PERMANENT | JSPROP_ENUMERATE),
|
||||
JS_FN("loadDefaultShaders", js_cocos2dx_GLProgramCache_loadDefaultGLPrograms, 0, JSPROP_PERMANENT | JSPROP_ENUMERATE),
|
||||
JS_FN("reloadDefaultGLProgramsRelativeToLights", js_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights, 0, JSPROP_PERMANENT | JSPROP_ENUMERATE),
|
||||
JS_FN("addProgram", js_cocos2dx_GLProgramCache_addGLProgram, 2, JSPROP_PERMANENT | JSPROP_ENUMERATE),
|
||||
JS_FN("reloadDefaultShaders", js_cocos2dx_GLProgramCache_reloadDefaultGLPrograms, 0, JSPROP_PERMANENT | JSPROP_ENUMERATE),
|
||||
JS_FN("getProgram", js_cocos2dx_GLProgramCache_getGLProgram, 1, JSPROP_PERMANENT | JSPROP_ENUMERATE),
|
||||
JS_FS_END
|
||||
};
|
||||
|
||||
|
|
|
@ -3537,10 +3537,11 @@ bool js_cocos2dx_GLProgramCache_constructor(JSContext *cx, uint32_t argc, jsval
|
|||
void js_cocos2dx_GLProgramCache_finalize(JSContext *cx, JSObject *obj);
|
||||
void js_register_cocos2dx_GLProgramCache(JSContext *cx, JS::HandleObject global);
|
||||
void register_all_cocos2dx(JSContext* cx, JS::HandleObject obj);
|
||||
bool js_cocos2dx_GLProgramCache_reloadDefaultGLPrograms(JSContext *cx, uint32_t argc, jsval *vp);
|
||||
bool js_cocos2dx_GLProgramCache_addGLProgram(JSContext *cx, uint32_t argc, jsval *vp);
|
||||
bool js_cocos2dx_GLProgramCache_getGLProgram(JSContext *cx, uint32_t argc, jsval *vp);
|
||||
bool js_cocos2dx_GLProgramCache_loadDefaultGLPrograms(JSContext *cx, uint32_t argc, jsval *vp);
|
||||
bool js_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights(JSContext *cx, uint32_t argc, jsval *vp);
|
||||
bool js_cocos2dx_GLProgramCache_addGLProgram(JSContext *cx, uint32_t argc, jsval *vp);
|
||||
bool js_cocos2dx_GLProgramCache_reloadDefaultGLPrograms(JSContext *cx, uint32_t argc, jsval *vp);
|
||||
bool js_cocos2dx_GLProgramCache_getGLProgram(JSContext *cx, uint32_t argc, jsval *vp);
|
||||
bool js_cocos2dx_GLProgramCache_destroyInstance(JSContext *cx, uint32_t argc, jsval *vp);
|
||||
bool js_cocos2dx_GLProgramCache_getInstance(JSContext *cx, uint32_t argc, jsval *vp);
|
||||
bool js_cocos2dx_GLProgramCache_GLProgramCache(JSContext *cx, uint32_t argc, jsval *vp);
|
||||
|
|
|
@ -4,6 +4,12 @@
|
|||
-- @extend Ref
|
||||
-- @parent_module cc
|
||||
|
||||
--------------------------------
|
||||
-- reload default programs these are relative to light
|
||||
-- @function [parent=#GLProgramCache] reloadDefaultGLProgramsRelativeToLights
|
||||
-- @param self
|
||||
-- @return GLProgramCache#GLProgramCache self (return value: cc.GLProgramCache)
|
||||
|
||||
--------------------------------
|
||||
-- adds a GLProgram to the cache for a given name
|
||||
-- @function [parent=#GLProgramCache] addGLProgram
|
||||
|
@ -12,13 +18,6 @@
|
|||
-- @param #string key
|
||||
-- @return GLProgramCache#GLProgramCache self (return value: cc.GLProgramCache)
|
||||
|
||||
--------------------------------
|
||||
-- returns a GL program for a given key
|
||||
-- @function [parent=#GLProgramCache] getGLProgram
|
||||
-- @param self
|
||||
-- @param #string key
|
||||
-- @return GLProgram#GLProgram ret (return value: cc.GLProgram)
|
||||
|
||||
--------------------------------
|
||||
-- reload the default shaders
|
||||
-- @function [parent=#GLProgramCache] reloadDefaultGLPrograms
|
||||
|
@ -31,6 +30,13 @@
|
|||
-- @param self
|
||||
-- @return GLProgramCache#GLProgramCache self (return value: cc.GLProgramCache)
|
||||
|
||||
--------------------------------
|
||||
-- returns a GL program for a given key
|
||||
-- @function [parent=#GLProgramCache] getGLProgram
|
||||
-- @param self
|
||||
-- @param #string key
|
||||
-- @return GLProgram#GLProgram ret (return value: cc.GLProgram)
|
||||
|
||||
--------------------------------
|
||||
-- purges the cache. It releases the retained instance.
|
||||
-- @function [parent=#GLProgramCache] destroyInstance
|
||||
|
|
|
@ -81834,6 +81834,53 @@ int lua_register_cocos2dx_GLProgram(lua_State* tolua_S)
|
|||
return 1;
|
||||
}
|
||||
|
||||
int lua_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights(lua_State* tolua_S)
|
||||
{
|
||||
int argc = 0;
|
||||
cocos2d::GLProgramCache* cobj = nullptr;
|
||||
bool ok = true;
|
||||
|
||||
#if COCOS2D_DEBUG >= 1
|
||||
tolua_Error tolua_err;
|
||||
#endif
|
||||
|
||||
|
||||
#if COCOS2D_DEBUG >= 1
|
||||
if (!tolua_isusertype(tolua_S,1,"cc.GLProgramCache",0,&tolua_err)) goto tolua_lerror;
|
||||
#endif
|
||||
|
||||
cobj = (cocos2d::GLProgramCache*)tolua_tousertype(tolua_S,1,0);
|
||||
|
||||
#if COCOS2D_DEBUG >= 1
|
||||
if (!cobj)
|
||||
{
|
||||
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights'", nullptr);
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
argc = lua_gettop(tolua_S)-1;
|
||||
if (argc == 0)
|
||||
{
|
||||
if(!ok)
|
||||
{
|
||||
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights'", nullptr);
|
||||
return 0;
|
||||
}
|
||||
cobj->reloadDefaultGLProgramsRelativeToLights();
|
||||
lua_settop(tolua_S, 1);
|
||||
return 1;
|
||||
}
|
||||
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramCache:reloadDefaultGLProgramsRelativeToLights",argc, 0);
|
||||
return 0;
|
||||
|
||||
#if COCOS2D_DEBUG >= 1
|
||||
tolua_lerror:
|
||||
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights'.",&tolua_err);
|
||||
#endif
|
||||
|
||||
return 0;
|
||||
}
|
||||
int lua_cocos2dx_GLProgramCache_addGLProgram(lua_State* tolua_S)
|
||||
{
|
||||
int argc = 0;
|
||||
|
@ -81887,56 +81934,6 @@ int lua_cocos2dx_GLProgramCache_addGLProgram(lua_State* tolua_S)
|
|||
|
||||
return 0;
|
||||
}
|
||||
int lua_cocos2dx_GLProgramCache_getGLProgram(lua_State* tolua_S)
|
||||
{
|
||||
int argc = 0;
|
||||
cocos2d::GLProgramCache* cobj = nullptr;
|
||||
bool ok = true;
|
||||
|
||||
#if COCOS2D_DEBUG >= 1
|
||||
tolua_Error tolua_err;
|
||||
#endif
|
||||
|
||||
|
||||
#if COCOS2D_DEBUG >= 1
|
||||
if (!tolua_isusertype(tolua_S,1,"cc.GLProgramCache",0,&tolua_err)) goto tolua_lerror;
|
||||
#endif
|
||||
|
||||
cobj = (cocos2d::GLProgramCache*)tolua_tousertype(tolua_S,1,0);
|
||||
|
||||
#if COCOS2D_DEBUG >= 1
|
||||
if (!cobj)
|
||||
{
|
||||
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramCache_getGLProgram'", nullptr);
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
argc = lua_gettop(tolua_S)-1;
|
||||
if (argc == 1)
|
||||
{
|
||||
std::string arg0;
|
||||
|
||||
ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramCache:getGLProgram");
|
||||
if(!ok)
|
||||
{
|
||||
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramCache_getGLProgram'", nullptr);
|
||||
return 0;
|
||||
}
|
||||
cocos2d::GLProgram* ret = cobj->getGLProgram(arg0);
|
||||
object_to_luaval<cocos2d::GLProgram>(tolua_S, "cc.GLProgram",(cocos2d::GLProgram*)ret);
|
||||
return 1;
|
||||
}
|
||||
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramCache:getGLProgram",argc, 1);
|
||||
return 0;
|
||||
|
||||
#if COCOS2D_DEBUG >= 1
|
||||
tolua_lerror:
|
||||
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramCache_getGLProgram'.",&tolua_err);
|
||||
#endif
|
||||
|
||||
return 0;
|
||||
}
|
||||
int lua_cocos2dx_GLProgramCache_reloadDefaultGLPrograms(lua_State* tolua_S)
|
||||
{
|
||||
int argc = 0;
|
||||
|
@ -82031,6 +82028,56 @@ int lua_cocos2dx_GLProgramCache_loadDefaultGLPrograms(lua_State* tolua_S)
|
|||
|
||||
return 0;
|
||||
}
|
||||
int lua_cocos2dx_GLProgramCache_getGLProgram(lua_State* tolua_S)
|
||||
{
|
||||
int argc = 0;
|
||||
cocos2d::GLProgramCache* cobj = nullptr;
|
||||
bool ok = true;
|
||||
|
||||
#if COCOS2D_DEBUG >= 1
|
||||
tolua_Error tolua_err;
|
||||
#endif
|
||||
|
||||
|
||||
#if COCOS2D_DEBUG >= 1
|
||||
if (!tolua_isusertype(tolua_S,1,"cc.GLProgramCache",0,&tolua_err)) goto tolua_lerror;
|
||||
#endif
|
||||
|
||||
cobj = (cocos2d::GLProgramCache*)tolua_tousertype(tolua_S,1,0);
|
||||
|
||||
#if COCOS2D_DEBUG >= 1
|
||||
if (!cobj)
|
||||
{
|
||||
tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_GLProgramCache_getGLProgram'", nullptr);
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
argc = lua_gettop(tolua_S)-1;
|
||||
if (argc == 1)
|
||||
{
|
||||
std::string arg0;
|
||||
|
||||
ok &= luaval_to_std_string(tolua_S, 2,&arg0, "cc.GLProgramCache:getGLProgram");
|
||||
if(!ok)
|
||||
{
|
||||
tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_GLProgramCache_getGLProgram'", nullptr);
|
||||
return 0;
|
||||
}
|
||||
cocos2d::GLProgram* ret = cobj->getGLProgram(arg0);
|
||||
object_to_luaval<cocos2d::GLProgram>(tolua_S, "cc.GLProgram",(cocos2d::GLProgram*)ret);
|
||||
return 1;
|
||||
}
|
||||
luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "cc.GLProgramCache:getGLProgram",argc, 1);
|
||||
return 0;
|
||||
|
||||
#if COCOS2D_DEBUG >= 1
|
||||
tolua_lerror:
|
||||
tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_GLProgramCache_getGLProgram'.",&tolua_err);
|
||||
#endif
|
||||
|
||||
return 0;
|
||||
}
|
||||
int lua_cocos2dx_GLProgramCache_destroyInstance(lua_State* tolua_S)
|
||||
{
|
||||
int argc = 0;
|
||||
|
@ -82149,10 +82196,11 @@ int lua_register_cocos2dx_GLProgramCache(lua_State* tolua_S)
|
|||
|
||||
tolua_beginmodule(tolua_S,"GLProgramCache");
|
||||
tolua_function(tolua_S,"new",lua_cocos2dx_GLProgramCache_constructor);
|
||||
tolua_function(tolua_S,"reloadDefaultGLProgramsRelativeToLights",lua_cocos2dx_GLProgramCache_reloadDefaultGLProgramsRelativeToLights);
|
||||
tolua_function(tolua_S,"addGLProgram",lua_cocos2dx_GLProgramCache_addGLProgram);
|
||||
tolua_function(tolua_S,"getGLProgram",lua_cocos2dx_GLProgramCache_getGLProgram);
|
||||
tolua_function(tolua_S,"reloadDefaultGLPrograms",lua_cocos2dx_GLProgramCache_reloadDefaultGLPrograms);
|
||||
tolua_function(tolua_S,"loadDefaultGLPrograms",lua_cocos2dx_GLProgramCache_loadDefaultGLPrograms);
|
||||
tolua_function(tolua_S,"getGLProgram",lua_cocos2dx_GLProgramCache_getGLProgram);
|
||||
tolua_function(tolua_S,"destroyInstance", lua_cocos2dx_GLProgramCache_destroyInstance);
|
||||
tolua_function(tolua_S,"getInstance", lua_cocos2dx_GLProgramCache_getInstance);
|
||||
tolua_endmodule(tolua_S);
|
||||
|
|
|
@ -2079,6 +2079,7 @@ int register_all_cocos2dx(lua_State* tolua_S);
|
|||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#endif // __cocos2dx_h__
|
||||
|
|
Loading…
Reference in New Issue