我将一个字节转换为一个uint8。我现在想把这个数字传递给一个只接受int64的函数,所以我需要先转换它。int64 i_number = int64(u_number);
这给出了一个错误TypeError: Explicit type conversion not allowed from "uint8" to "int64"
编辑: --我遇到了这个执行NV21到I420转换的libyuv,但是我不知道如何调用它。 int width, int height)
我将从相机回调中获得的NV21 byte[]传递给jni层,并将其转换为无符号字符下面的每个参数代表什么,以及如何从我拥有的无符号char* yuvNV21Buf中获得它们
shape, arr_t, dtype): Casts an array pointer from C to numpy
c_arrpt (uint64= dtype以下是我正在使用的示例中变量的值c_arrptr - 20622304 - numpy.uint642d_ALIGNED_C_CONTIGUOUS_WRITEABLE - _ctypes.PyCSimpleTy