@@ -173,6 +173,9 @@ void ffPrintGPU(FFGPUOptions* options)
173173
174174 FF_LIST_FOR_EACH (FFGPUResult , gpu , gpus )
175175 {
176+ if (gpu -> type == FF_GPU_TYPE_UNKNOWN && options -> hideType == FF_GPU_TYPE_UNKNOWN )
177+ continue ;
178+
176179 if (gpu -> type == FF_GPU_TYPE_INTEGRATED && options -> hideType == FF_GPU_TYPE_INTEGRATED )
177180 continue ;
178181
@@ -230,7 +233,8 @@ bool ffParseGPUCommandOptions(FFGPUOptions* options, const char* key, const char
230233 if (ffStrEqualsIgnCase (subKey , "hide-type" ))
231234 {
232235 options -> hideType = (FFGPUType ) ffOptionParseEnum (key , value , (FFKeyValuePair []) {
233- { "none" , FF_GPU_TYPE_UNKNOWN },
236+ { "none" , FF_GPU_TYPE_NONE },
237+ { "unknown" , FF_GPU_TYPE_UNKNOWN },
234238 { "integrated" , FF_GPU_TYPE_INTEGRATED },
235239 { "discrete" , FF_GPU_TYPE_DISCRETE },
236240 {},
@@ -288,7 +292,8 @@ void ffParseGPUJsonObject(FFGPUOptions* options, yyjson_val* module)
288292 {
289293 int value ;
290294 const char * error = ffJsonConfigParseEnum (val , & value , (FFKeyValuePair []) {
291- { "none" , FF_GPU_TYPE_UNKNOWN },
295+ { "none" , FF_GPU_TYPE_NONE },
296+ { "unknown" , FF_GPU_TYPE_UNKNOWN },
292297 { "integrated" , FF_GPU_TYPE_INTEGRATED },
293298 { "discrete" , FF_GPU_TYPE_DISCRETE },
294299 {},
@@ -345,9 +350,12 @@ void ffGenerateGPUJsonConfig(FFGPUOptions* options, yyjson_mut_doc* doc, yyjson_
345350 {
346351 switch (options -> hideType )
347352 {
348- case FF_GPU_TYPE_UNKNOWN :
353+ case FF_GPU_TYPE_NONE :
349354 yyjson_mut_obj_add_str (doc , module , "hideType" , "none" );
350355 break ;
356+ case FF_GPU_TYPE_UNKNOWN :
357+ yyjson_mut_obj_add_str (doc , module , "hideType" , "unknown" );
358+ break ;
351359 case FF_GPU_TYPE_INTEGRATED :
352360 yyjson_mut_obj_add_str (doc , module , "hideType" , "integrated" );
353361 break ;
0 commit comments