cocos2dx-bullet物理引擎编译的一个问题: Argument value 10880 is outside the valid range

简介: cocos2dx-bullet物理引擎编译的一个问题: Argument value 10880 is outside the valid range

bullet物理引擎位置在: cocos2d-x/external/bullet

在xcode上编译会遇到一个问题:

Argument value 10880 is outside the valid range [0, 255]

解决办法是:

修改源文件: cocos2d-x/external/bullet/include/bullet/LinearMath/btVector3.h

#define BT_SHUFFLE(x,y,z,w) ((w)<<6 | (z)<<4 | (y)<<2 | (x))
复制代码

为:

#define BT_SHUFFLE(x, y, z, w) (((w) << 6 | (z) << 4 | (y) << 2 | (x)) & 0xff)
复制代码

官方的issue有关于这个问题的讨论,在bullet的官方仓库里面也是这样的修改至于原因,没有必要深究了



目录
相关文章
|
7月前
|
自然语言处理 编译器 C语言
【C++ 20 新特性】参数包初始化捕获的魅力 (“pack init-capture“ in C++20: A Deep Dive)
【C++ 20 新特性】参数包初始化捕获的魅力 (“pack init-capture“ in C++20: A Deep Dive)
101 0
|
计算机视觉
YOLO环境搭建报错:module 'cv2' has no attribute 'gapi wip_ gst GStreamerPipeline'
报错:module 'cv2' has no attribute 'gapi wip_ gst GStreamerPipeline'
2458 0
|
7月前
|
Swift iOS开发 MacOS
解决新版xcode下swift .infinity报Invalid frame dimension (negative or non-finite)错误
解决新版xcode下swift .infinity报Invalid frame dimension (negative or non-finite)错误
211 1
|
6月前
|
消息中间件 监控 Serverless
函数计算操作报错合集之显示报错:RecursionError: maximum recursion depth exceeded while calling a Python object,该如何解决
在使用函数计算服务(如阿里云函数计算)时,用户可能会遇到多种错误场景。以下是一些常见的操作报错及其可能的原因和解决方法,包括但不限于:1. 函数部署失败、2. 函数执行超时、3. 资源不足错误、4. 权限与访问错误、5. 依赖问题、6. 网络配置错误、7. 触发器配置错误、8. 日志与监控问题。
144 0
|
7月前
MTK在编译10A的target时报错:make: *** [mmi_feature_check]
MTK在编译10A的target时报错:make: *** [mmi_feature_check]
27 0
|
iOS开发
Xcode消除警告:-1: The iOS Simulator deployment target is set to 6.0, but the range of supported deplo...
Xcode消除警告:-1: The iOS Simulator deployment target is set to 6.0, but the range of supported deplo...
163 0
Xcode消除警告:-1: The iOS Simulator deployment target is set to 6.0, but the range of supported deplo...
|
Android开发
【错误记录】Tinker 热修复示例运行报错 ( patch receive fail: /storage/emulated/0/patch_signed_7zip.apk, code: -2)
【错误记录】Tinker 热修复示例运行报错 ( patch receive fail: /storage/emulated/0/patch_signed_7zip.apk, code: -2)
477 0
【错误记录】Tinker 热修复示例运行报错 ( patch receive fail: /storage/emulated/0/patch_signed_7zip.apk, code: -2)
成功解决random.py"之TypeError: 'range' object does not support item assignment 解决问题
成功解决random.py"之TypeError: 'range' object does not support item assignment