Record video and take photo simultaneously
1650 1 2021-1-6
Uploading and Loding Picture ...(0/1)
o(^-^)o
fans2fb819bc
lvl.2
Flight distance : 22717 ft
Iceland
Offline

Hi all
I cannot find out how to record a video and take a photo at the same time.
This is possible with the DJI Pilot app while using the remote controller capture picture button (on the Matrice 300 and the H20T) So it should be possible.
However the SDK seems to only allow for one or the other, e.g. you call something like:


// Go into video mode
camera.setMode(.recordVideo)
camera.startRecordVideo { ...} // This works
camera.startShootPhoto{...} // this doesn't work, we are in video mode.

// If you first go into photo mode instead:
camera.setMode(.shootPhoto)
camera.startRecordVideo { ...} // Doesnt work anymore, we are in photo modecamera.startShootPhoto{...} // Now this works.

So, you can take a photo, but then you cannot record a video.
Is there a way to accomplish this? I also tried setting "flat mode" instead but with the same result.

Thanks!


2021-1-6
Use props
想养一条边牧
lvl.3
Flight distance : 1155 ft
Hong Kong
Offline

There is no way to do them in the same mode.
For the M300RTK drone, should use the setFlatMode instead of the setMode first.
And give the PHOTO_SINGLE to shot the photo or VIDEO_NORMAL to record video, see the documentation.https://developer.dji.com/api-re ... atcameramode_inline
2021-1-7
Use props
Advanced
You need to log in before you can reply Login | Register now

Credit Rules