Hello,
I'm trying to query a NSError object returned from on an AVFoundation call by reference.
The ObjectiveC Definition is
- (instancetype)deviceInputWithDevice:(AVCaptureDevice *)device
error:(NSError **)outError;
I tried many combinations and can't figure it out:
err = c_void_p()
print err
err1 = pointer(err)
print err1
A)
deviceInput2=ObjCClass('AVCaptureDeviceInput').deviceInputWithDevice_error_(self.inputDevice2, byref(err1) )
print err1
B)
deviceInput2=ObjCClass('AVCaptureDeviceInput').deviceInputWithDevice_error(self._inputDevice2, err1 )
print err1
What I get is
c_void_p(None)
<objc_util.LP_c_void_p object at 0x10762af48>
A) c_void_p(None)
B) <objc_util.LP_c_void_p object at 0x10762af48>
What is the right way to do this and to get the NSError in the end?
All examples I found just seem to ignore the NSError by using None.
Many thanks!