1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-11-21 10:55:51 +02:00
Commit Graph

17 Commits

Author SHA1 Message Date
Diederick Niehorster
76e164f332 avdevice/dshow: fix crash on x86
fix regression introduced in 911ba8417e.
Removal of WINAPI decoration from function signatures caused crashed
when using dshow on x86.

Fixes #9568

Signed-off-by: Diederick Niehorster <dcnieho@gmail.com>
Reviewed-by: Roger Pack <rogerdpack2@gmail.com>
2022-01-04 17:40:54 +05:30
Diederick Niehorster
271e55987f avdevice/dshow: handle unknown sample time
GetTime may return an error indication that the sample has not
timestamps, or may return a NULL start time. In those cases, fall back
to graph time. Emit log when that happens.
Improve logging in the frame receive function: now logged against
correct avclass instead of NULL.
Better debug message in case sample dropped: could now be audio or
video frame.

Signed-off-by: Diederick Niehorster <dcnieho@gmail.com>
Reviewed-by: Roger Pack <rogerdpack2@gmail.com>
2021-12-24 14:06:21 +05:30
Diederick Niehorster
584b0fbe4b avdevice/dshow: query graph and sample time only once
No need to query twice, use value we've already unconditionally got.
Improve variable names

Signed-off-by: Diederick Niehorster <dcnieho@gmail.com>
Reviewed-by: Roger Pack <rogerdpack2@gmail.com>
2021-12-24 14:06:14 +05:30
Diederick Niehorster
7dc33aad45 avdevice/dshow: implement option to use device video timestamps
The dshow avdevice ignores timestamps for video frames provided by the
DirectShow device, instead using wallclock time, apparently because the
implementer of this code had a device that provided unreliable
timestamps. Me (and others) would like to use the device's timestamps.
The new use_video_device_timestamps option for dshow device enables them
to do so. Since the majority of video devices out there probably provide
fine timestamps, this patch sets the default to using the device
timestamps, which means best fidelity timestamps are used by default.
Using the new option, the user can switch this off and revert to the old
behavior, so a fall back remains available in case the device provides
broken timestamps.

add use_video_device_timestamps to docs.

Closes: #8620

Signed-off-by: Diederick Niehorster <dcnieho@gmail.com>
Reviewed-by: Roger Pack <rogerdpack2@gmail.com>
2021-12-24 14:06:06 +05:30
James Almer
911ba8417e avdevice/dshow: Add namespace prefix to the remaining global symbols
Signed-off-by: James Almer <jamrial@gmail.com>
2021-01-25 19:31:11 -03:00
Oliver Collyer
bf96937a96 avdevice/dshow: Fixed some minor memory leaks
Signed-off-by: James Almer <jamrial@gmail.com>
2019-01-03 13:15:45 -03:00
rogerdpack
bed1d9ec7a dshow: show more debug timestamp info
Signed-off-by: rogerdpack <rogerpack2005@gmail.com>
2015-07-31 18:30:03 +02:00
rogerdpack
61974c7dcc dshow: tweak logging
Signed-off-by: rogerdpack <rogerpack2005@gmail.com>
2015-01-26 02:04:30 -07:00
rogerdpack
b76a0e24f9 dshow: drop initial audio packets with weird timestamps
Signed-off-by: rogerdpack <rogerpack2005@gmail.com>
2015-01-23 06:13:33 -07:00
rogerdpack
773eb74bab dshow: show device name when outputting buffer overflow log message
Signed-off-by: rogerdpack <rogerpack2005@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-03-28 00:22:55 +01:00
Michael Niedermayer
ea4c99de4c dshow_pin: dont return a value from a void function
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-03-25 22:12:07 +01:00
Alexander Strasser
7750c48d30 dshow: Use NO_DSHOW_STRSAFE for all dshow header inclusions
Move the NO_DSHOW_STRSAFE macro definition in front of the dshow.h
system header inclusion.

This excludes the usage of the STRSAFE functions consistently.

Further background on this can be found in the commit message of
revision 05ee0db1 where the #define was initially introduced.

Signed-off-by: Alexander Strasser <eclipse7@gmx.net>
2012-11-16 19:26:13 +01:00
Derek Buitenhuis
80d2ec6bc9 dshow: Change WINBOOL to BOOL
WINBOOL is MinGW-specific, and since both MSVC and MinGW
have BOOL, use that instead.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-09-07 22:23:32 +02:00
Kyle
02cc66dd78 dshow: rename dshow.h to avoid conflict with system header of equal name
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-05-24 14:15:10 +02:00
Rafaël Carré
05ee0db1b2 dshow_filter: fix compilation with mingw-w64
Closes ticket #999
NO_DSHOW_STRSAFE asks dshow.h header to not use secure string function
replacements.
Using secure replacements would break mingw.org compatibility as they don't
declare/define those functions.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-02-16 23:25:59 +01:00
Ramiro Polla
0b951d103d dshow: release pin on disconnect
Signed-off-by: Stefano Sabatini <stefasab@gmail.com>
2011-09-16 11:16:05 +02:00
Ramiro Polla
95eb2e3a38 DirectShow capture support
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-05-21 17:23:14 +02:00