Hello guys,
It’s impossible since Unity 2018.3.0b4 and b5 (I don’t test previous build but I think it must happen too) to compile a XCode project generate with Unity if you use the Camera from your device.
It’s due to CameraCapture.mm.
If you have a project with a call to the Camera module and then if you generate your project in XCode.
It won’t compile.
The CameraCapture.mm that comes from Unity 2017 works fine.
Cause those lines are correct :
#define countof(arr) sizeof(arr)/sizeof(arr[0])
static_assert(countof(presetW) == countof(preset), “preset and preset width arrrays have different elem count”);
But in Unity 2018.3.0bX, those lines (and most of the lines) from this file changed and are now this one :
const int count = STATIC_ARRAY_COUNT(preset);
so the STATIC_ARRAY_COUNT(preset) isn’t defined.
A line is missing and it’s :
#define STATIC_ARRAY_COUNT(arr) sizeof(arr)/sizeof(arr[0])
with this one, you can compile.
Cheers.
Aurélien.
P.S : I create a ticket, I’ll update the title from this post as soon as I have the case number