Skip to content

Commit

Permalink
winegstreamer/wm_reader: Use codec format only for compressed types.
Browse files Browse the repository at this point in the history
CW-Bug-Id: #24120
  • Loading branch information
ziqingh authored and ivyl committed Oct 16, 2024
1 parent 06a7d08 commit e63117c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion dlls/winegstreamer/wm_reader.c
Original file line number Diff line number Diff line change
Expand Up @@ -551,7 +551,9 @@ static HRESULT WINAPI stream_props_GetMediaType(IWMMediaProps *iface, WM_MEDIA_T
TRACE("iface %p, mt %p, size %p.\n", iface, mt, size);

wg_parser_stream_get_codec_format(config->stream->wg_stream, &codec_format);
format = (codec_format.major_type != WG_MAJOR_TYPE_UNKNOWN) ? &codec_format : &config->stream->format;
format = (codec_format.major_type != WG_MAJOR_TYPE_UNKNOWN
&& codec_format.major_type != WG_MAJOR_TYPE_VIDEO
&& codec_format.major_type != WG_MAJOR_TYPE_AUDIO) ? &codec_format : &config->stream->format;
if (!amt_from_wg_format(&stream_mt, format, true))
return E_OUTOFMEMORY;

Expand Down

0 comments on commit e63117c

Please sign in to comment.