CameraDevice only captured a black image on OSX

Hi

I just did some test with JUCE Demo (Camera Capture), it seems CameraDevice works fine on Windows,  but it can't capture the right image on OSX, it just showed a whole black thing... When compile the project, Xcode gave 64 warnings. The last one I noticed was:

ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/System/Library/Frameworks//QuickTime.framework/QuickTime, file was built for i386 which is not the architecture being linked (x86_64): /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/System/Library/Frameworks//QuickTime.framework/QuickTime

The most strangest thing is:  I remembered clearly it can capture the right image and show it below the cameraPreviewComp the other day (on OSX). I spent a lot of time play with it happily. Now, it suddenly abnormality. I suspected maybe my Xcode had some problem, then I unload it and reinstall, no luck. Then I update the whole OSX, 10.9.5 -> 10.10.3, then unload Xcode and install the lastest version... then adjust the settings in Introjucer, again and again... after all of these, I've still no any luck, the Camera Capture page still showed nothing (actually a big black image) below the cameraPreviewComp after I clicked 'Take a snapshot'.

What a bad day!

I think I must missing something. Anybody who tells me how to solve this problem would be appreciate!

 

 

 

Tried it on my OSX10.10 machine and it does capture the image correctly.

We do need to update the internal code to use CoreVideo rather than Quicktime but I've no idea why it's not working for you. Do some debugging and see how far it gets!

Thanks for your reply, Jules.

I did some debugging and extra code that day, it seemed all normal, but the image which captured just was a black one. I feel very strange. I'll do more study if I have time. 

I had a similar problem to this: an image taken successfully on Windows, but the identical code giving only a solid black image on OSX. In my case, the preliminary code giving the problem opened a camera and previewer to preview the image, then closed the camera and previewer and reopened a new camera object asynchronously to take the picture. When I tidied up the code so that the same camera object associated with the previewer also took the picture, then the image on OSX was no longer solid black in colour.