多攝像頭支持

在外部視圖系統(EVS)1.1中,支援由多個實體攝影機設備組成的邏輯攝影機設備。若要使用此虛擬設備,設備實作必須支援同步框架

枚舉、開啟和關閉邏輯相機設備

應用程式可以使用相同的IEvsEnumerator方法來使用可用的邏輯相機設備。傳回的EvsCamera物件代表邏輯相機設備,元資料中必須包含以下項目:

  • ANDROID_REQUEST_AVAILABLE_CAPABILITIES_LOGICAL_MULTI_CAMERA
    如果傳回的 EvsCamera 物件表示邏輯相機,則其相機元資料必須在其ANDROID_REQUEST_AVAILABLE_CAPABILITIES欄位中包含此功能鍵。
  • ANDROID_LOGICAL_MULTI_CAMERA_PHYSICAL_IDS欄位列出了實體相機裝置識別碼。
  • ANDROID_LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE欄位可以具有下列枚舉值之一:
    • ANDROID_LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE_APPROXIMATE適用於主-主模式下的感測器,無硬體快門/曝光同步。
    • ANDROID_LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE_CALIBRATED適用於主從模式下的感測器,硬體快門/曝光同步。同步 GMSL2 相機必須具有此值。

應用程式可以透過新的getPhysicalCameraInfo(stringcameraId)方法中的IEvsCamera檢索實體相機裝置的描述符。

/**
 * Returns the description of the physical camera device that backs this
 * logical camera.
 *
 * If a requested device does not either exist or back this logical device,
 * this method returns a null camera descriptor. And, if this is called on
 * a physical camera device, this method is the same as getCameraInfo_1_1()
 * method if a given device ID is matched. Otherwise, this returns a
 * null camera descriptor.
 *
 * @param  deviceId Physical camera device identifier string.
 * @return info     The description of a member physical camera device.
 *                  This must be the same value as reported by
 *                  EvsEnumerator::getCameraList_1_1().
 */
getPhysicalCameraInfo(string deviceId) generates (CameraDesc info);

配置多攝影機支援

所有邏輯攝影機都需要靜態定義,並且必須透過組態管理器實作進行枚舉。由於 EVS 允許對群組中的每個設備進行不同的配置,因此 EVS 提供成員設備清單並指示影像擷取是否同步。

<!-- camera group 0 -->
<group id='group0' synchronized='CALIBRATED'>
    <caps>
        <!-- list of supported controls supported by all physical devices -->
        <supported_controls>
            <control name='BRIGHTNESS' min='0' max='255'/>
            <control name='CONTRAST' min='0' max='255'/>
        </supported_controls>

        <!-- list of stream configuration supported by all physical devices -->
        <stream id='0' width='640' height='480' format='RGBA_8888' framerate='30'/>
    </caps>

    <!-- list of parameters -->
    <characteristics>
        <parameter
            name='REQUEST_AVAILABLE_CAPABILITIES'
            type='enum'
            size='1'
            value='LOGICAL_MULTI_CAMERA'
        />
        <parameter
            name='LOGICAL_MULTI_CAMERA_PHYSICAL_IDS'
            type='byte[]'
            size='2'
            value='/dev/video3,/dev/video4'
        />
    </characteristics>
</group>
,

在外部視圖系統(EVS)1.1中,支援由多個實體攝影機設備組成的邏輯攝影機設備。若要使用此虛擬設備,設備實作必須支援同步框架

枚舉、開啟和關閉邏輯相機設備

應用程式可以使用相同的IEvsEnumerator方法來使用可用的邏輯相機設備。傳回的EvsCamera物件代表邏輯相機設備,元資料中必須包含以下項目:

  • ANDROID_REQUEST_AVAILABLE_CAPABILITIES_LOGICAL_MULTI_CAMERA
    如果傳回的 EvsCamera 物件表示邏輯相機,則其相機元資料必須在其ANDROID_REQUEST_AVAILABLE_CAPABILITIES欄位中包含此功能鍵。
  • ANDROID_LOGICAL_MULTI_CAMERA_PHYSICAL_IDS欄位列出了實體相機裝置識別碼。
  • ANDROID_LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE欄位可以具有下列枚舉值之一:
    • ANDROID_LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE_APPROXIMATE適用於主-主模式下的感測器,無硬體快門/曝光同步。
    • ANDROID_LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE_CALIBRATED適用於主從模式下的感測器,硬體快門/曝光同步。同步 GMSL2 相機必須具有此值。

應用程式可以透過新的getPhysicalCameraInfo(stringcameraId)方法中的IEvsCamera檢索實體相機裝置的描述符。

/**
 * Returns the description of the physical camera device that backs this
 * logical camera.
 *
 * If a requested device does not either exist or back this logical device,
 * this method returns a null camera descriptor. And, if this is called on
 * a physical camera device, this method is the same as getCameraInfo_1_1()
 * method if a given device ID is matched. Otherwise, this returns a
 * null camera descriptor.
 *
 * @param  deviceId Physical camera device identifier string.
 * @return info     The description of a member physical camera device.
 *                  This must be the same value as reported by
 *                  EvsEnumerator::getCameraList_1_1().
 */
getPhysicalCameraInfo(string deviceId) generates (CameraDesc info);

配置多攝影機支援

所有邏輯攝影機都需要靜態定義,並且必須透過組態管理器實作進行枚舉。由於 EVS 允許對群組中的每個設備進行不同的配置,因此 EVS 提供成員設備清單並指示影像擷取是否同步。

<!-- camera group 0 -->
<group id='group0' synchronized='CALIBRATED'>
    <caps>
        <!-- list of supported controls supported by all physical devices -->
        <supported_controls>
            <control name='BRIGHTNESS' min='0' max='255'/>
            <control name='CONTRAST' min='0' max='255'/>
        </supported_controls>

        <!-- list of stream configuration supported by all physical devices -->
        <stream id='0' width='640' height='480' format='RGBA_8888' framerate='30'/>
    </caps>

    <!-- list of parameters -->
    <characteristics>
        <parameter
            name='REQUEST_AVAILABLE_CAPABILITIES'
            type='enum'
            size='1'
            value='LOGICAL_MULTI_CAMERA'
        />
        <parameter
            name='LOGICAL_MULTI_CAMERA_PHYSICAL_IDS'
            type='byte[]'
            size='2'
            value='/dev/video3,/dev/video4'
        />
    </characteristics>
</group>