
Recherche avancée
Autres articles (78)
-
Organiser par catégorie
17 mai 2013, parDans MédiaSPIP, une rubrique a 2 noms : catégorie et rubrique.
Les différents documents stockés dans MédiaSPIP peuvent être rangés dans différentes catégories. On peut créer une catégorie en cliquant sur "publier une catégorie" dans le menu publier en haut à droite ( après authentification ). Une catégorie peut être rangée dans une autre catégorie aussi ce qui fait qu’on peut construire une arborescence de catégories.
Lors de la publication prochaine d’un document, la nouvelle catégorie créée sera proposée (...) -
Récupération d’informations sur le site maître à l’installation d’une instance
26 novembre 2010, parUtilité
Sur le site principal, une instance de mutualisation est définie par plusieurs choses : Les données dans la table spip_mutus ; Son logo ; Son auteur principal (id_admin dans la table spip_mutus correspondant à un id_auteur de la table spip_auteurs)qui sera le seul à pouvoir créer définitivement l’instance de mutualisation ;
Il peut donc être tout à fait judicieux de vouloir récupérer certaines de ces informations afin de compléter l’installation d’une instance pour, par exemple : récupérer le (...) -
Demande de création d’un canal
12 mars 2010, parEn fonction de la configuration de la plateforme, l’utilisateur peu avoir à sa disposition deux méthodes différentes de demande de création de canal. La première est au moment de son inscription, la seconde, après son inscription en remplissant un formulaire de demande.
Les deux manières demandent les mêmes choses fonctionnent à peu près de la même manière, le futur utilisateur doit remplir une série de champ de formulaire permettant tout d’abord aux administrateurs d’avoir des informations quant à (...)
Sur d’autres sites (4819)
-
ffmpeg - android ndk build assembler messages bad instruction
17 septembre 2016, par Madhavan MalolanI have compiled the latest ffmpeg source using the following build script adapted from Telegram :
#!/bin/bash
#apply fix http://permalink.gmane.org/gmane.comp.video.ffmpeg.devel/203198
function build_one {
echo "Cleaning..."
make clean
echo "Configuring..."
./configure \
--cc=$CC \
--nm=$NM \
--enable-stripping \
--arch=$ARCH \
--cpu=$CPU \
--target-os=linux \
--enable-cross-compile \
--yasmexe=$NDK/prebuilt/darwin-x86_64/bin/yasm \
--prefix=$PREFIX \
--enable-pic \
--disable-shared \
--enable-static \
--cross-prefix=$CROSS_PREFIX \
--sysroot=$PLATFORM \
--extra-cflags="-Os -DANDROID $OPTIMIZE_CFLAGS -fPIE -pie --static" \
--extra-ldflags="-Wl,-rpath-link=$PLATFORM/usr/lib -L$PLATFORM/usr/lib -nostdlib -lc -lm -ldl" \
--extra-libs="-lgcc" \
\
--enable-version3 \
--enable-gpl \
\
--disable-doc \
--disable-avx \
\
--disable-everything \
--disable-network \
--disable-zlib \
--disable-debug \
--disable-programs \
--disable-network \
\
--enable-pthreads \
--enable-protocol=file \
--enable-decoder=h264 \
--enable-decoder=gif \
--enable-demuxer=mov \
--enable-demuxer=gif \
--enable-hwaccels \
--enable-runtime-cpudetect \
--enable-asm \
$ADDITIONAL_CONFIGURE_FLAG
#echo "continue?"
#read
make -j8 install
}
NDK=~/Downloads/android-ndk-r12b/
#arm platform
PLATFORM=$NDK/platforms/android-9/arch-arm
PREBUILT=$NDK/toolchains/arm-linux-androideabi-4.9/prebuilt/darwin-x86_64
LD=$PREBUILT/bin/arm-linux-androideabi-ld
AR=$PREBUILT/bin/arm-linux-androideabi-ar
NM=$PREBUILT/bin/arm-linux-androideabi-nm
GCCLIB=$PREBUILT/lib/gcc/arm-linux-androideabi/4.9/libgcc.a
ARCH=arm
CC=$PREBUILT/bin/arm-linux-androideabi-gcc
CROSS_PREFIX=$PREBUILT/bin/arm-linux-androideabi-
#arm v5
CPU=armv5te
OPTIMIZE_CFLAGS="-marm -march=$CPU"
PREFIX=./android/$CPU
ADDITIONAL_CONFIGURE_FLAG="--disable-armv6 --disable-armv6t2 --disable-vfp --disable-neon"
build_one
#arm v7n
CPU=armv7-a
OPTIMIZE_CFLAGS="-marm -march=$CPU"
PREFIX=./android/$CPU
ADDITIONAL_CONFIGURE_FLAG=--enable-neon
build_one
#x86 platform
PLATFORM=$NDK/platforms/android-9/arch-x86
PREBUILT=$NDK/toolchains/x86-4.9/prebuilt/darwin-x86_64
LD=$PREBUILT/bin/i686-linux-android-ld
AR=$PREBUILT/bin/i686-linux-android-ar
NM=$PREBUILT/bin/i686-linux-android-nm
GCCLIB=$PREBUILT/lib/gcc/i686-linux-android/4.9/libgcc.a
ARCH=x86
CC=$PREBUILT/bin/i686-linux-android-gcc
CROSS_PREFIX=$PREBUILT/bin/i686-linux-android-
CPU=i686
OPTIMIZE_CFLAGS="-march=$CPU"
PREFIX=./android/$CPU
ADDITIONAL_CONFIGURE_FLAG="--disable-mmx --disable-yasm"
build_oneI copied the contents of the android/ folder generated to jni/ffmpeg/.
I then tried to do a ndk-build, which fails with an error.The Android.mk file is as follows :
LOCAL_PATH := $(call my-dir)
LOCAL_MODULE := avutil
LOCAL_MODULE_FILENAME := libavutil
LOCAL_SRC_FILES := ./ffmpeg/armv7-a/lib/libavutil.a
include $(PREBUILT_STATIC_LIBRARY)
include $(CLEAR_VARS)
LOCAL_MODULE := avformat
LOCAL_MODULE_FILENAME := libavformat
LOCAL_SRC_FILES := ./ffmpeg/armv7-a/lib/libavformat.a
include $(PREBUILT_STATIC_LIBRARY)
include $(CLEAR_VARS)
LOCAL_MODULE := avcodec
LOCAL_MODULE_FILENAME := libavcodec
LOCAL_SRC_FILES := ./ffmpeg/armv7-a/lib/libavcodec.a
include $(PREBUILT_STATIC_LIBRARY)
include $(CLEAR_VARS)
LOCAL_MODULE := avdevice
LOCAL_MODULE_FILENAME := libavdevice
LOCAL_SRC_FILES := ./ffmpeg/armv7-a/lib/libavdevice.a
include $(PREBUILT_STATIC_LIBRARY)
include $(CLEAR_VARS)
LOCAL_MODULE := avfilter
LOCAL_MODULE_FILENAME := libavfilter
LOCAL_SRC_FILES := ./ffmpeg/armv7-a/lib/libavfilter.a
include $(PREBUILT_STATIC_LIBRARY)
include $(CLEAR_VARS)
LOCAL_MODULE := postproc
LOCAL_MODULE_FILENAME := libpostproc
LOCAL_SRC_FILES := ./ffmpeg/armv7-a/lib/libpostproc.a
include $(PREBUILT_STATIC_LIBRARY)
include $(CLEAR_VARS)
LOCAL_MODULE := swresample
LOCAL_MODULE_FILENAME := libswresample
LOCAL_SRC_FILES := ./ffmpeg/armv7-a/lib/libswresample.a
include $(PREBUILT_STATIC_LIBRARY)
include $(CLEAR_VARS)
LOCAL_MODULE := swscale
LOCAL_MODULE_FILENAME := libswscale
LOCAL_SRC_FILES := ./ffmpeg/armv7-a/lib/libswscale.a
include $(PREBUILT_STATIC_LIBRARY)
include $(CLEAR_VARS)
LOCAL_PRELINK_MODULE := false
LOCAL_MODULE := ffmpeg
LOCAL_CFLAGS := -w -std=c11 -Os -DNULL=0 -DSOCKLEN_T=socklen_t -DLOCALE_NOT_USED -D_LARGEFILE_SOURCE=1 -D_FILE_OFFSET_BITS=64
LOCAL_CFLAGS += -Drestrict='' -D__EMX__ -DOPUS_BUILD -DFIXED_POINT -DUSE_ALLOCA -DHAVE_LRINT -DHAVE_LRINTF -fno-math-errno
LOCAL_CFLAGS += -DANDROID_NDK -DDISABLE_IMPORTGL -fno-strict-aliasing -fprefetch-loop-arrays -DAVOID_TABLES -DANDROID_TILE_BASED_DECODE -DANDROID_ARMV6_IDCT -ffast-math -D__STDC_CONSTANT_MACROS
LOCAL_CPPFLAGS := -DBSD=1 -ffast-math -Os -funroll-loops -std=c++11
LOCAL_LDLIBS := -ljnigraphics -llog -lz -latomic
LOCAL_STATIC_LIBRARIES := avformat avcodec avutil avfilter avdevice postproc swresample swscale
LOCAL_SRC_FILES := ffmpeg.c
include $(BUILD_SHARED_LIBRARY)The error thrown is :
[armeabi-v7a] Compile thumb : ffmpeg <= ffmpeg.c
/var/folders/2p/0jqlz1c94t537_53qn3h8v9h0000gn/T//cc8Tnpth.s :
Assembler messages :
/var/folders/2p/0jqlz1c94t537_53qn3h8v9h0000gn/T//cc8Tnpth.s:4421 :
Error : bad instructioncmovg r3,r8'
/var/folders/2p/0jqlz1c94t537_53qn3h8v9h0000gn/T//cc8Tnpth.s:4422:
Error: bad instructioncmovg r2,r3’
/var/folders/2p/0jqlz1c94t537_53qn3h8v9h0000gn/T//cc8Tnpth.s:4424 :
Error : bad instructioncmovl r1,r3'
/var/folders/2p/0jqlz1c94t537_53qn3h8v9h0000gn/T//cc8Tnpth.s:4426:
Error: bad instructioncmovg r3,r8’ make : ***
[path/to/app/obj/local/armeabi-v7a/objs/ffmpeg/ffmpeg.o]
Error 1I am guessing i got the compiler wrong somewhere. I am trying to build on a mac. Is there something i am missing ? I am trying to build only for armeabi-v7a.
-
Missing packets when transcoding using ffmpeg
23 février 2021, par Adam SzmydI have very weird issue with trans-coding
opus
to any other format usingffmpeg
. I example it on transcoding toflac
as this is what I'm currently using.

So I have this one example
opus
file that after processing viaffmpeg
kinda gets shorten like if the ffmpeg would drop some packets/data out of it.

I wouldn't mind if ffmpeg was cleaning up some redundant stuff but in practice this thing is making my output file of multiple streams out of sync so at some point audio tracks gets overlapping each other.


So I have this input
input.opus
file that's length is00:00:05.78
and when i pass it through ffmpeg like this :

$ ffmpeg -i input.opus -c flac output.flac
ffmpeg version 4.3.1 Copyright (c) 2000-2020 the FFmpeg developers
 built with gcc 10 (GCC)
 configuration: --prefix=/usr --bindir=/usr/bin --datadir=/usr/share/ffmpeg --docdir=/usr/share/doc/ffmpeg --incdir=/usr/include/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64 --optflags='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection' --extra-ldflags='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld ' --extra-cflags=' ' --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libvo-amrwbenc --enable-version3 --enable-bzlib --disable-crystalhd --enable-fontconfig --enable-frei0r --enable-gcrypt --enable-gnutls --enable-ladspa --enable-libaom --enable-libdav1d --enable-libass --enable-libbluray --enable-libcdio --enable-libdrm --enable-libjack --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-liblensfun --enable-libmp3lame --enable-libmysofa --enable-nvenc --enable-openal --enable-opencl --enable-opengl --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librsvg --enable-librav1e --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libvorbis --enable-libv4l2 --enable-libvidstab --enable-libvmaf --enable-version3 --enable-vapoursynth --enable-libvpx --enable-vulkan --enable-libglslang --enable-libx264 --enable-libx265 --enable-libxvid --enable-libzimg --enable-libzvbi --enable-avfilter --enable-avresample --enable-libmodplug --enable-postproc --enable-pthreads --disable-static --enable-shared --enable-gpl --disable-debug --disable-stripping --shlibdir=/usr/lib64 --enable-lto --enable-libmfx --enable-runtime-cpudetect
 libavutil 56. 51.100 / 56. 51.100
 libavcodec 58. 91.100 / 58. 91.100
 libavformat 58. 45.100 / 58. 45.100
 libavdevice 58. 10.100 / 58. 10.100
 libavfilter 7. 85.100 / 7. 85.100
 libavresample 4. 0. 0 / 4. 0. 0
 libswscale 5. 7.100 / 5. 7.100
 libswresample 3. 7.100 / 3. 7.100
 libpostproc 55. 7.100 / 55. 7.100
Input #0, ogg, from 'input.opus':
 Duration: 00:00:05.78, start: -0.017500, bitrate: 48 kb/s
 Stream #0:0: Audio: opus, 48000 Hz, mono, fltp
 Metadata:
 DURATION : 00:00:05.836000000
 encoder : Lavc58.91.100 opus
Stream mapping:
 Stream #0:0 -> #0:0 (opus (native) -> flac (native))
Press [q] to stop, [?] for help
[flac @ 0x55f94c9c2f40] encoding as 24 bits-per-sample
Output #0, flac, to 'output.flac':
 Metadata:
 encoder : Lavf58.45.100
 Stream #0:0: Audio: flac, 48000 Hz, mono, s32 (24 bit), 128 kb/s
 Metadata:
 DURATION : 00:00:05.836000000
 encoder : Lavc58.91.100 flac
size= 393kB time=00:00:05.79 bitrate= 555.7kbits/s speed= 373x 
video:0kB audio:385kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 2.102753%



interestingly ffmpeg above shows that output should get
00:00:05.79
duration but when checking it with ffprobe, its shorter by 50ms :

$ ffprobe -hide_banner output.flac
Input #0, flac, from 'output.flac':
 Metadata:
 encoder : Lavf58.45.100
 Duration: 00:00:05.73, start: 0.000000, bitrate: 561 kb/s
 Stream #0:0: Audio: flac, 48000 Hz, mono, s32 (24 bit)



It may seem silly small difference but I intentionally cut the file to be 5s long to keep troubleshooting easier. Source file is 30mins and I loose 1min out of it during that process so it is real.


ffmpeg version 4.3.1


How can i troubleshoot this ? When i try with
-loglevel trace
I noticed these few logs that looks "suspicious" :

[opus @ 0x555a5abe6c40] skip 0 / discard 192 samples due to side data
[opus @ 0x555a5abe6c40] discard 192/960 samples



But haven't found a way to stop it from discarding these samples (not even sure it is causing that..)


I would appreciate any help or point troubleshooting direction.


-
Map streams in ffmpeg based on title (to remove language variant)
16 octobre 2024, par MappaMI have a few video files with English audio track and French audio track, because the family wants French and I prefer VO. With ffmpeg I can easily filter all tracks to keep eng and fre, the problem is there are multiple french dialects, one of them being Candian (VFQ).


Therefore, with the following input streams :


Stream #0:1(fre): Audio: eac3, 48000 Hz, 5.1(side), fltp, 768 kb/s (default)
 Metadata:
 title : E-AC3 VFF
 Stream #0:2(fre): Subtitle: subrip (default) (forced)
 Metadata:
 title : FORCED VFF
 Stream #0:3(fre): Audio: ac3, 48000 Hz, 5.1(side), fltp, 384 kb/s
 Metadata:
 title : AC3 VFQ
 Stream #0:4(fre): Subtitle: subrip
 Metadata:
 title : FORCED VFQ
 Stream #0:5(eng): Audio: eac3, 48000 Hz, 5.1(side), fltp, 768 kb/s
 Metadata:
 title : E-AC3 VO



The command
-map 0:v: -map 0:m:language:eng -map 0:m:language:fre
does not filter out anything, and I keep both audio which is wasteful. The only metadata that could be used to filter seems to be the title.