Mobile-SDK-iOS icon indicating copy to clipboard operation
Mobile-SDK-iOS copied to clipboard

How do you get the camera details from the video feed?

Open Nitaym opened this issue 6 years ago • 9 comments

Using M210, M200, Inspire 2 you can select the video streams you wish to receive, and listening on DJIVideoFeedSourceListener gives you info on the available streams. I need a way to connect the video stream (DJIVideoFeed) to the camera details (DJICamera). Namely, to know which video stream relates to which camera.

Is this possible?

I'm using SDK 4.4

Nitaym avatar Mar 11 '18 12:03 Nitaym

Could you try DJIVideoFeedPhysicalSource?

XietongLU avatar Mar 11 '18 15:03 XietongLU

Hi,

DJIVideoFeedPhysicalSource gives the video source, but not the name of the camera. For example, one might have a ZenmuseXT either as DJIVideoFeedPhysicalSourceMainCamera, DJIVideoFeedPhysicalSourceLeftCamera, or DJIVideoFeedPhysicalSourceRightCamera. Depending on drone and configuration.

Thanks Nitay

Nitaym avatar Mar 13 '18 15:03 Nitaym

Hi,

Is there any update on this?

Thanks Nitay

Nitaym avatar Mar 19 '18 11:03 Nitaym

@Nitaym you are right. By design, the physical source is used to determine the source of the video feed. If you need to know the detail of camera, you should access DJICamera.

XietongLU avatar Mar 19 '18 11:03 XietongLU

@XietongLU Thanks for you answer. My question is how do I know which video feed is which camera. For drones like Inspire 2, M210 you have 2-3 video feeds. I'd like to know the camera details of each video feed.

Currently I have a list of video feeds, and a list of DJICamera - But I don't know which video feed is coming from which camera.

Nitaym avatar Mar 20 '18 08:03 Nitaym

I am afraid that you have to base on some context for the aircraft: for example, M210 has two DJICamera instances. The DJIVideoFeedPhysicalSourceLeftCamera is for DJICamera with index 0 and DJIVideoFeedPhysicalSourceRightCamera is for DJICamera with index 1. The reason that we don't provide the interface for this information is in some cases, a physical source doesn't map to any DJICamera instances (FPVCamera).

XietongLU avatar Mar 20 '18 14:03 XietongLU

Okay, I will try and experiment with this. Thanks

Nitaym avatar Mar 20 '18 14:03 Nitaym

Did you resolve your issue with new version? if not, pls report the issue to [email protected] it's the official channel to request DJI SDK support now.

lijia6745 avatar Dec 16 '18 08:12 lijia6745

Hello! This issue is very important and it's so pity DJI SDK is that cumbersome and unclear in terms of setting up video feed desired. In or application our primary goal is to stream live video feed and let user an option to switch between FPV and other camera/cameras (if available). There are so many ways to control cameras, it is possible to set bandwidth allocation for main and left cameras in DJILightbridgeLink, it is also possible to assign sources to primary and secondary channels in DJIOcuSyncLink and allocate bandwidth there. As developers the only method we need is to be able to setup video feed to get video from particular camera (fpv and/or any other from the cameras array). Guys, if you have any plans to make this task easier for developers, that would be super awesome!

antonm76 avatar Oct 14 '20 11:10 antonm76