• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*===================== begin_copyright_notice ==================================
2 
3 # Copyright (c) 2022, Intel Corporation
4 
5 # Permission is hereby granted, free of charge, to any person obtaining a
6 # copy of this software and associated documentation files (the "Software"),
7 # to deal in the Software without restriction, including without limitation
8 # the rights to use, copy, modify, merge, publish, distribute, sublicense,
9 # and/or sell copies of the Software, and to permit persons to whom the
10 # Software is furnished to do so, subject to the following conditions:
11 
12 # The above copyright notice and this permission notice shall be included
13 # in all copies or substantial portions of the Software.
14 
15 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
16 # OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
18 # THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
19 # OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
20 # ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
21 # OTHER DEALINGS IN THE SOFTWARE.
22 
23 ======================= end_copyright_notice ==================================*/
24 #ifndef DDI_REGISTER_COMPONENTS_SPECIFIC_H
25 #define DDI_REGISTER_COMPONENTS_SPECIFIC_H
26 
27 #include "media_factory.h"
28 #include "ddi_encode_base_specific.h"
29 #include "media_capstable_specific.h" //Include for component info Comparison
30 #include "ddi_decode_base_specific.h"
31 
32 typedef MediaFactory<ComponentInfo, encode::DdiEncodeBase> DdiEncodeFactory;
33 typedef MediaFactory<ComponentInfo, decode::DdiDecodeBase> DdiDecodeFactory;
34 
35 #if _MEDIA_RESERVED
36 #include "ddi_register_components_specific_reserved.h"
37 #endif
38 
39 #if defined (_HEVC_ENCODE_VDENC_SUPPORTED)
40 #include "ddi_encode_hevc_specific.h"
41 
42 static bool RegisteredHevcMain =
43     DdiEncodeFactory::
44         Register<encode::DdiEncodeHevc>(ComponentInfo {VAProfileHEVCMain, VAEntrypointEncSlice});
45 static bool RegisteredHevcMain10 =
46     DdiEncodeFactory::
47         Register<encode::DdiEncodeHevc>(ComponentInfo{VAProfileHEVCMain10, VAEntrypointEncSlice});
48 static bool RegisteredHevcMain422_10 =
49     DdiEncodeFactory::
50         Register<encode::DdiEncodeHevc>(ComponentInfo{VAProfileHEVCMain422_10, VAEntrypointEncSlice});
51 static bool RegisteredHevcMain444 =
52     DdiEncodeFactory::
53         Register<encode::DdiEncodeHevc>(ComponentInfo{VAProfileHEVCMain444, VAEntrypointEncSlice});
54 static bool RegisteredHevcMain444_10 =
55     DdiEncodeFactory::
56         Register<encode::DdiEncodeHevc>(ComponentInfo{VAProfileHEVCMain444_10, VAEntrypointEncSlice});
57 static bool RegisteredHevcSCCMain =
58     DdiEncodeFactory::
59         Register<encode::DdiEncodeHevc>(ComponentInfo{VAProfileHEVCSccMain, VAEntrypointEncSlice});
60 static bool RegisteredHevcSCCMain10 =
61     DdiEncodeFactory::
62         Register<encode::DdiEncodeHevc>(ComponentInfo{VAProfileHEVCSccMain10, VAEntrypointEncSlice});
63 static bool RegisteredHevcSCCMain444 =
64     DdiEncodeFactory::
65         Register<encode::DdiEncodeHevc>(ComponentInfo{VAProfileHEVCSccMain444, VAEntrypointEncSlice});
66 static bool RegisteredHevcSCCMain444_10 =
67     DdiEncodeFactory::
68         Register<encode::DdiEncodeHevc>(ComponentInfo{VAProfileHEVCSccMain444_10, VAEntrypointEncSlice});
69 #endif // _HEVC_ENCODE_VDENC_SUPPORTED
70 
71 #if defined (_AV1_ENCODE_VDENC_SUPPORTED)
72 #include "ddi_encode_av1_specific.h"
73 static bool RegisteredAv1Profile0 =
74     DdiEncodeFactory::
75         Register<encode::DdiEncodeAV1>(ComponentInfo {VAProfileAV1Profile0, VAEntrypointEncSlice});
76 #endif // _AV1_ENCODE_VDENC_SUPPORTED
77 
78 #if defined (_VP9_ENCODE_VDENC_SUPPORTED)
79 #include "ddi_encode_vp9_specific.h"
80 static bool RegisteredVp9Profile0 =
81     DdiEncodeFactory::
82         Register<encode::DdiEncodeVp9>(ComponentInfo {VAProfileVP9Profile0, VAEntrypointEncSlice});
83 static bool RegisteredVp9Profile1 =
84     DdiEncodeFactory::
85         Register<encode::DdiEncodeVp9>(ComponentInfo {VAProfileVP9Profile1, VAEntrypointEncSlice});
86 static bool RegisteredVp9Profile2 =
87     DdiEncodeFactory::
88         Register<encode::DdiEncodeVp9>(ComponentInfo {VAProfileVP9Profile2, VAEntrypointEncSlice});
89 static bool RegisteredVp9Profile3 =
90     DdiEncodeFactory::
91         Register<encode::DdiEncodeVp9>(ComponentInfo {VAProfileVP9Profile3, VAEntrypointEncSlice});
92 #endif // _VP9_ENCODE_VDENC_SUPPORTED
93 
94 #if defined (_AVC_ENCODE_VDENC_SUPPORTED)
95 #include "ddi_encode_avc_specific.h"
96 
97 static bool RegisteredH264Main =
98     DdiEncodeFactory::
99         Register<encode::DdiEncodeAvc>(ComponentInfo {VAProfileH264Main, VAEntrypointEncSlice});
100 static bool RegisteredH264High =
101     DdiEncodeFactory::
102         Register<encode::DdiEncodeAvc>(ComponentInfo{VAProfileH264High, VAEntrypointEncSlice});
103 static bool RegisteredH264ConstrainedBaseline =
104     DdiEncodeFactory::
105         Register<encode::DdiEncodeAvc>(ComponentInfo{VAProfileH264ConstrainedBaseline, VAEntrypointEncSlice});
106 #endif // _AVC_ENCODE_VDENC_SUPPORTED
107 
108 #if defined (_JPEG_ENCODE_SUPPORTED)
109 #include "ddi_encode_jpeg_specific.h"
110 
111 static bool RegisteredJPEGBaseline =
112     DdiEncodeFactory::
113         Register<encode::DdiEncodeJpeg>(ComponentInfo {VAProfileJPEGBaseline, VAEntrypointEncPicture});
114 #endif // _JPEG_ENCODE_SUPPORTED
115 
116 #if defined (_HEVC_DECODE_SUPPORTED)
117 #include "ddi_decode_hevc_specific.h"
118 
119 static bool RegisteredHEVCMainVLD =
120     DdiDecodeFactory::
121         Register<decode::DdiDecodeHevc>(ComponentInfo {VAProfileHEVCMain, VAEntrypointVLD});
122 static bool RegisteredHEVCMain10VLD =
123     DdiDecodeFactory::
124         Register<decode::DdiDecodeHevc>(ComponentInfo {VAProfileHEVCMain10, VAEntrypointVLD});
125 static bool RegisteredHEVCMain12VLD =
126     DdiDecodeFactory::
127         Register<decode::DdiDecodeHevc>(ComponentInfo {VAProfileHEVCMain12, VAEntrypointVLD});
128 static bool RegisteredHEVCMain422_10VLD =
129     DdiDecodeFactory::
130         Register<decode::DdiDecodeHevc>(ComponentInfo {VAProfileHEVCMain422_10, VAEntrypointVLD});
131 static bool RegisteredHEVCMain422_12VLD =
132     DdiDecodeFactory::
133         Register<decode::DdiDecodeHevc>(ComponentInfo {VAProfileHEVCMain422_12, VAEntrypointVLD});
134 static bool RegisteredHEVCMain444VLD =
135     DdiDecodeFactory::
136         Register<decode::DdiDecodeHevc>(ComponentInfo {VAProfileHEVCMain444, VAEntrypointVLD});
137 static bool RegisteredHEVCMain444_10VLD =
138     DdiDecodeFactory::
139         Register<decode::DdiDecodeHevc>(ComponentInfo {VAProfileHEVCMain444_10, VAEntrypointVLD});
140 static bool RegisteredHEVCMain444_12VLD =
141     DdiDecodeFactory::
142         Register<decode::DdiDecodeHevc>(ComponentInfo {VAProfileHEVCMain444_12, VAEntrypointVLD});
143 static bool RegisteredHEVCMainSCCVLD =
144     DdiDecodeFactory::
145         Register<decode::DdiDecodeHevc>(ComponentInfo {VAProfileHEVCSccMain, VAEntrypointVLD});
146 static bool RegisteredHEVCMainSCC_10VLD =
147     DdiDecodeFactory::
148         Register<decode::DdiDecodeHevc>(ComponentInfo {VAProfileHEVCSccMain10, VAEntrypointVLD});
149 static bool RegisteredHEVCMainSCC444VLD =
150     DdiDecodeFactory::
151         Register<decode::DdiDecodeHevc>(ComponentInfo {VAProfileHEVCSccMain444, VAEntrypointVLD});
152 static bool RegisteredHEVCMainSCC444_10VLD =
153     DdiDecodeFactory::
154         Register<decode::DdiDecodeHevc>(ComponentInfo {VAProfileHEVCSccMain444_10, VAEntrypointVLD});
155 #endif // _HEVC_DECODE_SUPPORTED
156 
157 #if defined (_AVC_DECODE_SUPPORTED)
158 #include "ddi_decode_avc_specific.h"
159 
160 static bool RegisteredH264MainVLD =
161     DdiDecodeFactory::
162         Register<decode::DdiDecodeAvc>(ComponentInfo {VAProfileH264Main, VAEntrypointVLD});
163 static bool RegisteredH264HighVLD =
164     DdiDecodeFactory::
165         Register<decode::DdiDecodeAvc>(ComponentInfo{VAProfileH264High, VAEntrypointVLD});
166 static bool RegisteredH264ConstrainedBaselineVLD =
167     DdiDecodeFactory::
168         Register<decode::DdiDecodeAvc>(ComponentInfo{VAProfileH264ConstrainedBaseline, VAEntrypointVLD});
169 #endif // _AVC_DECODE_SUPPORTED
170 
171 #if defined (_AV1_DECODE_SUPPORTED)
172 #include "ddi_decode_av1_specific.h"
173 
174 static bool RegisteredAv1Profile0VLD =
175     DdiDecodeFactory::
176         Register<decode::DdiDecodeAv1>(ComponentInfo {VAProfileAV1Profile0, VAEntrypointVLD});
177 #endif // _AV1_DECODE_SUPPORTED
178 
179 #if defined (_VVC_DECODE_SUPPORTED)
180 #include "ddi_decode_vvc_specific.h"
181 
182 static bool RegisteredVAProfileVVCMain10 =
183     DdiDecodeFactory::
184         Register<decode::DdiDecodeVvc>(ComponentInfo {(VAProfile)VAProfileVVCMain10, VAEntrypointVLD});
185 #endif
186 
187 #if defined (_JPEG_DECODE_SUPPORTED)
188 #include "ddi_decode_jpeg_specific.h"
189 
190 static bool RegisteredJpegBaselineVLD =
191     DdiDecodeFactory::
192         Register<decode::DdiDecodeJpeg>(ComponentInfo {VAProfileJPEGBaseline, VAEntrypointVLD});
193 #endif // _JPEG_DECODE_SUPPORTED
194 
195 #if defined (_MPEG2_DECODE_SUPPORTED)
196 #include "ddi_decode_mpeg2_specific.h"
197 
198 static bool RegisteredMPEG2SimpleVLD =
199     DdiDecodeFactory::
200         Register<decode::DdiDecodeMpeg2>(ComponentInfo {VAProfileMPEG2Simple, VAEntrypointVLD});
201 static bool RegisteredMPEG2MainVLD =
202     DdiDecodeFactory::
203         Register<decode::DdiDecodeMpeg2>(ComponentInfo {VAProfileMPEG2Main, VAEntrypointVLD});
204 #endif // _MPEG2_DECODE_SUPPORTED
205 
206 #if defined (_VP8_DECODE_SUPPORTED)
207 #include "ddi_decode_vp8_specific.h"
208 
209 static bool RegisteredVP8Version0_3VLD =
210     DdiDecodeFactory::
211         Register<decode::DdiDecodeVp8>(ComponentInfo {VAProfileVP8Version0_3, VAEntrypointVLD});
212 #endif // _VP8_DECODE_SUPPORTED
213 
214 #if defined (_VP9_DECODE_SUPPORTED)
215 #include "ddi_decode_vp9_specific.h"
216 
217 static bool RegisteredVP9Profile0VLD =
218     DdiDecodeFactory::
219         Register<decode::DdiDecodeVp9>(ComponentInfo {VAProfileVP9Profile0, VAEntrypointVLD});
220 static bool RegisteredVP9Profile1VLD =
221     DdiDecodeFactory::
222         Register<decode::DdiDecodeVp9>(ComponentInfo {VAProfileVP9Profile1, VAEntrypointVLD});
223 static bool RegisteredVP9Profile2VLD =
224     DdiDecodeFactory::
225         Register<decode::DdiDecodeVp9>(ComponentInfo {VAProfileVP9Profile2, VAEntrypointVLD});
226 static bool RegisteredVP9Profile3VLD =
227     DdiDecodeFactory::
228         Register<decode::DdiDecodeVp9>(ComponentInfo {VAProfileVP9Profile3, VAEntrypointVLD});
229 #endif // _VP9_DECODE_SUPPORTED
230 
231 #endif // DDI_REGISTER_COMPONENTS_SPECIFIC_H
232