Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
大多数人似乎都想走另一条路。我想知道是否有一种将定点转换为浮点的快速方法,最好是使用 SSE2。直接的 C 或 C++ 甚至 asm 都可以。
只要你有一个双精度 FPU,这很容易:有 53 位有效数字。SSE2 具有双精度。
float conv_fx( int32_t fx ) { double fp = fx; fp = fp / double(1<<16); // multiplication by a constant return fp; }