
Recherche avancée
Médias (39)
-
Stereo master soundtrack
17 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Audio
-
ED-ME-5 1-DVD
11 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Audio
-
1,000,000
27 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Demon Seed
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
The Four of Us are Dying
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Corona Radiata
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
Autres articles (36)
-
MediaSPIP Core : La Configuration
9 novembre 2010, parMediaSPIP Core fournit par défaut trois pages différentes de configuration (ces pages utilisent le plugin de configuration CFG pour fonctionner) : une page spécifique à la configuration générale du squelettes ; une page spécifique à la configuration de la page d’accueil du site ; une page spécifique à la configuration des secteurs ;
Il fournit également une page supplémentaire qui n’apparait que lorsque certains plugins sont activés permettant de contrôler l’affichage et les fonctionnalités spécifiques (...) -
Le plugin : Podcasts.
14 juillet 2010, parLe problème du podcasting est à nouveau un problème révélateur de la normalisation des transports de données sur Internet.
Deux formats intéressants existent : Celui développé par Apple, très axé sur l’utilisation d’iTunes dont la SPEC est ici ; Le format "Media RSS Module" qui est plus "libre" notamment soutenu par Yahoo et le logiciel Miro ;
Types de fichiers supportés dans les flux
Le format d’Apple n’autorise que les formats suivants dans ses flux : .mp3 audio/mpeg .m4a audio/x-m4a .mp4 (...) -
Emballe médias : à quoi cela sert ?
4 février 2011, parCe plugin vise à gérer des sites de mise en ligne de documents de tous types.
Il crée des "médias", à savoir : un "média" est un article au sens SPIP créé automatiquement lors du téléversement d’un document qu’il soit audio, vidéo, image ou textuel ; un seul document ne peut être lié à un article dit "média" ;
Sur d’autres sites (5846)
-
FFMPEG unwanted rotation
5 mars 2015, par BenWhen I add a watermark image with a landscape orientation to a video that has a portrait orientation the video automatically rotates to landscape. How do I prevent this ? Also, the audio file isn’t being merged into the output. How can I include the audio.mp3 to be the sole audio track ?
ffmpeg -i 1425500438.MOV -i hashtag.png -itsoffset 00:00:07 -i audio.mp3 -filter_complex "[0:v]curves=preset=vintage[a];[a][1:v]overlay=10:10[out]" -vcodec libx264 -pix_fmt yuv420p -ss 0:0:07 -t 14 -map "[out]" -y processed.mov
EDIT****
ffmpeg version 2.1.4 Copyright (c) 2000-2014 the FFmpeg developers
built on Mar 19 2014 12:48:02 with Apple LLVM version 5.1 (clang-503.0.38) (based on LLVM 3.4svn)
configuration: --prefix=/usr/local/Cellar/ffmpeg/2.1.4 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-nonfree --enable-hardcoded-tables --enable-avresample --enable-vda --cc=clang --host-cflags= --host-ldflags= --enable-libx264 --enable-libfaac --enable-libmp3lame --enable-libxvid --enable-libfreetype --enable-libvorbis --enable-libvpx --enable-librtmp --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libvo-aacenc --enable-libass --enable-ffplay --enable-libspeex --enable-libschroedinger --enable-libfdk-aac --enable-libopus --enable-frei0r --enable-libopenjpeg --extra-cflags='-I/usr/local/Cellar/openjpeg/1.5.1/include/openjpeg-1.5 '
libavutil 52. 48.101 / 52. 48.101
libavcodec 55. 39.101 / 55. 39.101
libavformat 55. 19.104 / 55. 19.104
libavdevice 55. 5.100 / 55. 5.100
libavfilter 3. 90.100 / 3. 90.100
libavresample 1. 1. 0 / 1. 1. 0
libswscale 2. 5.101 / 2. 5.101
libswresample 0. 17.104 / 0. 17.104
libpostproc 52. 3.100 / 52. 3.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '1425500438.MOV':
Metadata:
major_brand : qt
minor_version : 0
compatible_brands: qt
creation_time : 2015-03-04 20:20:14
encoder : 8.1.2
encoder-eng : 8.1.2
date : 2015-03-04T14:20:14-0600
date-eng : 2015-03-04T14:20:14-0600
model : iPhone 6
model-eng : iPhone 6
make : Apple
make-eng : Apple
Duration: 00:00:10.56, start: 0.000000, bitrate: 703 kb/s
Stream #0:0(und): Video: h264 (Baseline) (avc1 / 0x31637661), yuv420p(tv, smpte170m), 480x360, 696 kb/s, 30.02 fps, 30.08 tbr, 600 tbn, 1200 tbc (default)
Metadata:
rotate : 90
creation_time : 2015-03-04 20:20:14
handler_name : Core Media Data Handler
Input #1, image2, from 'hashtag.png':
Duration: 00:00:00.04, start: 0.000000, bitrate: N/A
Stream #1:0: Video: png, rgba, 131x29, 25 tbr, 25 tbn, 25 tbc
Input #2, mp3, from 'audio.mp3':
Metadata:
encoder : Lavf55.19.104
Duration: 00:00:10.44, start: 0.000000, bitrate: 128 kb/s
Stream #2:0: Audio: mp3, 16000 Hz, stereo, s16p, 128 kb/s
[libx264 @ 0x7f9894017200] using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.2 AVX AVX2 FMA3 BMI1 BMI2
[libx264 @ 0x7f9894017200] profile High, level 3.0
[libx264 @ 0x7f9894017200] 264 - core 125 - H.264/MPEG-4 AVC codec - Copyleft 2003-2012 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=12 lookahead_threads=2 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=crf mbtree=1 crf=23.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, mov, to 'processed.mov':
Metadata:
major_brand : qt
minor_version : 0
compatible_brands: qt
make-eng : Apple
make : Apple
encoder-eng : 8.1.2
date : 2015-03-04T14:20:14-0600
date-eng : 2015-03-04T14:20:14-0600
model : iPhone 6
model-eng : iPhone 6
encoder : Lavf55.19.104
Stream #0:0: Video: h264 (libx264) (avc1 / 0x31637661), yuv420p, 480x360, q=-1--1, 11552 tbn, 30.08 tbc (default)
Stream mapping:
Stream #0:0 (h264) -> curves
Stream #1:0 (png) -> overlay:overlay
overlay -> Stream #0:0 (libx264)
Press [q] to stop, [?] for help
frame= 422 fps=413 q=-1.0 Lsize= 361kB time=00:00:13.96 bitrate= 211.9kbits/s dup=303 drop=0
video:356kB audio:0kB subtitle:0 global headers:0kB muxing overhead 1.574185%
[libx264 @ 0x7f9894017200] frame I:2 Avg QP:20.09 size: 19764
[libx264 @ 0x7f9894017200] frame P:134 Avg QP:22.29 size: 2248
[libx264 @ 0x7f9894017200] frame B:286 Avg QP:28.02 size: 79
[libx264 @ 0x7f9894017200] consecutive B-frames: 9.2% 0.0% 3.6% 87.2%
[libx264 @ 0x7f9894017200] mb I I16..4: 6.6% 45.0% 48.4%
[libx264 @ 0x7f9894017200] mb P I16..4: 1.8% 2.4% 0.7% P16..4: 40.8% 13.6% 4.5% 0.0% 0.0% skip:36.1%
[libx264 @ 0x7f9894017200] mb B I16..4: 0.0% 0.0% 0.0% B16..8: 10.9% 0.1% 0.0% direct: 0.0% skip:89.0% L0:56.5% L1:42.3% BI: 1.2%
[libx264 @ 0x7f9894017200] 8x8 transform intra:47.6% inter:61.5%
[libx264 @ 0x7f9894017200] coded y,uvDC,uvAC intra: 51.3% 81.4% 36.7% inter: 5.6% 8.5% 0.5%
[libx264 @ 0x7f9894017200] i16 v,h,dc,p: 21% 27% 12% 40%
[libx264 @ 0x7f9894017200] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 24% 27% 19% 5% 4% 4% 7% 5% 6%
[libx264 @ 0x7f9894017200] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 35% 22% 12% 4% 5% 5% 6% 4% 6%
[libx264 @ 0x7f9894017200] i8c dc,h,v,p: 40% 28% 22% 10%
[libx264 @ 0x7f9894017200] Weighted P-Frames: Y:16.4% UV:10.4%
[libx264 @ 0x7f9894017200] ref P L0: 73.7% 12.2% 11.7% 2.3% 0.2%
[libx264 @ 0x7f9894017200] ref B L0: 93.5% 5.8% 0.7%
[libx264 @ 0x7f9894017200] ref B L1: 97.2% 2.8%
[libx264 @ 0x7f9894017200] kb/s:207.25 -
iOS Build PJSIP with FFmpeg+libx264
22 février 2021, par MeonardoI have built the FFmpeg with libx264 into static libs, here is my directory tree.


./ffmpeg
├── include
│   ├── libavcodec
│   │   ├── ac3_parser.h
│   │   ├── adts_parser.h
│   │   ├── avcodec.h
│   │   ├── avdct.h
│   │   ├── avfft.h
│   │   ├── bsf.h
│   │   ├── codec.h
│   │   ├── codec_desc.h
│   │   ├── codec_id.h
│   │   ├── codec_par.h
│   │   ├── d3d11va.h
│   │   ├── dirac.h
│   │   ├── dv_profile.h
│   │   ├── dxva2.h
│   │   ├── jni.h
│   │   ├── mediacodec.h
│   │   ├── packet.h
│   │   ├── qsv.h
│   │   ├── vaapi.h
│   │   ├── vdpau.h
│   │   ├── version.h
│   │   ├── videotoolbox.h
│   │   ├── vorbis_parser.h
│   │   └── xvmc.h
│   ├── libavdevice
│   │   ├── avdevice.h
│   │   └── version.h
│   ├── libavfilter
│   │   ├── avfilter.h
│   │   ├── buffersink.h
│   │   ├── buffersrc.h
│   │   └── version.h
│   ├── libavformat
│   │   ├── avformat.h
│   │   ├── avio.h
│   │   └── version.h
│   ├── libavutil
│   │   ├── adler32.h
│   │   ├── aes.h
│   │   ├── aes_ctr.h
│   │   ├── attributes.h
│   │   ├── audio_fifo.h
│   │   ├── avassert.h
│   │   ├── avconfig.h
│   │   ├── avstring.h
│   │   ├── avutil.h
│   │   ├── base64.h
│   │   ├── blowfish.h
│   │   ├── bprint.h
│   │   ├── bswap.h
│   │   ├── buffer.h
│   │   ├── camellia.h
│   │   ├── cast5.h
│   │   ├── channel_layout.h
│   │   ├── common.h
│   │   ├── cpu.h
│   │   ├── crc.h
│   │   ├── des.h
│   │   ├── dict.h
│   │   ├── display.h
│   │   ├── dovi_meta.h
│   │   ├── downmix_info.h
│   │   ├── encryption_info.h
│   │   ├── error.h
│   │   ├── eval.h
│   │   ├── ffversion.h
│   │   ├── fifo.h
│   │   ├── file.h
│   │   ├── frame.h
│   │   ├── hash.h
│   │   ├── hdr_dynamic_metadata.h
│   │   ├── hmac.h
│   │   ├── hwcontext.h
│   │   ├── hwcontext_cuda.h
│   │   ├── hwcontext_d3d11va.h
│   │   ├── hwcontext_drm.h
│   │   ├── hwcontext_dxva2.h
│   │   ├── hwcontext_mediacodec.h
│   │   ├── hwcontext_opencl.h
│   │   ├── hwcontext_qsv.h
│   │   ├── hwcontext_vaapi.h
│   │   ├── hwcontext_vdpau.h
│   │   ├── hwcontext_videotoolbox.h
│   │   ├── hwcontext_vulkan.h
│   │   ├── imgutils.h
│   │   ├── intfloat.h
│   │   ├── intreadwrite.h
│   │   ├── lfg.h
│   │   ├── log.h
│   │   ├── lzo.h
│   │   ├── macros.h
│   │   ├── mastering_display_metadata.h
│   │   ├── mathematics.h
│   │   ├── md5.h
│   │   ├── mem.h
│   │   ├── motion_vector.h
│   │   ├── murmur3.h
│   │   ├── opt.h
│   │   ├── parseutils.h
│   │   ├── pixdesc.h
│   │   ├── pixelutils.h
│   │   ├── pixfmt.h
│   │   ├── random_seed.h
│   │   ├── rational.h
│   │   ├── rc4.h
│   │   ├── replaygain.h
│   │   ├── ripemd.h
│   │   ├── samplefmt.h
│   │   ├── sha.h
│   │   ├── sha512.h
│   │   ├── spherical.h
│   │   ├── stereo3d.h
│   │   ├── tea.h
│   │   ├── threadmessage.h
│   │   ├── time.h
│   │   ├── timecode.h
│   │   ├── timestamp.h
│   │   ├── tree.h
│   │   ├── twofish.h
│   │   ├── tx.h
│   │   ├── version.h
│   │   ├── video_enc_params.h
│   │   └── xtea.h
│   ├── libpostproc
│   │   ├── postprocess.h
│   │   └── version.h
│   ├── libswresample
│   │   ├── swresample.h
│   │   └── version.h
│   ├── libswscale
│   │   ├── swscale.h
│   │   └── version.h
│   └── libx264
│   ├── x264.h
│   └── x264_config.h
└── lib
 ├── libavcodec.a
 ├── libavdevice.a
 ├── libavfilter.a
 ├── libavformat.a
 ├── libavutil.a
 ├── libpostproc.a
 ├── libswresample.a
 ├── libswscale.a
 └── libx264.a



The final lib was created successfully, no error message in log file,
but when I import the lib to my Xcode Project,
the linker give me tons of errors(missing symbols like :
Undefined symbol: _pjsua_vid_codec_set_priority
).
I found thepjsua_vid.o
is very small(200Bytes) compare to my pjsip+openh264 build file(was 47KB), perhaps this is the reason cause the link error.

Here is my build log :
log_file


the build script I am using :


#!/bin/sh

# see http://stackoverflow.com/a/3915420/318790
function realpath { echo $(cd $(dirname "$1"); pwd)/$(basename "$1"); }
__FILE__=`realpath "$0"`
__DIR__=`dirname "${__FILE__}"`

# download
function download() {
 "${__DIR__}/download.sh" "$1" "$2" #--no-cache
}

BASE_DIR="$1"
PJSIP_URL="https://github.com/pjsip/pjproject/archive/2.10.zip"
#http://www.pjsip.org/release/2.8.0/pjproject-2.8.0.tar.bz2
PJSIP_DIR="$1/src"
LIB_PATHS=("pjlib/lib" \
 "pjlib-util/lib" \
 "pjmedia/lib" \
 "pjnath/lib" \
 "pjsip/lib" \
 "third_party/lib")

OPENSSL_PREFIX=
FFMPEG_PREFIX=
OPENH264_PREFIX=
OPUS_PREFIX=
while [ "$#" -gt 0 ]; do
 case $1 in
 --with-openssl)
 if [ "$#" -gt 1 ]; then
 OPENSSL_PREFIX=$(python -c "import os,sys; print os.path.realpath(sys.argv[1])" "$2")
 shift 2
 continue
 else
 echo 'ERROR: Must specify a non-empty "--with-openssl PREFIX" argument.' >&2
 exit 1
 fi
 ;;
 --with-openh264)
 if [ "$#" -gt 1 ]; then
 OPENH264_PREFIX=$(python -c "import os,sys; print os.path.realpath(sys.argv[1])" "$2")
 shift 2
 continue
 else
 echo 'ERROR: Must specify a non-empty "--with-openh264 PREFIX" argument.' >&2
 exit 1
 fi
 ;;
 --with-ffmpeg)
 if [ "$#" -gt 1 ]; then
 FFMPEG_PREFIX=$(python -c "import os,sys; print os.path.realpath(sys.argv[1])" "$2")
 shift 2
 continue
 else
 echo 'ERROR: Must specify a non-empty "--with-ffmpeg PREFIX" argument.' >&2
 exit 1
 fi
 ;;
 --with-opus)
 if [ "$#" -gt 1 ]; then
 OPUS_PREFIX=$(python -c "import os,sys; print os.path.realpath(sys.argv[1])" "$2")
 shift 2
 continue
 else
 echo 'ERROR: Must specify a non-empty "--with-opus PREFIX" argument.' >&2
 exit 1
 fi
 ;;
 esac

 shift
done

function config_site() {
 SOURCE_DIR=$1
 PJSIP_CONFIG_PATH="${SOURCE_DIR}/pjlib/include/pj/config_site.h"
 HAS_VIDEO=

 echo "Creating config_site.h ..."

 if [ -f "${PJSIP_CONFIG_PATH}" ]; then
 rm "${PJSIP_CONFIG_PATH}"
 fi

 echo "#define PJ_CONFIG_IPHONE 1" >> "${PJSIP_CONFIG_PATH}"
 echo "#define PJ_HAS_IPV6 1" >> "${PJSIP_CONFIG_PATH}" # Enable IPV6
 if [[ ${OPENH264_PREFIX} ]]; then
 # echo "#define PJMEDIA_HAS_VID_TOOLBOX_CODEC 1" >> "${PJSIP_CONFIG_PATH}"
 # echo "#define PJMEDIA_HAS_OPENH264_CODEC 1" >> "${PJSIP_CONFIG_PATH}"
 echo "#define PJMEDIA_HAS_FFMPEG_VID_CODEC 1" >> "${PJSIP_CONFIG_PATH}"
 HAS_VIDEO=1
 fi
 if [[ ${HAS_VIDEO} ]]; then
 echo "#define PJMEDIA_HAS_VIDEO 1" >> "${PJSIP_CONFIG_PATH}"
 echo "#define PJMEDIA_VIDEO_DEV_HAS_OPENGL 1" >> "${PJSIP_CONFIG_PATH}"
 echo "#define PJMEDIA_VIDEO_DEV_HAS_OPENGL_ES 1" >> "${PJSIP_CONFIG_PATH}"
 echo "#define PJMEDIA_VIDEO_DEV_HAS_IOS_OPENGL 1" >> "${PJSIP_CONFIG_PATH}"
 echo "#include <opengles></opengles>ES3/glext.h>" >> "${PJSIP_CONFIG_PATH}"
 fi
 echo "#include <pj></pj>config_site_sample.h>" >> "${PJSIP_CONFIG_PATH}"
}

function clean_libs () {
 ARCH=${1}
 for SRC_DIR in ${LIB_PATHS[*]}; do
 DIR="${PJSIP_DIR}/${SRC_DIR}"
 if [ -d "${DIR}" ]; then
 rm -rf "${DIR}"/*
 fi

 DIR="${PJSIP_DIR}/${SRC_DIR}-${ARCH}"
 if [ -d "${DIR}" ]; then
 rm -rf "${DIR}"
 fi
 done
}

function copy_libs () {
 ARCH=${1}

 for SRC_DIR in ${LIB_PATHS[*]}; do
 SRC_DIR="${PJSIP_DIR}/${SRC_DIR}"
 DST_DIR="${SRC_DIR}-${ARCH}"
 if [ -d "${DST_DIR}" ]; then
 rm -rf "${DST_DIR}"
 fi
 cp -R "${SRC_DIR}" "${DST_DIR}"
 rm -rf "${SRC_DIR}"/* # delete files because this directory will be used for the final lipo output
 done
}

function _build() {
 pushd . > /dev/null
 cd ${PJSIP_DIR}

 ARCH=$1
 LOG=${BASE_DIR}/${ARCH}.log

 # configure
 CONFIGURE="./configure-iphone"
 if [[ ${OPENSSL_PREFIX} ]]; then
 CONFIGURE="${CONFIGURE} --with-ssl=${OPENSSL_PREFIX}"
 fi
 # if [[ ${OPENH264_PREFIX} ]]; then
 # CONFIGURE="${CONFIGURE} --with-openh264=${OPENH264_PREFIX}"
 # fi
 if [[ ${FFMPEG_PREFIX} ]]; then
 CONFIGURE="${CONFIGURE} --with-ffmpeg=${FFMPEG_PREFIX}"
 fi
 if [[ ${OPUS_PREFIX} ]]; then
 CONFIGURE="${CONFIGURE} --with-opus=${OPUS_PREFIX}"
 fi

 # flags
 if [[ ! ${CFLAGS} ]]; then
 export CFLAGS=
 fi
 if [[ ! ${LDFLAGS} ]]; then
 export LDFLAGS=
 fi
 if [[ ${OPENSSL_PREFIX} ]]; then
 export CFLAGS="${CFLAGS} -I${OPENSSL_PREFIX}/include"
 export LDFLAGS="${LDFLAGS} -L${OPENSSL_PREFIX}/lib"
 fi
 # if [[ ${OPENH264_PREFIX} ]]; then
 # export CFLAGS="${CFLAGS} -I${OPENH264_PREFIX}/include"
 # export LDFLAGS="${LDFLAGS} -L${OPENH264_PREFIX}/lib"
 # fi
 if [[ ${FFMPEG_PREFIX} ]]; then
 export CFLAGS="${CFLAGS} -I${FFMPEG_PREFIX}/include"
 export LDFLAGS="${LDFLAGS} -L${FFMPEG_PREFIX}/lib"
 fi
 export LDFLAGS="${LDFLAGS} -lstdc++"

 echo "Building for ${ARCH}..."

 clean_libs ${ARCH}

 make distclean > ${LOG} 2>&1
 ARCH="-arch ${ARCH}" ${CONFIGURE} >> ${LOG} 2>&1
 make dep >> ${LOG} 2>&1
 make clean >> ${LOG}
 make lib >> ${LOG} 2>&1

 copy_libs ${ARCH}
}

# function armv7() {
# export DEVPATH="`xcrun -sdk iphoneos --show-sdk-platform-path`/Developer"
# export CFLAGS="-miphoneos-version-min=8.0"
# export LDFLAGS=
# _build "armv7"
# }
# function armv7s() {
# export DEVPATH="`xcrun -sdk iphoneos --show-sdk-platform-path`/Developer"
# export CFLAGS="-miphoneos-version-min=8.0"
# export LDFLAGS=
# _build "armv7s"
# }
function arm64() {
 export DEVPATH="`xcrun -sdk iphoneos --show-sdk-platform-path`/Developer"
 export CFLAGS="-miphoneos-version-min=8.0"
 export LDFLAGS=
 _build "arm64"
}
function i386() {
 export DEVPATH="`xcrun -sdk iphonesimulator --show-sdk-platform-path`/Developer"
 export CFLAGS="-O2 -m32 -mios-simulator-version-min=8.0"
 export LDFLAGS="-O2 -m32 -mios-simulator-version-min=8.0"
 _build "i386"
}
function x86_64() {
 export DEVPATH="`xcrun -sdk iphonesimulator --show-sdk-platform-path`/Developer"
 export CFLAGS="-O2 -m32 -mios-simulator-version-min=8.0"
 export LDFLAGS="-O2 -m32 -mios-simulator-version-min=8.0"
 _build "x86_64"
}

function lipo() {
 TMP=`mktemp -t lipo`
 echo "Lipo libs... (${TMP})"

 for LIB_DIR in ${LIB_PATHS[*]}; do # loop over libs
 DST_DIR="${PJSIP_DIR}/${LIB_DIR}"

 # use the first architecture to find all libraries
 PATTERN_DIR="${DST_DIR}-$1"
 for PATTERN_FILE in `ls -l1 "${PATTERN_DIR}"`; do
 OPTIONS=""

 # loop over all architectures and collect the current library
 for ARCH in "$@"; do
 FILE="${DST_DIR}-${ARCH}/${PATTERN_FILE/-$1-/-${ARCH}-}"
 if [ -e "${FILE}" ]; then
 OPTIONS="$OPTIONS -arch ${ARCH} ${FILE}"
 fi
 done

 if [ "$OPTIONS" != "" ]; then
 OUTPUT_PREFIX=$(dirname "${DST_DIR}")
 OUTPUT="${OUTPUT_PREFIX}/lib/${PATTERN_FILE/-$1-/-}"

 OPTIONS="${OPTIONS} -create -output ${OUTPUT}"
 echo "$OPTIONS" >> "${TMP}"
 fi
 done
 done

 while read LINE; do
 xcrun -sdk iphoneos lipo ${LINE}
 done < "${TMP}"
}

# download "${PJSIP_URL}" "${PJSIP_DIR}"
config_site "${PJSIP_DIR}"
arm64 && i386 && x86_64
lipo arm64 i386 x86_64



Thanks for any advice.


-
Cannot use Mobile FFmpeg and LibVLCSharp together in Xamarin.Forms project
26 février 2021, par Travis PI am adding video stream capture functionality to a Xamarin Forms project. I am trying to use VLC's LibVLCSharp.Forms (https://github.com/videolan/libvlcsharp) package and the Mobile ffmpeg Xamarin wrapper package, Laerdal.Xamarin.FFmpeg.* (https://github.com/Laerdal/Laerdal.Xamarin.FFmpeg.iOS). However, the internal ffmpeg library from VLC is conflicting with the ffmpeg wrapper and is built with different flags which exclude functionality that I need.


For native development, it looks like you can configure a preferred library with the
OTHER_LDFLAGS
flag in thePods-<your app="app">.debug.xcconfig</your>
file but I don't see where to do that with Xamarin.Forms.
Source : https://github.com/tanersener/mobile-ffmpeg/wiki/Using-Multiple-FFmpeg-Implementations-In-The-Same-iOS-Application

How can I configure Xamarin iOS builds to prefer the mobile ffmpeg library over the VLC ffmpeg library ? If I am able to use the mobile ffmpeg library, will it cause issues with VLC ?


Here is a log message when I try to run commands with ffmpeg. As you can see, ffmpeg's internal library paths reference "vlc" :


FFmpegExecute: Command: -vsync 1 -i 'rtsp://wowzaec2demo.streamlock.net/vod/mp4:bigbuckbunny_115k.mov' -force_key_frames "expr: gte(t, n_forced * 2)" -strict experimental -f segment -segment_time 00:00:02 -segment_start_number 0 -reset_timestamps 1 -c:v copy -c:a copy '[path to temp]/tmp/VideoStream/%01d-record-temp.mp4'
Loaded mobile-ffmpeg-full-gpl-x86_64-4.4-lts-20200725
INFO: ffmpeg version v4.4-dev-416
INFO: Copyright (c) 2000-2020 the FFmpeg developers
INFO:
INFO: built with Apple LLVM version 7.3.0 (clang-703.0.31)
INFO: configuration: --sysroot=/Applications/Xcode-v7.3.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator9.3.sdk --prefix=/Users/taner/Projects/mobile-ffmpeg/prebuilt/ios-x86_64/ffmpeg --enable-version3 --arch=x86_64 --cpu=x86_64 --target-os=darwin --ar=/Applications/Xcode-v7.3.1.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar --cc=clang --cxx=clang++ --as='clang -arch x86_64 -target x86_64-ios-darwin -march=x86-64 -msse4.2 -mpopcnt -m64 -mtune=intel -DMOBILE_FFMPEG_X86_64 -Wno-unused-function -Wno-deprecated-declarations -fstrict-aliasing -DIOS -DMOBILE_FFMPEG_LTS -DMOBILE_FFMPEG_BUILD_DATE=20200725 -isysroot /Applications/Xcode-v7.3.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator9.3.sdk -O2 -mios-simulator-version-min=9.3 -I/Applications/Xcode-v7.3.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator9.3.sdk/usr/include' --ranlib=/Applications/Xcode-v7.3.1.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib --strip=/Applications/Xcode-v7.3.1.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/strip --disable-neon --enable-cross-compile --enable-pic --disable-asm --enable-inline-asm --enable-optimizations --enable-swscale --enable-static --disable-shared --enable-small --disable-v4l2-m2m --disable-outdev=v4l2 --disable-outdev=fbdev --disable-outdev=audiotoolbox --disable-indev=v4l2 --disable-indev=fbdev --disable-openssl --disable-xmm-clobber-test --disable-debug --disable-neon-clobber-test --disable-programs --disable-postproc --disable-doc --disable-htmlpages --disable-manpages --disable-podpages --disable-txtpages --disable-sndio --disable-schannel --disable-securetransport --disable-xlib --disable-cuda --disable-cuvid --disable-nvenc --disable-vaapi --disable-vdpau --disable-appkit --disable-alsa --disable-cuda --disable-cuvid --disable-nvenc --disable-vaapi --disable-vdpau --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-gmp --enable-gnutls --enable-libmp3lame --enable-libass --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libxml2 --enable-libopencore-amrnb --enable-libshine --enable-libspeex --enable-libwavpack --enable-libkvazaar --enable-libx264 --enable-gpl --enable-libxvid --enable-gpl --enable-libx265 --enable-gpl --enable-libvidstab --enable-gpl --enable-libilbc --enable-libopus --enable-libsnappy --enable-libsoxr --enable-libaom --enable-libtwolame --disable-sdl2 --enable-libvo-amrwbenc --enable-zlib --enable-audiotoolbox --enable-bzlib --enable-videotoolbox --disable-avfoundation --enable-iconv --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-gmp --enable-gnutls --enable-libmp3lame --enable-libass --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libxml2 --enable-libopencore-amrnb --enable-libshine --enable-libspeex --enable-libwavpack --enable-libkvazaar --enable-libx264 --enable-gpl --enable-libxvid --enable-gpl --enable-libx265 --enable-gpl --enable-libvidstab --enable-gpl --enable-libilbc --enable-libopus --enable-libsnappy --enable-libsoxr --enable-libaom --enable-libtwolame --disable-sdl2 --enable-libvo-amrwbenc --enable-zlib --enable-audiotoolbox --enable-bzlib --enable-videotoolbox --disable-avfoundation --enable-iconv --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-gmp --enable-gnutls --enable-libmp3lame --enable-libass --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libxml2 --enable-libopencore-amrnb --enable-libshine --enable-libspeex --enable-libwavpack --enable-libkvazaar --enable-libx264 --enable-gpl --enable-libxvid --enable-gpl --enable-libx265 --enable-gpl --enable-libvidstab --enable-gpl --enable-libilbc --enable-libopus --enable-libsnappy --enable-libsoxr --enable-libaom --enable-libtwolame --disable-sdl2 --enable-libvo-amrwbenc --enable-zlib --enable-audiotoolbox --enable-bzlib --enable-videotoolbox --disable-avfoundation --enable-iconv --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-gmp --enable-gnutls --enable-libmp3lame --enable-libass --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libxml2 --enable-libopencore-amrnb --enable-libshine --enable-libspeex --enable-libwavpack --enable-libkvazaar --enable-libx264 --enable-gpl --enable-libxvid --enable-gpl --enable-libx265 --enable-gpl --enable-libvidstab --enable-gpl --enable-libilbc --enable-libopus --enable-libsnappy --enable-libsoxr --enable-libaom --enable-libtwolame --disable-sdl2 --enable-libvo-amrwbenc --enable-zlib --enable-audiotoolbox --enable-bzlib --enable-videotoolbox --disable-avfoundation --enable-iconv
INFO: WARNING: library configuration mismatch
INFO: avutil configuration: --extra-ldflags='-arch x86_64 -v -Wl,-ios_simulator_version_min,8.4 -L/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64/lib -Wl,-ios_simulator_version_min,8.4' --cc=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang --pkg-config=pkg-config --disable-doc --disable-encoder=vorbis --disable-decoder=opus --enable-libgsm --disable-decoder=mlp --disable-demuxer=mlp --disable-parser=mlp --disable-debug --disable-avdevice --disable-devices --disable-avfilter --disable-filters --disable-protocol=concat --disable-bsfs --disable-bzlib --disable-libvpx --disable-avresample --enable-bsf=vp9_superframe --disable-swresample --disable-iconv --disable-avisynth --disable-nvenc --disable-linux-perf --disable-securetransport --enable-libopenjpeg --enable-libmp3lame --enable-cross-compile --disable-programs --arch=x86_64 --target-os=darwin --disable-lzma --cpu=core2 --enable-pic --extra-ldflags='-arch x86_64 -miphoneos-version-min=8.4 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.2.sdk -arch x86_64 -O3 -g -miphoneos-version-min=8.4 -arch x86_64 -miphoneos-version-min=8.4 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.2.sdk -arch x86_64 -O3 -g -miphoneos-version-min=8.4 -I/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64/include -g -O2 -I/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64/include' --enable-pthreads --nm= --ar=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar --prefix=/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64 --enable-static --disable-shared
INFO: avcodec configuration: --extra-ldflags='-arch x86_64 -v -Wl,-ios_simulator_version_min,8.4 -L/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64/lib -Wl,-ios_simulator_version_min,8.4' --cc=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang --pkg-config=pkg-config --disable-doc --disable-encoder=vorbis --disable-decoder=opus --enable-libgsm --disable-decoder=mlp --disable-demuxer=mlp --disable-parser=mlp --disable-debug --disable-avdevice --disable-devices --disable-avfilter --disable-filters --disable-protocol=concat --disable-bsfs --disable-bzlib --disable-libvpx --disable-avresample --enable-bsf=vp9_superframe --disable-swresample --disable-iconv --disable-avisynth --disable-nvenc --disable-linux-perf --disable-securetransport --enable-libopenjpeg --enable-libmp3lame --enable-cross-compile --disable-programs --arch=x86_64 --target-os=darwin --disable-lzma --cpu=core2 --enable-pic --extra-ldflags='-arch x86_64 -miphoneos-version-min=8.4 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.2.sdk -arch x86_64 -O3 -g -miphoneos-version-min=8.4 -arch x86_64 -miphoneos-version-min=8.4 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.2.sdk -arch x86_64 -O3 -g -miphoneos-version-min=8.4 -I/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64/include -g -O2 -I/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64/include' --enable-pthreads --nm= --ar=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar --prefix=/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64 --enable-static --disable-shared
INFO: avformat configuration: --extra-ldflags='-arch x86_64 -v -Wl,-ios_simulator_version_min,8.4 -L/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64/lib -Wl,-ios_simulator_version_min,8.4' --cc=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang --pkg-config=pkg-config --disable-doc --disable-encoder=vorbis --disable-decoder=opus --enable-libgsm --disable-decoder=mlp --disable-demuxer=mlp --disable-parser=mlp --disable-debug --disable-avdevice --disable-devices --disable-avfilter --disable-filters --disable-protocol=concat --disable-bsfs --disable-bzlib --disable-libvpx --disable-avresample --enable-bsf=vp9_superframe --disable-swresample --disable-iconv --disable-avisynth --disable-nvenc --disable-linux-perf --disable-securetransport --enable-libopenjpeg --enable-libmp3lame --enable-cross-compile --disable-programs --arch=x86_64 --target-os=darwin --disable-lzma --cpu=core2 --enable-pic --extra-ldflags='-arch x86_64 -miphoneos-version-min=8.4 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.2.sdk -arch x86_64 -O3 -g -miphoneos-version-min=8.4 -arch x86_64 -miphoneos-version-min=8.4 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.2.sdk -arch x86_64 -O3 -g -miphoneos-version-min=8.4 -I/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64/include -g -O2 -I/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64/include' --enable-pthreads --nm= --ar=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar --prefix=/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64 --enable-static --disable-shared
INFO: swscale configuration: --extra-ldflags='-arch x86_64 -v -Wl,-ios_simulator_version_min,8.4 -L/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64/lib -Wl,-ios_simulator_version_min,8.4' --cc=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang --pkg-config=pkg-config --disable-doc --disable-encoder=vorbis --disable-decoder=opus --enable-libgsm --disable-decoder=mlp --disable-demuxer=mlp --disable-parser=mlp --disable-debug --disable-avdevice --disable-devices --disable-avfilter --disable-filters --disable-protocol=concat --disable-bsfs --disable-bzlib --disable-libvpx --disable-avresample --enable-bsf=vp9_superframe --disable-swresample --disable-iconv --disable-avisynth --disable-nvenc --disable-linux-perf --disable-securetransport --enable-libopenjpeg --enable-libmp3lame --enable-cross-compile --disable-programs --arch=x86_64 --target-os=darwin --disable-lzma --cpu=core2 --enable-pic --extra-ldflags='-arch x86_64 -miphoneos-version-min=8.4 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.2.sdk -arch x86_64 -O3 -g -miphoneos-version-min=8.4 -arch x86_64 -miphoneos-version-min=8.4 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.2.sdk -arch x86_64 -O3 -g -miphoneos-version-min=8.4 -I/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64/include -g -O2 -I/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64/include' --enable-pthreads --nm= --ar=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar --prefix=/Users/Martz/Projects/vlckit/libvlc/vlc/contrib/iPhone-x86_64-apple-darwin14-x86_64 --enable-static --disable-shared
INFO: libavutil 56. 55.100 / 56. 5.100
INFO: libavcodec 58. 96.100 / 58. 6.103
INFO: libavformat 58. 48.100 / 58. 3.100
INFO: libavdevice 58. 11.101 / 58. 11.101
INFO: libavfilter 7. 87.100 / 7. 87.100
INFO: libswscale 5. 8.100 / 5. 0.101
INFO: libswresample 3. 8.100 / 3. 8.100
ERROR: Unrecognized option 'segment_time'.
FATAL: Error splitting the argument list:
FATAL: Option not found