Can't define the matrix_double3x3 in a c header

I tried to define the matrix_double3x3 properties but the compiler don't allow me to do. I can define the matrix_float3x3 or matrix_half3x3 but not for the matrix_double3x3.

But I saw the matrix_types.h, it has typedef simd_double3x3 matrix_double3x3

My goal is to send the matrix_double3x3 to Metal for computing the rectified image.

Environment

  • Xcode 14.0 (14A309)
    • Destination:
      • macOS (Minimum Deployments: 12.3)
  • macOS 12.6 (21G115)

The double types are defined in the matrix_types.h header if __HAVE_NATIVE_DOUBLE__ is defined in your Metal shading language source code. However, according to section 2.3 (page 30) in the Metal Shading Language specification, double types are not currently supported in MSL. I also found that there are two different matrix_types.h headers: one for C/C++/Obj-C code, and one for MSL code. I'm guessing from the Common.h file name that the error is likely occurring in a .Metal file.

Can't define the matrix_double3x3 in a c header
 
 
Q