|
1 // |
|
2 // Copyright (c) 2009-2010 Nokia Corporation and/or its subsidiary(-ies). |
|
3 // All rights reserved. |
|
4 // This component and the accompanying materials are made available |
|
5 // under the terms of "Eclipse Public License v1.0" |
|
6 // which accompanies this distribution, and is available |
|
7 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 // |
|
9 // Initial Contributors: |
|
10 // Nokia Corporation - initial contribution. |
|
11 // |
|
12 // Contributors: |
|
13 // |
|
14 // Description: |
|
15 // |
|
16 |
|
17 LOAD_SUITE tsu_omxilgraphicsink |
|
18 |
|
19 START_TESTCASE MMVIDEO-OMX-GS-001-01-HP |
|
20 //! @SYMTestCaseID MMVIDEO-OMX-GS-001-01-HP |
|
21 //! @SYMTestType UT |
|
22 //! @SYMTestCaseDesc Confirm OMX_GraphicSink component is initialized with the correct parameters and is initialized to the correct state |
|
23 //! @SYMTestExpectedResults The component is initialized correctly and in the right state |
|
24 //! @SYMTestActions Create a OMX_GraphicSink component and check initial state OMX_StateLoaded |
|
25 //! Confirm OMX component name using GetComponentVersion |
|
26 //! Check default values for OMX_PARAM_PORTDEFINITIONTYPE |
|
27 //! Check default values for OMX_VIDEO_PARAM_PORTFORMATTYPE |
|
28 //! Send command to all suppported states using SendCommand |
|
29 //! Check state is unaltered with GetState |
|
30 //! COmxILGraphicSink::CreateComponent |
|
31 //! COmxILGraphicSinkProcessingFunction::StateTransitionIndication |
|
32 //! COmxILGraphicSinkVPB0Port::GetParameter |
|
33 //! COmxILGraphicSinkVPB0Port::SetParameter |
|
34 RUN_TEST_STEP 100 tsu_omxilgraphicsink MMVIDEO-OMX-GS-001-01-HP |
|
35 END_TESTCASE MMVIDEO-OMX-GS-001-01-HP |
|
36 |
|
37 START_TESTCASE MMVIDEO-OMX-GS-001-02-HP |
|
38 //! @SYMTestCaseID MMVIDEO-OMX-GS-001-02-HP |
|
39 //! @SYMTestType UT |
|
40 //! @SYMTestCaseDesc Test default parameters assigned and exported into a struct using the correct index type |
|
41 //! Then change Framerate value using the same structs and confirm the value is updated |
|
42 //! @SYMTestExpectedResults Framerate is updated in in OMX_VIDEO_PARAM_PORTFORMATTYPE and OMX_PARAM_PORTDEFINITIONTYPE |
|
43 //! @SYMTestActions Using OMX_PARAM_PORTDEFINITIONTYPE set xFramerate OMX_ErrorUnsupportedSetting |
|
44 //! Confirm xFramerate value using OMX_PARAM_PORTDEFINITIONTYPE |
|
45 //! Confirm xFramerate value using OMX_VIDEO_PARAM_PORTFORMATTYPE |
|
46 //! Using OMX_VIDEO_PARAM_PORTFORMATTYPE set xFramerate OMX_ErrorUnsupportedSetting |
|
47 //! Confirm xFramerate value using OMX_VIDEO_PARAM_PORTFORMATTYPE -GetParameter |
|
48 //! Confirm xFramerate value using OMX_PARAM_PORTDEFINITIONTYPE -GetParameter |
|
49 //! COmxILGraphicSinkVPB0Port::GetParameter |
|
50 //! COmxILGraphicSinkVPB0Port::SetParameter |
|
51 RUN_TEST_STEP 100 tsu_omxilgraphicsink MMVIDEO-OMX-GS-001-02-HP |
|
52 END_TESTCASE MMVIDEO-OMX-GS-001-02-HP |
|
53 |
|
54 START_TESTCASE MMVIDEO-OMX-GS-001-03-HP |
|
55 //! @SYMTestCaseID MMVIDEO-OMX-GS-001-03-HP |
|
56 //! @SYMTestType UT |
|
57 //! @SYMTestCaseDesc Test default parameters assigned and exported into a struct using the correct index type |
|
58 //! Then change Framesize value using the same structs and confirm the value is updated |
|
59 //! @SYMTestExpectedResults Framesize is changed in the graphicsink component |
|
60 //! @SYMTestActions Declare and populate data structure OMX_PARAM_PORTDEFINITIONTYPE |
|
61 //! Attempt to set nFrameHeight & nFrameWidth -SetParameter |
|
62 //! Confirm values are updated in component |
|
63 //! Repeat multiple time with increases frame sizes |
|
64 //! COmxILGraphicSinkVPB0Port::GetParameter |
|
65 //! COmxILGraphicSinkVPB0Port::SetParameter |
|
66 RUN_TEST_STEP 100 tsu_omxilgraphicsink MMVIDEO-OMX-GS-001-03-HP |
|
67 END_TESTCASE MMVIDEO-OMX-GS-001-03-HP |
|
68 |
|
69 START_TESTCASE MMVIDEO-OMX-GS-001-04-HP |
|
70 //! @SYMTestCaseID MMVIDEO-OMX-GS-001-04-HP |
|
71 //! @SYMTestType UT |
|
72 //! @SYMTestCaseDesc Test default parameters assigned and exported into a struct using the correct index type |
|
73 //! Then change colour format using the same structs and confirm the value is updated |
|
74 //! @SYMTestExpectedResults Colour format is never changed from the default value |
|
75 //! @SYMTestActions Using OMX_PARAM_PORTDEFINITIONTYPE set eColorFormat to OMX_COLOR_FormatCbYCrY |
|
76 //! Confirm eColorFormat value using OMX_VIDEO_PARAM_PORTFORMATTYPE & OMX_PARAM_PORTDEFINITIONTYPE |
|
77 //! Set negative values for eColorFormat & eCompressionFormat using OMX_PARAM_PORTDEFINITIONTYPE |
|
78 //! Using OMX_VIDEO_PARAM_PORTFORMATTYPE set eColorFormat to OMX_COLOR_FormatCbYCrY |
|
79 //! Confirm eColorFormat value using OMX_VIDEO_PARAM_PORTFORMATTYPE & OMX_PARAM_PORTDEFINITIONTYPE |
|
80 //! Set negative values for eColorFormat & eCompressionFormat using OMX_VIDEO_PARAM_PORTFORMATTYPE |
|
81 //! COmxILGraphicSinkVPB0Port::GetParameter |
|
82 //! COmxILGraphicSinkVPB0Port::SetParameter |
|
83 RUN_TEST_STEP 100 tsu_omxilgraphicsink MMVIDEO-OMX-GS-001-04-HP |
|
84 END_TESTCASE MMVIDEO-OMX-GS-001-04-HP |
|
85 |
|
86 START_TESTCASE MMVIDEO-OMX-GS-001-05-HP |
|
87 //! @SYMTestCaseID MMVIDEO-OMX-GS-001-05-HP |
|
88 //! @SYMTestType UT |
|
89 //! @SYMTestCaseDesc Test default parameters assigned and exported into a struct using the correct index type |
|
90 //! Then change buffer count using the same structs and confirm the value is updated |
|
91 //! @SYMTestExpectedResults nBufferCountActual value is updated in component |
|
92 //! @SYMTestActions Using OMX_PARAM_PORTDEFINITIONTYPE confirm nBufferCountMin and nBufferCountActual values |
|
93 //! Set nBufferCountActual to below nBufferCountMin and confirm OMX_ErrorBadParameter |
|
94 //! Incrementally increase nBufferCountActual and set in component |
|
95 //! COmxILGraphicSinkVPB0Port::GetParameter |
|
96 //! COmxILGraphicSinkVPB0Port::SetParameter |
|
97 RUN_TEST_STEP 100 tsu_omxilgraphicsink MMVIDEO-OMX-GS-001-05-HP |
|
98 END_TESTCASE MMVIDEO-OMX-GS-001-05-HP |
|
99 |
|
100 START_TESTCASE MMVIDEO-OMX-GS-001-06-HP |
|
101 //! @SYMTestCaseID MMVIDEO-OMX-GS-001-06-HP |
|
102 //! @SYMTestType UT |
|
103 //! @SYMTestCaseDesc Test stride dependant values in supported struct types using the correct index type |
|
104 //! @SYMTestExpectedResults Stride value is updated and correct in component |
|
105 //! @SYMTestActions Using OMX_PARAM_PORTDEFINITIONTYPE confirm stride dependant values |
|
106 //! Set nFrameWidth & eColorFormat and calculated correct stride |
|
107 //! Incrementally increase nFrameWidth and set in component |
|
108 //! COmxILGraphicSinkVPB0Port::GetParameter |
|
109 //! COmxILGraphicSinkVPB0Port::SetParameter |
|
110 RUN_TEST_STEP 100 tsu_omxilgraphicsink MMVIDEO-OMX-GS-001-06-HP |
|
111 END_TESTCASE MMVIDEO-OMX-GS-001-06-HP |
|
112 |
|
113 START_TESTCASE MMVIDEO-OMX-GS-001-07-HP |
|
114 //! @SYMTestCaseID MMVIDEO-OMX-GS-001-07-HP |
|
115 //! @SYMTestType UT |
|
116 //! @SYMTestCaseDesc Attempt to set the parameter of the graphics sink component |
|
117 //! @SYMTestExpectedResults Set command should return appropiate error and value is updated |
|
118 //! @SYMTestActions Using OMX_PARAM_PORTDEFINITIONTYPE change values |
|
119 //! Attempt to set the following values nBufferCountMin, nBufferSize, nBufferAlignment |
|
120 //! nSliceHeight, bEnabled, bPopulated, bBuffersContiguous and eDomain |
|
121 //! COmxILGraphicSinkVPB0Port::GetParameter |
|
122 //! COmxILGraphicSinkVPB0Port::SetParameter |
|
123 RUN_TEST_STEP 100 tsu_omxilgraphicsink MMVIDEO-OMX-GS-001-07-HP |
|
124 END_TESTCASE MMVIDEO-OMX-GS-001-07-HP |
|
125 |
|
126 START_TESTCASE MMVIDEO-OMX-GS-001-08-HP |
|
127 //! @SYMTestCaseID MMVIDEO-OMX-GS-001-08-HP |
|
128 |
|
129 |
|
130 |
|
131 //! @SYMTestType UT |
|
132 //! @SYMTestCaseDesc Attempt to set unsupported colour format types |
|
133 //! @SYMTestExpectedResults OMX_ErrorBadParameter and OMX_ErrorUnsupported setting should be returned |
|
134 //! @SYMTestActions Using OMX_PARAM_PORTDEFINITIONTYPE and OMX_VIDEO_PARAM_PORTFORMATTYPE |
|
135 //! Set unsupported OMX_COLOR_FORMATTYPE and Set unsupported OMX_VIDEO_CODINGTYPE |
|
136 //! Both structs should return OMX_ErrorUnsupportedSetting when SetParmater called |
|
137 //! Use combination of unsupported colour formats to invoke OMX_ErrorBadParameter |
|
138 //! COmxILGraphicSinkVPB0Port::GetParameter |
|
139 //! COmxILGraphicSinkVPB0Port::SetParameter |
|
140 RUN_TEST_STEP 100 tsu_omxilgraphicsink MMVIDEO-OMX-GS-001-08-HP |
|
141 END_TESTCASE MMVIDEO-OMX-GS-001-08-HP |
|
142 |
|
143 START_TESTCASE MMVIDEO-OMX-GS-001-09-HP |
|
144 //! @SYMTestCaseID MMVIDEO-OMX-GS-001-09-HP |
|
145 //! @SYMTestType UT |
|
146 //! @SYMTestCaseDesc Get BytesPerPixel for all color formats |
|
147 //! @SYMTestExpectedResults A valid bytes per pixil TInt value is returned |
|
148 //! @SYMTestActions Call COmxILMMBuffer::BytesPerPixel with OMX_COLOR_FORMATTYPE |
|
149 //! Call COmxILMMBuffer::BytesPerPixel with TUidPixelFormat |
|
150 //! COmxILMMBuffer::BytesPerPixel(TUidPixelFormat aPixelForamt) |
|
151 //! COmxILMMBuffer::BytesPerPixel(OMX_COLOR_FORMATTYPE aPixelForamt) |
|
152 RUN_TEST_STEP 100 tsu_omxilgraphicsink MMVIDEO-OMX-GS-001-09-HP |
|
153 END_TESTCASE MMVIDEO-OMX-GS-001-09-HP |
|
154 |
|
155 // START_TESTCASE MMVIDEO-OMX-GS-001-00-HP |
|
156 //! @SYMTestCaseID MMVIDEO-OMX-GS-001-00-HP |
|
157 //! @SYMTestType UT |
|
158 //! @SYMTestCaseDesc Allocate test for Graphic Sink component |
|
159 //! @SYMTestExpectedResults OOM testing should return correct errors |
|
160 //! @SYMTestActions Allocate testing of the Graphic SInk OMX component |
|
161 //! COmxILGraphicSink::CreateComponent |
|
162 // Fails due to "OmxILPort: 1" Panic - under investigation. Test disabled as this failure sometimes interferes with subsequent test steps. |
|
163 // RUN_TEST_STEP !OOM 100 tsu_omxilgraphicsink MMVIDEO-OMX-GS-001-00-HP |
|
164 // END_TESTCASE MMVIDEO-OMX-GS-001-00-HP |