我们有一个产品官网,目前在百度app上日常进行直播,我们希望在我们原本的官网中,同步直播的画面内容;需要做一个嵌入直播插件,来同时实现我们的直播同步;在官网同步的直播中,可以以浮窗的方式来呈现,或者有更优秀的方案也同样可以行
Success story sharing
200元找人实现
C++的LuaBridge库 有例子 只需要实现几个接口
lua_State* L = luaL_newstate(); // 创建一个新的 Lua 状态
luaL_openlibs(L); // 加载 Lua 标准库
luabridge::LuaRef ret = luabridge::LuaRef::fromStack(L, -1);
std::cout << "序号: " << ret["序号"].cast
luabridge::LuaRef contents = ret["内容"];
for (int i = 0; i < contents.length(); ++i) {
luabridge::LuaRef item = contents[i + 1];
if (item.isNil()) {
std::cerr << "Item at index " << (i + 1) << " does not exist." << std::endl;
continue;
}
std::cout << "内容 " << (i + 1) << ": 名称 = " << item["名称"].caststd::string() << ", x = " << item["x"].cast
}