avdevice/decklink: deprecate @mode syntax in device name to specify mode
Signed-off-by: Marton Balint <cus@passwd.hu>
This commit is contained in:
parent
c395d230b1
commit
77d2cb8874
2 changed files with 4 additions and 4 deletions
|
@ -286,7 +286,6 @@ int ff_decklink_list_formats(AVFormatContext *avctx, decklink_direction_t direct
|
||||||
IDeckLinkDisplayModeIterator *itermode;
|
IDeckLinkDisplayModeIterator *itermode;
|
||||||
IDeckLinkDisplayMode *mode;
|
IDeckLinkDisplayMode *mode;
|
||||||
uint32_t format_code;
|
uint32_t format_code;
|
||||||
int i=0;
|
|
||||||
HRESULT res;
|
HRESULT res;
|
||||||
|
|
||||||
if (direction == DIRECTION_IN) {
|
if (direction == DIRECTION_IN) {
|
||||||
|
@ -307,14 +306,14 @@ int ff_decklink_list_formats(AVFormatContext *avctx, decklink_direction_t direct
|
||||||
return AVERROR(EIO);
|
return AVERROR(EIO);
|
||||||
}
|
}
|
||||||
|
|
||||||
av_log(avctx, AV_LOG_INFO, "Supported formats for '%s':\n\tmode\tformat_code\tdescription",
|
av_log(avctx, AV_LOG_INFO, "Supported formats for '%s':\n\tformat_code\tdescription",
|
||||||
avctx->filename);
|
avctx->filename);
|
||||||
while (itermode->Next(&mode) == S_OK) {
|
while (itermode->Next(&mode) == S_OK) {
|
||||||
BMDTimeValue tb_num, tb_den;
|
BMDTimeValue tb_num, tb_den;
|
||||||
mode->GetFrameRate(&tb_num, &tb_den);
|
mode->GetFrameRate(&tb_num, &tb_den);
|
||||||
format_code = av_bswap32(mode->GetDisplayMode());
|
format_code = av_bswap32(mode->GetDisplayMode());
|
||||||
av_log(avctx, AV_LOG_INFO, "\n\t%d\t%.4s\t\t%ldx%ld at %d/%d fps",
|
av_log(avctx, AV_LOG_INFO, "\n\t%.4s\t\t%ldx%ld at %d/%d fps",
|
||||||
++i, (char*) &format_code, mode->GetWidth(), mode->GetHeight(),
|
(char*) &format_code, mode->GetWidth(), mode->GetHeight(),
|
||||||
(int) tb_den, (int) tb_num);
|
(int) tb_den, (int) tb_num);
|
||||||
switch (mode->GetFieldDominance()) {
|
switch (mode->GetFieldDominance()) {
|
||||||
case bmdLowerFieldFirst:
|
case bmdLowerFieldFirst:
|
||||||
|
|
|
@ -516,6 +516,7 @@ av_cold int ff_decklink_read_header(AVFormatContext *avctx)
|
||||||
strcpy (fname, avctx->filename);
|
strcpy (fname, avctx->filename);
|
||||||
tmp=strchr (fname, '@');
|
tmp=strchr (fname, '@');
|
||||||
if (tmp != NULL) {
|
if (tmp != NULL) {
|
||||||
|
av_log(avctx, AV_LOG_WARNING, "The @mode syntax is deprecated and will be removed. Please use the -format_code option.\n");
|
||||||
mode_num = atoi (tmp+1);
|
mode_num = atoi (tmp+1);
|
||||||
*tmp = 0;
|
*tmp = 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue