Skip to content

Commit

Permalink
avdevice/dshow: don't mix declarations and code
Browse files Browse the repository at this point in the history
Signed-off-by: James Almer <[email protected]>
  • Loading branch information
jamrial committed Dec 24, 2021
1 parent c147f79 commit 2497a45
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libavdevice/dshow.c
Original file line number Diff line number Diff line change
Expand Up @@ -915,6 +915,7 @@ dshow_cycle_formats(AVFormatContext *avctx, enum dshowDeviceType devtype,
}

if (!pformat_set) {
const char *chroma = av_chroma_location_name(fmt_info->chroma_loc);
if (fmt_info->pix_fmt == AV_PIX_FMT_NONE) {
const AVCodec *codec = avcodec_find_decoder(fmt_info->codec_id);
if (fmt_info->codec_id == AV_CODEC_ID_NONE || !codec) {
Expand All @@ -931,7 +932,6 @@ dshow_cycle_formats(AVFormatContext *avctx, enum dshowDeviceType devtype,
vcaps->MaxOutputSize.cx, vcaps->MaxOutputSize.cy,
1e7 / vcaps->MinFrameInterval);

const char *chroma = av_chroma_location_name(fmt_info->chroma_loc);
if (fmt_info->col_range != AVCOL_RANGE_UNSPECIFIED ||
fmt_info->col_space != AVCOL_SPC_UNSPECIFIED ||
fmt_info->col_prim != AVCOL_PRI_UNSPECIFIED ||
Expand Down

0 comments on commit 2497a45

Please sign in to comment.