
Recherche avancée
Autres articles (96)
-
Personnaliser en ajoutant son logo, sa bannière ou son image de fond
5 septembre 2013, parCertains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;
-
Ecrire une actualité
21 juin 2013, parPrésentez les changements dans votre MédiaSPIP ou les actualités de vos projets sur votre MédiaSPIP grâce à la rubrique actualités.
Dans le thème par défaut spipeo de MédiaSPIP, les actualités sont affichées en bas de la page principale sous les éditoriaux.
Vous pouvez personnaliser le formulaire de création d’une actualité.
Formulaire de création d’une actualité Dans le cas d’un document de type actualité, les champs proposés par défaut sont : Date de publication ( personnaliser la date de publication ) (...) -
Les tâches Cron régulières de la ferme
1er décembre 2010, parLa gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
Le super Cron (gestion_mutu_super_cron)
Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...)
Sur d’autres sites (25881)
-
Problems compiling ffmpeg on windows using cygwin
26 mai 2014, par Papajohn000I’ve been having a lot of trouble recently compiling ffmpeg on windows. I’m currently using the cgywin terminal to run the code. I’ve tried following many of the most popular tutorials on the web but I can’t seem to get it to work. I’m currently using this tutorial as a guide http://www.roman10.net/how-to-build-ffmpeg-for-android/
Where I’m at :
I’ve created a bash script
#!/bin/bash
NDK=C:/Users/jrblain/Development/adt-bundle-windows-x86_64-20130514/android-ndk-r9
PLATFORM=$NDK/platforms/android-8/arch-arm/
PREBUILT=$NDK/toolchains/arm-linux-androideabi-4.6/prebuilt/windows-x86_64
function build_one
{
./configure --target-os=linux \
--prefix=$PREFIX \
--enable-cross-compile \
--extra-libs="-lgcc" \
--arch=arm \
--cc=$PREBUILT/bin/arm-linux-androideabi-gcc \
--cross-prefix=$PREBUILT/bin/arm-linux-androideabi- \
--nm=$PREBUILT/bin/arm-linux-androideabi-nm \
--sysroot=$PLATFORM \
--extra-cflags=" -O3 -fpic -DANDROID -DHAVE_SYS_UIO_H=1 -Dipv6mr_interface=ipv6mr_ifindex -fasm -Wno-psabi -fno-short-enums -fno-strict-aliasing -finline-limit=300 $OPTIMIZE_CFLAGS " \
--disable-shared \
--enable-static \
--extra-ldflags="-Wl,-rpath-link=$PLATFORM/usr/lib -L$PLATFORM/usr/lib -nostdlib -lc -lm -ldl -llog" \
--disable-everything \
--enable-demuxer=mov \
--enable-demuxer=h264 \
--disable-ffplay \
--enable-protocol=file \
--enable-avformat \
--enable-avcodec \
--enable-decoder=rawvideo \
--enable-decoder=mjpeg \
--enable-decoder=h263 \
--enable-decoder=mpeg4 \
--enable-decoder=h264 \
--enable-parser=h264 \
--disable-network \
--enable-zlib \
--disable-avfilter \
--disable-avdevice \
$ADDITIONAL_CONFIGURE_FLAG
make clean
make -j4 install
$PREBUILT/bin/arm-linux-androideabi-ar d libavcodec/libavcodec.a inverse.o
$PREBUILT/bin/arm-linux-androideabi-ld -rpath-link=$PLATFORM/usr/lib -L$PLATFORM/usr/lib -soname libffmpeg.so -shared -nostdlib -z,noexecstack -Bsymbolic --whole-archive --no-undefined -o $PREFIX/libffmpeg.so libavcodec/libavcodec.a libavformat/libavformat.a libavutil/libavutil.a libswscale/libswscale.a -lc -lm -lz -ldl -llog --warn-once --dynamic-linker=/system/bin/linker $PREBUILT/lib/gcc/arm-linux-androideabi/4.4.3/libgcc.a
}
#arm v6
#CPU=armv6
#OPTIMIZE_CFLAGS="-marm -march=$CPU"
#PREFIX=./android/$CPU
#ADDITIONAL_CONFIGURE_FLAG=
#build_one
#arm v7vfpv3
CPU=armv7-a
OPTIMIZE_CFLAGS="-mfloat-abi=softfp -mfpu=vfpv3-d16 -marm -march=$CPU "
PREFIX=./android/$CPU
ADDITIONAL_CONFIGURE_FLAG=
build_one
#arm v7vfp
#CPU=armv7-a
#OPTIMIZE_CFLAGS="-mfloat-abi=softfp -mfpu=vfp -marm -march=$CPU "
#PREFIX=./android/$CPU-vfp
#ADDITIONAL_CONFIGURE_FLAG=
#build_one
#arm v7n
#CPU=armv7-a
#OPTIMIZE_CFLAGS="-mfloat-abi=softfp -mfpu=neon -marm -march=$CPU -mtune=cortex-a8"
#PREFIX=./android/$CPU
#ADDITIONAL_CONFIGURE_FLAG=--enable-neon
#build_one
#arm v6+vfp
#CPU=armv6
#OPTIMIZE_CFLAGS="-DCMP_HAVE_VFP -mfloat-abi=softfp -mfpu=vfp -marm -march=$CPU"
#PREFIX=./android/${CPU}_vfp
#ADDITIONAL_CONFIGURE_FLAG=
#build_oneI then followed steps 4-6 of this post Does anyone find this useful ? - Compiling FFMPEG on Windows with Cywin and NDK r5 which consists of
4 - Open the file 'configure' in the root of the FFMPEG directory in a text editor.
5 - Comment out lines 2073, 2074 and 2075.
6 - Below 2075, add the following line:
TMPDIR=c:/cygwin/tmpWhen I ran the script in cgywin I got this result :
install prefix ./android/armv7-a
source path .
C compiler C:/Users/jrblain/Development/adt-bundle-windows-x86_64-20130514/android-ndk-r9/toolchains/arm-linux-androideabi-4.6/prebuilt/windows-x86_64/bin/arm-linux-androideabi-gcc
ARCH arm (armv7-a)
big-endian no
runtime cpu detection yes
ARMv5TE enabled yes
ARMv6 enabled yes
ARMv6T2 enabled yes
VFP enabled yes
NEON enabled yes
THUMB enabled no
debug symbols yes
strip symbols yes
optimize for size no
optimizations yes
static yes
shared no
postprocessing support no
new filter support no
network support no
threading support pthreads
safe bitstream reader yes
SDL support no
opencl enabled no
texi2html enabled no
perl enabled no
pod2man enabled no
makeinfo enabled no
External libraries:
zlib
Enabled decoders:
h263 mjpeg rawvideo
h264 mpeg4
Enabled encoders:
Enabled hwaccels:
Enabled parsers:
h263 h264 mpeg4video
Enabled demuxers:
h264 mov
Enabled muxers:
Enabled protocols:
file
Enabled filters:
Enabled bsfs:
Enabled indevs:
Enabled outdevs:
License: LGPL version 2.1 or later
Creating config.mak, config.h, and doc/config.texi...
libavutil/avconfig.h is unchanged
WARNING: C:/Users/jrblain/Development/adt-bundle-windows-x86_64-20130514/android-ndk-r9/toolchains/arm-linux-androideabi-4.6/prebuilt/windows-x86_64/bin/arm-linux-androideabi-pkg-config not found, library detection may fail.
library.mak:105: *** missing separator. Stop.
library.mak:105: *** missing separator. Stop.
C:\Users\jrblain\Development\adt-bundle-windows-x86_64-20130514\android-ndk-r9\toolchains\arm-linux-androideabi-4.6\prebuilt\windows-x86_64\bin\arm-linux-androideabi-ld.exe: ,noexecstack: unknown -z option
C:\Users\jrblain\Development\adt-bundle-windows-x86_64-20130514\android-ndk-r9\toolchains\arm-linux-androideabi-4.6\prebuilt\windows-x86_64\bin\arm-linux-androideabi-ld.exe: use the --help option for usage informationAfter this script runs I get some new files within my ffmpeg folder. They are .config, config(header), config.mak , config.fate. The android folder is never created like it is supposed to. I’m also not sure where the library.mak error is coming from considering that it came with ffmpeg download.
I’m not sure where this i’m going wrong in all of this. I feel like the fact that I’m using windows will make this build process different.
-
LibVLC DXVA2 Windows C++ Hardware Acceleration
15 novembre 2016, par Sergiu VladI want to decode a h264 RTSP stream using DXVA2 Accelerated decoder. In VLC it does work but in my code have the following output :
avcodec generic warning: threaded frame decoding is not compatible with DXVA2, disabled
avcodec generic debug: available hardware decoder output format 61 (dxva2_vld)
avcodec generic debug: available hardware decoder output format 128 (d3d11va_vld)
avcodec generic debug: available software decoder output format 12 (yuvj420p)
core generic debug: looking for hw decoder module matching "any": 1 candidates
core generic debug: no hw decoder modules matchedIs this a problem with NV12 conversion ? Is there a way to force DXVA2 ?
Thanks
CODE :
#include
#include
#include
#include
#include
#include <iostream>
#include
#include <ctime>
#include <vlc></vlc>vlc.h>
// RTSP address
const char* rtspAddress = "rtsp://admin:admin@192.168.0.245/live_st1";
// Video resolution WxH
cv::Size rtspRes(1920, 1080);
struct VideoDataStruct
{
int param;
};
int done = 0;
libvlc_media_player_t *mp;
unsigned int videoBufferSize = 0;
uint8_t *videoBuffer = 0;
void cbVideoPrerender(void *p_video_data, uint8_t **pp_pixel_buffer, int size)
{
if (size > videoBufferSize || !videoBuffer)
{
printf("Reallocate raw video buffer %d bytes\n", size);
free(videoBuffer);
videoBuffer = (uint8_t *)malloc(size);
videoBufferSize = size;
}
// videoBuffer = (uint8_t *)malloc(size);
*pp_pixel_buffer = videoBuffer;
}
void cbVideoPostrender(void *p_video_data, uint8_t *p_pixel_buffer, int width, int height, int pixel_pitch, int size, int64_t pts)
{
// Unlocking
//CloseHandle(hMutex);
}
//static void handleEvent(const libvlc_event_t* pEvt, void* pUserData)
//{
// libvlc_time_t time;
// switch (pEvt->type)
// {
// case libvlc_MediaPlayerTimeChanged:
// time = libvlc_media_player_get_time(mp);
// printf("MediaPlayerTimeChanged %lld ms\n", (long long)time);
// break;
// case libvlc_MediaPlayerEndReached:
// printf("MediaPlayerEndReached\n");
// done = 1;
// break;
// default:
// printf("%s\n", libvlc_event_type_name(pEvt->type));
// }
//}
clock_t startTime[8];
int framesReceivedThisSecond[8];
int main()
{
// VLC pointers
libvlc_instance_t *inst;
libvlc_media_t *m;
void *pUserData = 0;
VideoDataStruct dataStruct;
// VLC options
char smem_options[1000];
// RV24
sprintf(smem_options
, "#transcode{vcodec=RV24}:smem{"
"video-prerender-callback=%lld,"
"video-postrender-callback=%lld,"
"video-data=%lld,"
"no-time-sync},"
, (long long int)(intptr_t)(void*)&cbVideoPrerender
, (long long int)(intptr_t)(void*)&cbVideoPostrender
, (long long int)(intptr_t)(void*)&dataStruct
);
const char * const vlc_args[] = {
"-I", "dummy", // Don't use any interface
"--ignore-config", // Don't use VLC's config
"--extraintf=logger", // Log anything
"--verbose=4", // Be verbose
// "--ffmpeg-hw",
// "-vvv",
"--ffmpeg-hw",
"--avcodec-hw=any",
"--sout", smem_options // Stream to memory
};
// Launch VLC
inst = libvlc_new(sizeof(vlc_args) / sizeof(vlc_args[0]), vlc_args);
// Create a new item
m = libvlc_media_new_location(inst, rtspAddress);
// Create a media player playing environement
mp = libvlc_media_player_new_from_media(m);
// libvlc_event_manager_t* eventManager = libvlc_media_player_event_manager(mp);
// libvlc_event_attach(eventManager, libvlc_MediaPlayerTimeChanged, handleEvent, pUserData);
// libvlc_event_attach(eventManager, libvlc_MediaPlayerEndReached, handleEvent, pUserData);
// libvlc_event_attach(eventManager, libvlc_MediaPlayerPositionChanged, handleEvent, pUserData);
//libvlc_video_set_format(mp, "RV24", 240, 320, 240 * 3 );
// play the media_player
libvlc_media_player_play(mp);
// Create a window for displaying the video
std::string winName("Demo Video");
cv::namedWindow(winName, cv::WINDOW_AUTOSIZE);
cv::Mat frame;
int key = 0;
// Endless loop, press Esc to quit
while (key != 27)
{
// Check for invalid input
if (videoBuffer)
{
// CV_8UC3 = 8 bits, 3 chanels
frame = cv::Mat(rtspRes, CV_8UC3, videoBuffer);
}
if (frame.rows == 0 || frame.cols == 0)
continue;
int stream_number=0;
framesReceivedThisSecond[stream_number]++;
long duration = ( std::clock() - startTime[stream_number] );
if(duration>1000)
{
std::cout<<"\n"<<"FPS "<code></ctime></iostream>FULL LOG :
core libvlc debug: Copyright © 1996-2016 the VideoLAN team
core libvlc debug: revision 2.2.3-37-g888b7e89
core libvlc debug: configured with ../extras/package/win32/../../../configure '--enable-update-check' '--enable-lua' '--enable-faad' '--enable-flac' '--enable-theora' '--enable-twolame' '--enable-quicktime' '--enable-avcodec' '--enable-merge-ffmpeg' '--enable-dca' '--enable-mpc' '--enable-libass' '--enable-x264' '--enable-schroedinger' '--enable-realrtsp' '--enable-live555' '--enable-dvdread' '--enable-shout' '--enable-goom' '--enable-caca' '--disable-sdl' '--enable-qt' '--enable-skins2' '--enable-sse' '--enable-mmx' '--enable-libcddb' '--enable-zvbi' '--disable-telx' '--enable-nls' '--host=i686-w64-mingw32' '--build=x86_64-pc-linux-gnu' 'build_alias=x86_64-pc-linux-gnu' 'host_alias=i686-w64-mingw32' 'PKG_CONFIG_PATH=/opt/intel/opencl:' 'PKG_CONFIG_LIBDIR=/home/svlad/DEV/vlc/contrib/i686-w64-mingw32/lib/pkgconfig'
core libvlc debug: using multimedia timers as clock source
core libvlc debug: min period: 1 ms, max period: 1000000 ms
core libvlc debug: searching plug-in modules
core libvlc debug: loading plugins cache file C:\DEV\VLCStreamProcessor\build-untitled-Desktop_Qt_5_5_1_MSVC2013_32bit-Debug\debug\plugins\plugins.dat
core libvlc debug: recursively browsing `C:\DEV\VLCStreamProcessor\build-untitled-Desktop_Qt_5_5_1_MSVC2013_32bit-Debug\debug\plugins'
core libvlc debug: saving plugins cache C:\DEV\VLCStreamProcessor\build-untitled-Desktop_Qt_5_5_1_MSVC2013_32bit-Debug\debug\plugins\plugins.dat
core libvlc debug: plug-ins loaded: 418 modules
core libvlc debug: translation test: code is "C"
core libvlc debug: CPU has capabilities MMX MMXEXT SSE SSE2 SSE3 SSSE3 SSE4.1 SSE4.2 FPU
core playlist debug: creating audio output
core audio output debug: looking for audio output module matching "any": 6 candidates
directsound audio output debug: found 2 devices
core audio output debug: using audio output module "directsound"
core playlist debug: keeping audio output
core interface debug: looking for interface module matching "logger,none": 16 candidates
logger interface: VLC media player - 2.2.4 Weatherwax
logger interface: Copyright © 1996-2016 the VideoLAN team
logger interface:
Warning: if you cannot access the GUI anymore, open a command-line window, go to the directory where you installed VLC and run "vlc -I qt"
logger interface: using logger.
logger interface warning: no log filename provided, using `vlc-log.txt'
logger interface debug: opening logfile `vlc-log.txt'
core libvlc debug: VLC media player - 2.2.4 Weatherwax
core libvlc debug: Copyright © 1996-2016 the VideoLAN team
core libvlc debug: revision 2.2.3-37-g888b7e89
core libvlc debug: configured with ../extras/package/win32/../../../configure '--enable-update-check' '--enable-lua' '--enable-faad' '--enable-flac' '--enable-theora' '--enable-twolame' '--enable-quicktime' '--enable-avcodec' '--enable-merge-ffmpeg' '--enable-dca' '--enable-mpc' '--enable-libass' '--enable-x264' '--enable-schroedinger' '--enable-realrtsp' '--enable-live555' '--enable-dvdread' '--enable-shout' '--enable-goom' '--enable-caca' '--disable-sdl' '--enable-qt' '--enable-skins2' '--enable-sse' '--enable-mmx' '--enable-libcddb' '--enable-zvbi' '--disable-telx' '--enable-nls' '--host=i686-w64-mingw32' '--build=x86_64-pc-linux-gnu' 'build_alias=x86_64-pc-linux-gnu' 'host_alias=i686-w64-mingw32' 'PKG_CONFIG_PATH=/opt/intel/opencl:' 'PKG_CONFIG_LIBDIR=/home/svlad/DEV/vlc/contrib/i686-w64-mingw32/lib/pkgconfig'
core interface debug: using interface module "logger"
core generic debug: creating audio output
core audio output debug: looking for audio output module matching "any": 6 candidates
directsound audio output debug: found 2 devices
core audio output debug: using audio output module "directsound"
core generic debug: keeping audio output
core input debug: Creating an input for 'rtsp://192.168.0.245/live_st1'
core stream output debug: using sout chain=`transcode{vcodec=RV24}:smem{video-prerender-callback=15667245,video-postrender-callback=15667630,video-data=3471900,no-time-sync},'
core stream output debug: stream=`smem'
core stream out debug: looking for sout stream module matching "smem": 22 candidates
core stream out debug: set config option: sout-smem-video-prerender-callback to 15667245
core stream out debug: set config option: sout-smem-video-postrender-callback to 15667630
core stream out debug: set config option: sout-smem-video-data to 3471900
core stream out debug: set config option: sout-smem-time-sync to (null)
core stream out debug: using sout stream module "stream_out_smem"
core stream output debug: stream=`transcode'
core stream out debug: looking for sout stream module matching "transcode": 22 candidates
core stream out debug: set config option: sout-transcode-vcodec to RV24
stream_out_transcode stream out debug: Checking video codec mapping for RV24 got RV24
stream_out_transcode stream out debug: codec video=RV24 0x0 scaling: 0.000000 0kb/s
core stream out debug: using sout stream module "stream_out_transcode"
core input debug: using timeshift granularity of 50 MiB, in path 'C:\Users\BCDVideo\AppData\Local\Temp'
core input debug: `rtsp://admin:admin@192.168.0.245/live_st1' gives access `rtsp' demux `' path `admin:admin@192.168.0.245/live_st1'
core input debug: specified demux `any'
core input debug: creating demux: access='rtsp' demux='any' location='admin:admin@192.168.0.245/live_st1' file='\\admin:admin@192.168.0.245\live_st1'
core demux debug: looking for access_demux module matching "rtsp": 12 candidates
live555 demux debug: version 2016.01.12
live555 demux debug: RTP subsession 'video/H264'
core input debug: selecting program id=0
live555 demux debug: setup start: 0.000000 stop:0.000000
live555 demux debug: We have a timeout of 60 seconds
live555 demux debug: spawned timeout thread
live555 demux debug: play start: 0.000000 stop:0.000000
core demux debug: using access_demux module "live555"
core decoder debug: looking for packetizer module matching "any": 23 candidates
packetizer_h264 decoder debug: found NAL_SPS (sps_id=0)
packetizer_h264 decoder debug: found NAL_PPS (pps_id=0 sps_id=0)
core decoder debug: using packetizer module "packetizer_h264"
core input debug: starting in sync mode
core demux meta debug: looking for meta reader module matching "any": 2 candidates
lua demux meta debug: Trying Lua scripts in C:\Users\BCDVideo\AppData\Roaming\vlc\lua\meta\reader
lua demux meta debug: Trying Lua scripts in C:\DEV\VLCStreamProcessor\build-untitled-Desktop_Qt_5_5_1_MSVC2013_32bit-Debug\debug\lua\meta\reader
core demux meta debug: no meta reader modules matched
core input debug: `rtsp://admin:admin@192.168.0.245/live_st1' successfully opened
core input debug: switching to async mode
core input debug: Buffering 0%
core input debug: Buffering 3%
core input debug: Buffering 10%
core stream output debug: adding a new sout input (sout_input:00c21c50)
core input debug: Buffering 13%
stream_out_transcode stream out debug: creating video transcoding from fcc=`h264' to fcc=`RV24'
core input debug: Buffering 16%
core generic debug: looking for decoder module matching "any": 43 candidates
core input debug: Buffering 20%
core input debug: Buffering 23%
avcodec generic debug: CPU flags: 0x0107d3db
core input debug: Buffering 30%
avcodec generic debug: trying to use direct rendering
core input debug: Buffering 33%
avcodec generic debug: allowing 4 thread(s) for decoding
core input debug: Buffering 36%
avcodec generic warning: threaded frame decoding is not compatible with DXVA2, disabled
core input debug: Buffering 40%
avcodec generic debug: avcodec codec (H264 - MPEG-4 AVC (part 10)) started
core input debug: Buffering 43%
avcodec generic debug: using slice thread mode with 4 threads
core input debug: Buffering 50%
core generic debug: using decoder module "avcodec"
core input debug: Buffering 53%
core encoder debug: looking for encoder module matching "any": 20 candidates
core input debug: Buffering 56%
core input debug: Buffering 60%
avcodec encoder debug: CPU flags: 0x0107d3db
core input debug: Buffering 63%
avcodec encoder debug: Time base for probing setted to 1/1000000
core input debug: Buffering 70%
avcodec encoder debug: Time base set to 1/1000000
core input debug: Buffering 73%
avcodec encoder debug: found encoder Raw video
core input debug: Buffering 76%
core encoder debug: using encoder module "avcodec"
core input debug: Buffering 80%
core encoder debug: removing module "avcodec"
core input debug: Buffering 83%
core input debug: Buffering 90%
core input debug: Buffering 93%
core input debug: Buffering 96%
core input debug: Stream buffering done (1002 ms in 834 ms)
core input debug: Decoder wait done in 0 ms
avcodec generic debug: available hardware decoder output format 61 (dxva2_vld)
avcodec generic debug: available hardware decoder output format 128 (d3d11va_vld)
avcodec generic debug: available software decoder output format 12 (yuvj420p)
core generic debug: looking for hw decoder module matching "any": 1 candidates
core generic debug: no hw decoder modules matched
avcodec generic warning: plane 0 not aligned
avcodec generic warning: disabling direct rendering
stream_out_transcode stream out debug: decoder aspect is 1.761468:1
stream_out_transcode stream out debug: source pixel aspect is 0.990826:1
stream_out_transcode stream out debug: scaled pixel aspect is 0.990826:1
stream_out_transcode stream out debug: source 1920x1080, destination 1920x1080
stream_out_transcode stream out debug: source fps 30/1, destination 30/1
stream_out_transcode stream out: input interval 33333 (base 1)
stream_out_transcode stream out: output interval 33333 (base 1)
stream_out_transcode stream out debug: encoder aspect is 1920:1090
core filter debug: looking for video filter2 module matching "any": 58 candidates
swscale filter debug: 1920x1080 (1920x1090) chroma: J420 -> 1920x1080 (1920x1090) chroma: RV24 with scaling using Bicubic (good quality)
core filter debug: using video filter2 module "swscale"
core stream out debug: Filter 'Swscale' (0089a2cc) appended to chain
stream_out_transcode stream out debug: destination (after video filters) 1920x1090
core encoder debug: looking for encoder module matching "any": 20 candidates
avcodec encoder debug: CPU flags: 0x0107d3db
avcodec encoder debug: Time base for probing setted to 1/30
avcodec encoder debug: Time base set to 1/30
avcodec encoder debug: found encoder Raw video
core encoder debug: using encoder module "avcodec"
stream_out_transcode stream out warning: Reseting video sync
stream_out_transcode stream out warning: Reseting video sync
stream_out_transcode stream out warning: Reseting video sync
stream_out_transcode stream out warning: Reseting video sync
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518755, last: 1518769)
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518756, last: 1518769)
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518757, last: 1518769)
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518758, last: 1518769)
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518759, last: 1518769)
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518760, last: 1518769)
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518761, last: 1518769)
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518762, last: 1518769)
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518763, last: 1518769)
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518764, last: 1518769)
stream_out_transcode stream out warning: Reseting video sync
stream_out_transcode stream out warning: Reseting video sync
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518784, last: 1518795)
live555 demux debug: tk->rtpSource->hasBeenSynchronizedUsingRTCP()
core input error: ES_OUT_RESET_PCR called
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518785, last: 1518795)
core input debug: Buffering 0%
core input debug: Buffering 3%
core input debug: Buffering 6%
core input debug: Buffering 10%
core input debug: Buffering 13%
core input debug: Buffering 20%
core input debug: Buffering 23%
core input debug: Buffering 26%
core input debug: Buffering 30%
core input debug: Buffering 33%
core input debug: Buffering 40%
core input debug: Buffering 43%
core input debug: Buffering 46%
core input debug: Buffering 50%
core input debug: Buffering 53%
core input debug: Buffering 60%
core input debug: Buffering 63%
core input debug: Buffering 66%
core input debug: Buffering 70%
core input debug: Buffering 73%
core input debug: Buffering 80%
core input debug: Buffering 83%
core input debug: Buffering 86%
core input debug: Buffering 90%
core input debug: Buffering 93%
core input debug: Stream buffering done (1002 ms in 817 ms)
core input debug: Decoder wait done in 0 ms
stream_out_transcode stream out warning: Reseting video sync
stream_out_transcode stream out warning: Reseting video sync
stream_out_transcode stream out warning: Reseting video sync
stream_out_transcode stream out warning: Reseting video sync
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518834, last: 1518837)
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518835, last: 1518837)
avcodec encoder warning: almost fed libavcodec with a frame in the past (current: 1518836, last: 1518837)
avcodec encoder warning: almost fed libavcodec with two frames with the same PTS (1518837)
stream_out_transcode stream out warning: Reseting video sync
stream_out_transcode stream out warning: Reseting video sync -
OpenCV in Python on Windows does not report correct video properties from VideoReader
24 décembre 2015, par Mircea DavidescuI am running into a problem with using VideoReader in OpenCV with Python. Many of the properties that I should be able to get from the video reader are either somehow invalid (returning 0), or return the wrong number. For instance.
vidFile = cv2.VideoCapture('movie.avi')
vidFile.get(cv2.CAP_PROP_FRAME_COUNT)
vidFile.get(cv2.CAP_PROP_FPS)The first get command returns a wrong value, while the second get command returns 0. The output of the
ffprobe
command is given below :built with gcc 5.2.0 (GCC)
configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls
--enable-iconv --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libdcadec --enable-libfreetype --enable-libgme --enable-libgsm
--enable-libilbc --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus
--enable-librtmp --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab
--enable-libvo-aacenc --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265
--enable-libxavs --enable-libxvid --enable-lzma --enable-decklink --enable-zlib
libavutil 55. 5.100 / 55. 5.100
libavcodec 57. 12.100 / 57. 12.100
libavformat 57. 11.100 / 57. 11.100
libavdevice 57. 0.100 / 57. 0.100
libavfilter 6. 14.101 / 6. 14.101
libswscale 4. 0.100 / 4. 0.100
libswresample 2. 0.100 / 2. 0.100
libpostproc 54. 0.100 / 54. 0.100
Input #0, avi, from 'movie.avi':
Metadata:
encoder : Lavf55.0.100
Duration: 00:31:59.97, start: 0.000000, bitrate: 24321 kb/s
Stream #0:0: Video: mjpeg (MJPG / 0x47504A4D), yuvj420p(pc, bt470bg/unknown/unknown), 1392x1040 [SAR 1:1 DAR 87:65], 24316 kb/s, 30 fps, 30 tbr, 30 tbn,
30 tbcI am running a Windows 10 machine with Python 2.7.11 (Anaconda 2.4.1 64-bit). I have installed OpenCV 3.0.0 according the instructions provided here. Because I am using the VideoReader feature I also added C :\opencv\sources\3rdparty\ffmpeg to the system PATH and renamed both opencv_ffmpeg300.dll and opencv_ffmpeg_x64.dll to opencv_ffmpeg300.dll and opencv_ffmpeg300_64.dll respectively, as specified here.
Thank you for your help with this problem !