static int GetNativePixels32(IntPtr L)
    {
        try
        {
            int count = LuaDLL.lua_gettop(L);

            if (count == 2 && TypeChecker.CheckTypes(L, 1, typeof(UnityEngine.Texture2D), typeof(System.IntPtr)))
            {
                UnityEngine.Texture2D obj  = (UnityEngine.Texture2D)ToLua.ToObject(L, 1);
                System.IntPtr         arg0 = (System.IntPtr)LuaDLL.lua_touserdata(L, 2);
                obj.GetNativePixels32(arg0);
                return(0);
            }
            else if (count == 3 && TypeChecker.CheckTypes(L, 1, typeof(UnityEngine.Texture2D), typeof(System.IntPtr), typeof(int)))
            {
                UnityEngine.Texture2D obj  = (UnityEngine.Texture2D)ToLua.ToObject(L, 1);
                System.IntPtr         arg0 = (System.IntPtr)LuaDLL.lua_touserdata(L, 2);
                int arg1 = (int)LuaDLL.lua_tonumber(L, 3);
                obj.GetNativePixels32(arg0, arg1);
                return(0);
            }
            else
            {
                return(LuaDLL.luaL_throw(L, "invalid arguments to method: UnityEngine.Texture2D.GetNativePixels32"));
            }
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e));
        }
    }