• No results found

PROFILES AND VIDEO SOURCE CONFIGURATIONS

5 Media Configuration Test Cases

5.2 Video Configuration

5.2.2 Video Source Configuration

5.2.2.4 PROFILES AND VIDEO SOURCE CONFIGURATIONS

Test Label: Video Source Configuration – Video Source Configurations and Video Source Configuration Options Consistency

Test Case ID: MEDIA2-2-2-4(OLD MEDIA2-5-1-4)

ONVIF Core Specification Coverage: Get configurations, Get media profiles, Video source configuration.

Command Under Test: GetVideoSourceConfigurations, GetProfiles

WSDL Reference: media2.wsdl

Test Purpose: To verify all Media Profiles are consistent with Video Source Configurations.

Pre-Requisite: Media2 Service is received from the DUT.

Test Configuration: ONVIF Client and DUT Test Procedure:

1. Start an ONVIF Client.

2. Start the DUT.

3. ONVIF Client invokes GetProfiles request with parameters

• Token skipped

• Type[0] := VideoSource

4. The DUT responds with GetProfilesResponse message with parameters

• Profiles list =: profileList

5. For each Media Profile profile in profileList, which contains Configurations.VideoSource repeat the following steps:

5.1. ONVIF Client invokes GetVideoSourceConfigurations request with parameters

• ConfigurationToken := profile.Configurations.VideoSource.@token

• ProfileToken skipped

5.2. The DUT responds with GetVideoSourceConfigurationsResponse with parameters

• Configurations list =: videoSourceConfList

5.3. If videoSourceConfList[0] is not equal to profile.Configurations.VideoSource, FAIL the test and skip other steps.

Test Result:

PASS –

• DUT passes all assertions.

FAIL –

• DUT did not send GetProfilesResponse message.

• DUT did not send GetVideoSourceConfigurationsResponse message.

Note: The following fields are compared at step 5.3:

• SourceToken

• Name

• Bounds.x

• Bounds.y

• Bounds.width

• Bounds.height

• Extension.Rotate

• Extension.Rotate.Mode

• Extension.Rotate.Degree

• Extension.Extension.LensDescription list (XFactor will be used as a key)

• Extension.Extension.LensDescription.FocalLength

• Extension.Extension.LensDescription.Offset.x

• Extension.Extension.LensDescription.Offset.y

• Extension.Extension.LensDescription.Projection list (Angle and Radius will be used as key)

• Extension.Extension.LensDescription.Projection.Transmittance

5.2.2.5 MODIFY ALL SUPPORTED VIDEO SOURCE CONFIGURATIONS

Test Label: Video Source Configuration – Modify All Supported Video Source Configurations Test Case ID: MEDIA2-2-2-5(OLD MEDIA2-5-1-5)

ONVIF Core Specification Coverage: Get configurations, Get configuration options, Video source configuration, Modify a configuration.

Command Under Test: GetVideoSourceConfigurationOptions, GetVideoSourceConfigurations, SetVideoSourceConfiguration

WSDL Reference: media2.wsdl

Test Purpose: To verify whether all supported Video Source Configuration Options can be set.

Pre-Requisite: Media2 Service is received from the DUT.

Test Configuration: ONVIF Client and DUT Test Procedure:

1. Start an ONVIF Client.

2. Start the DUT.

3. ONVIF Client retrieves Video Source Configurations list by following the procedure mentioned in Annex A.7 with the following input and output parameters

• out videoSourceConfList - Video Source Configurations list

4. ONVIF Client creates PullPoint subscription for the specified topic by following the procedure mentioned in Annex A.12 with the following input and output parameters

• in "tns1:Media/ConfigurationChanged" - Notification Topic

• out s - Subscription reference

• out currentTime - current time for the DUT

• out terminationTime - Subscription termination time

5. For each Video Source Configuration videoSourceConfiguration in videoSourceConfList repeat the following steps:

5.1. ONVIF Client invokes GetVideoSourceConfigurationOptions request with parameters

• ConfigurationToken := videoSourceConfiguration.@token

• ProfileToken skipped

5.2. DUT responds with GetVideoSourceConfigurationOptionsResponse message with parameters

• Options =: options

5.3. ONVIF Client invokes SetVideoSourceConfiguration request with parameters

• Configuration.@token := videoSourceConfiguration.@token

• Configuration.Name := "TestName1"

• Configuration.SourceToken := first value from options.VideoSourceTokensAvailable list

• Configuration.Bounds.x := options.BoundsRange.XRange.Min

• Configuration.Bounds.y := options.BoundsRange.YRange.Min

• Configuration.Bounds.width := options.BoundsRange.WidthRange.Min

• Configuration.Bounds.height := options.BoundsRange.HeightRange.Min

• If options.Extension.Rotate specified:

• Configuration.Extension.Rotate.Mode := first value from options.Extension.Rotate.Mode list

• If Configuration.Extension.Rotate.Mode = ON:

• If options.Extension.Rotate.DegreeList is specified and contains at least one Item:

• Configuration.Extension.Rotate.Degree := first value from options.Extension.Rotate.DegreeList.Item list

• If options.Extension.Rotate.DegreeList is not specified:

• Configuration.Extension.Rotate.Degree := -180

5.4. DUT responds with SetVideoSourceConfigurationResponse message.

5.5. ONVIF Client retrieves and checks tns1:Media/ConfigurationChanged event for the specified Configuration by following the procedure mentioned in Annex A.15 with the following input and output parameters

• in s - Subscription reference

• in currentTime - current time for the DUT

• in terminationTime - subscription termination time

• in videoSourceConfiguration.@token - Configuration token

• in VideoSource - Configuration Type

5.6. ONVIF Client invokes GetVideoSourceConfigurations request with parameters

• ConfigurationToken := videoSourceConfiguration.@token

• ProfileToken skipped

• Configurations list =: videoSourceConfList

5.8. If videoSourceConfList[0] is not equal to Configuration from step 5.3, FAIL the test and skip other steps.

5.9. ONVIF Client invokes SetVideoSourceConfiguration request with parameters

• Configuration.@token := videoSourceConfiguration.@token

• Configuration.Name := "TestName2"

• Configuration.SourceToken := last value from options.VideoSourceTokensAvailable list

• Configuration.Bounds.x := (options.BoundsRange.XRange.Max + options.BoundsRange.XRange.Min - options.BoundsRange.WidthRange.Min) / 2

• Configuration.Bounds.y := (options.BoundsRange.YRange.Max + options.BoundsRange.YRange.Min - options.BoundsRange.HeightRange.Min) / 2

• Configuration.Bounds.width := min{options.BoundsRange.WidthRange.Max, options.BoundsRange.XRange.Max - Configuration.Bounds.x}

• Configuration.Bounds.height := min{options.BoundsRange.HeightRange.Max, options.BoundsRange.YRange.Max - Configuration.Bounds.y}

• If options.Extension.Rotate specified:

• Configuration.Extension.Rotate.Mode := last value from options.Extension.Rotate.Mode list

• If Configuration.Extension.Rotate.Mode = ON:

• If options.Extension.Rotate.DegreeList is specified and contains at least one Item:

• Configuration.Extension.Rotate.Degree := last value from options.Extension.Rotate.DegreeList.Item list

• If options.Extension.Rotate.DegreeList is not specified:

• Configuration.Extension.Rotate.Degree := 180

5.10. DUT responds with SetVideoSourceConfigurationResponse message.

5.11. ONVIF Client retrieves and checks tns1:Media/ConfigurationChanged event for the specified Configuration by following the procedure mentioned in Annex A.15 with the following input and output parameters

• in s - Subscription reference

• in currentTime - current time for the DUT

• in terminationTime - subscription termination time

• in videoSourceConfiguration.@token - Configuration token

• in VideoSource - Configuration Type

5.12. ONVIF Client invokes GetVideoSourceConfigurations request with parameters

• ConfigurationToken := videoSourceConfiguration.@token

• ProfileToken skipped

5.13. The DUT responds with GetVideoSourceConfigurationsResponse with parameters

• Configurations list =: videoSourceConfList

5.14. If videoSourceConfList[0] is not equal to Configuration from step 5.9, FAIL the test and skip other steps.

5.15. ONVIF Client restores settings of Video Source Configuration with @token = videoSourceConfiguration.@token.

6. ONVIF Client deletes PullPoint subscription by following the procedure mentioned in Annex A.13 with the following input and output parameters

• in s - Subscription reference Test Result:

PASS –

• DUT passes all assertions.

FAIL –

• DUT did not send GetVideoSourceConfigurationsResponse message.

• DUT did not send SetVideoSourceConfigurationResponse message.

• DUT did not send GetVideoSourceConfigurationOptionsResponse message.

Note: The following fields are compared at step 5.8 and 5.14:

• SourceToken

• Name

• Bounds.x

• Bounds.y

• Bounds.width

• Bounds.height

• Extension.Rotate

• Extension.Rotate.Mode

• Extension.Rotate.Degree

• Extension.Extension.LensDescription list (XFactor will be used as a key)

• Extension.Extension.LensDescription.FocalLength

• Extension.Extension.LensDescription.Offset.x

• Extension.Extension.LensDescription.Offset.y

• Extension.Extension.LensDescription.Projection list (Angle and Radius will be used as key)

• Extension.Extension.LensDescription.Projection.Transmittance

5.2.2.6 GET VIDEO SOURCE CONFIGURATIONS – INVALID

Related documents