From a6dbeb029eed81ee7328b8935c46c338db7ddd05 Mon Sep 17 00:00:00 2001 From: halx99 Date: Thu, 28 Apr 2022 04:20:11 +0000 Subject: [PATCH] Committing genbindings changes [skip ci] --- .../auto/lua_cocos2dx_video_auto.cpp | 51 +++++++++++++++++++ .../auto/lua_cocos2dx_video_auto.hpp | 1 + 2 files changed, 52 insertions(+) diff --git a/extensions/scripting/lua-bindings/auto/lua_cocos2dx_video_auto.cpp b/extensions/scripting/lua-bindings/auto/lua_cocos2dx_video_auto.cpp index 76452d9a1e..379c22463d 100644 --- a/extensions/scripting/lua-bindings/auto/lua_cocos2dx_video_auto.cpp +++ b/extensions/scripting/lua-bindings/auto/lua_cocos2dx_video_auto.cpp @@ -338,6 +338,56 @@ int lua_cocos2dx_video_VideoPlayer_setFullScreenEnabled(lua_State* tolua_S) return 0; } +int lua_cocos2dx_video_VideoPlayer_setPlayRate(lua_State* tolua_S) +{ + int argc = 0; + cocos2d::ui::VideoPlayer* cobj = nullptr; + bool ok = true; + +#if COCOS2D_DEBUG >= 1 + tolua_Error tolua_err; +#endif + + +#if COCOS2D_DEBUG >= 1 + if (!tolua_isusertype(tolua_S,1,"ccui.VideoPlayer",0,&tolua_err)) goto tolua_lerror; +#endif + + cobj = (cocos2d::ui::VideoPlayer*)tolua_tousertype(tolua_S,1,0); + +#if COCOS2D_DEBUG >= 1 + if (!cobj) + { + tolua_error(tolua_S,"invalid 'cobj' in function 'lua_cocos2dx_video_VideoPlayer_setPlayRate'", nullptr); + return 0; + } +#endif + + argc = lua_gettop(tolua_S)-1; + if (argc == 1) + { + double arg0; + + ok &= luaval_to_number(tolua_S, 2,&arg0, "ccui.VideoPlayer:setPlayRate"); + if(!ok) + { + tolua_error(tolua_S,"invalid arguments in function 'lua_cocos2dx_video_VideoPlayer_setPlayRate'", nullptr); + return 0; + } + cobj->setPlayRate(arg0); + lua_settop(tolua_S, 1); + return 1; + } + luaL_error(tolua_S, "%s has wrong number of arguments: %d, was expecting %d \n", "ccui.VideoPlayer:setPlayRate",argc, 1); + return 0; + +#if COCOS2D_DEBUG >= 1 + tolua_lerror: + tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_video_VideoPlayer_setPlayRate'.",&tolua_err); +#endif + + return 0; +} int lua_cocos2dx_video_VideoPlayer_setFileName(lua_State* tolua_S) { int argc = 0; @@ -967,6 +1017,7 @@ int lua_register_cocos2dx_video_VideoPlayer(lua_State* tolua_S) tolua_function(tolua_S,"setKeepAspectRatioEnabled",lua_cocos2dx_video_VideoPlayer_setKeepAspectRatioEnabled); tolua_function(tolua_S,"stop",lua_cocos2dx_video_VideoPlayer_stop); tolua_function(tolua_S,"setFullScreenEnabled",lua_cocos2dx_video_VideoPlayer_setFullScreenEnabled); + tolua_function(tolua_S,"setPlayRate",lua_cocos2dx_video_VideoPlayer_setPlayRate); tolua_function(tolua_S,"setFileName",lua_cocos2dx_video_VideoPlayer_setFileName); tolua_function(tolua_S,"setURL",lua_cocos2dx_video_VideoPlayer_setURL); tolua_function(tolua_S,"setStyle",lua_cocos2dx_video_VideoPlayer_setStyle); diff --git a/extensions/scripting/lua-bindings/auto/lua_cocos2dx_video_auto.hpp b/extensions/scripting/lua-bindings/auto/lua_cocos2dx_video_auto.hpp index 31ac70ecb2..a6c81d5ffe 100644 --- a/extensions/scripting/lua-bindings/auto/lua_cocos2dx_video_auto.hpp +++ b/extensions/scripting/lua-bindings/auto/lua_cocos2dx_video_auto.hpp @@ -31,6 +31,7 @@ int register_all_cocos2dx_video(lua_State* tolua_S); + #endif // __cocos2dx_video_h__