
Recherche avancée
Autres articles (69)
-
Supporting all media types
13 avril 2011, parUnlike most software and media-sharing platforms, MediaSPIP aims to manage as many different media types as possible. The following are just a few examples from an ever-expanding list of supported formats : images : png, gif, jpg, bmp and more audio : MP3, Ogg, Wav and more video : AVI, MP4, OGV, mpg, mov, wmv and more text, code and other data : OpenOffice, Microsoft Office (Word, PowerPoint, Excel), web (html, CSS), LaTeX, Google Earth and (...)
-
Prérequis à l’installation
31 janvier 2010, parPréambule
Cet article n’a pas pour but de détailler les installations de ces logiciels mais plutôt de donner des informations sur leur configuration spécifique.
Avant toute chose SPIPMotion tout comme MediaSPIP est fait pour tourner sur des distributions Linux de type Debian ou dérivées (Ubuntu...). Les documentations de ce site se réfèrent donc à ces distributions. Il est également possible de l’utiliser sur d’autres distributions Linux mais aucune garantie de bon fonctionnement n’est possible.
Il (...) -
Emballe Médias : Mettre en ligne simplement des documents
29 octobre 2010, parLe plugin emballe médias a été développé principalement pour la distribution mediaSPIP mais est également utilisé dans d’autres projets proches comme géodiversité par exemple. Plugins nécessaires et compatibles
Pour fonctionner ce plugin nécessite que d’autres plugins soient installés : CFG Saisies SPIP Bonux Diogène swfupload jqueryui
D’autres plugins peuvent être utilisés en complément afin d’améliorer ses capacités : Ancres douces Légendes photo_infos spipmotion (...)
Sur d’autres sites (8588)
-
Android + ffmpeg + AudioTrack produces bad audio output
12 septembre 2014, par Goddchenhere is what I am trying to do : use an
AudioRecord
and "pipe" the output ofAudioRecord.read(byte[],...)
to an ffmpeg process’ stdin that will convert to a 3gp (AAC) file.The ffmpeg call is as follows :
ProcessBuilder processBuilder = new ProcessBuilder(BINARY.getAbsolutePath(),
"-y",
"-ar", "44100", "-c:a", "pcm_s16le", "-ac", "1","-f","s16le",
"-i", "-",
"-strict", "-2", "-c:a", "aac",
outFile.getAbsolutePath());The AudioRecord is setup as follows :
AudioRecord record = new AudioRecord(/*AudioSource.VOICE_RECOGNITION,*/ AudioSource.MIC,
SAMPLING_RATE,
AudioFormat.CHANNEL_IN_MONO,
AudioFormat.ENCODING_PCM_16BIT,
bufferSize);SAMPLING_RATE = 44100
andbufferSize
is the one returned byAudioRecord.getMinBufferSize(...)
I am writing the data to ffmpeg like this :
try {
IOUtils.write(data, getFFmpegHelper().getCurrentProcessOutputStream());
} catch (Exception e) {
Log.e(Application.LOG_TAG, "Error writing data to ffmpeg process", e);
//TODO notify user, stop the recording, etc...
}So far so good, the ffmpeg runs and created a proper 3gp file. But the audio in the file is totally off. It seems "choppy" (not sure if this is the correct english word ;) ) and also the pace is wrong, is plays too fast.
Check out this sample : http://goddchen.de/android/tmp/tmp.3gp
This is the output of the ffmpeg process :
[s16le @ 0x23634d0] Estimating duration from bitrate, this may be inaccurate
Guessed Channel Layout for Input Stream #0.0 : mono
Input #0, s16le, from 'pipe:':
Duration: N/A, start: 0.000000, bitrate: 705 kb/s
Stream #0:0: Audio: pcm_s16le, 44100 Hz, mono, s16, 705 kb/s
[aformat @ 0x2363100] auto-inserting filter 'auto-inserted resampler 0' between the filter 'src' and the filter 'aformat'
[aresample @ 0x235b0a0] chl:mono fmt:s16 r:44100Hz -> chl:mono fmt:flt r:44100Hz
Output #0, 3gp, to '/data/data/com.test.audio/files/tmp.3gp':
Metadata:
encoder : Lavf54.6.100
Stream #0:0: Audio: aac (mp4a / 0x6134706D), 44100 Hz, mono, flt, 128 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (pcm_s16le -> aac)
size= 3kB time=00:00:00.18 bitrate= 132.5kbits/s
size= 8kB time=00:00:00.55 bitrate= 120.9kbits/s
size= 12kB time=00:00:00.83 bitrate= 121.8kbits/s
size= 16kB time=00:00:01.04 bitrate= 122.8kbits/s
size= 20kB time=00:00:01.32 bitrate= 122.5kbits/s
size= 23kB time=00:00:01.53 bitrate= 121.6kbits/s
size= 27kB time=00:00:01.81 bitrate= 121.0kbits/s
size= 31kB time=00:00:02.11 bitrate= 120.7kbits/s
size= 35kB time=00:00:02.32 bitrate= 123.4kbits/s
video:0kB audio:34kB global headers:0kB muxing overhead 3.031610% -
passing script variable of filename with spaces in bash to external program (ffmpeg) fails
13 janvier 2016, par BostonScottShort story : I’m trying to write a script that will use FFmpeg to convert the many files stored in one directory to a "standard" mp4 format and save the converted files in another directory. It’s been a learning experience (a fun one !) since I haven’t done any real coding since using Pascal and FORTRAN on an IBM 370 mainframe was in vogue.
Essentially the script takes the filename, strips the path and extension off it, reassembles the filename with the path and an mp4 extension and calls FFmpeg with some set parameters to do the conversion. If the directory contains only video files with without spaces in the names, then everything works fine. If the filenames contain spaces, then FFmpeg is not able to process the file and moves on to the next one. The error indicates that FFMpeg is only seeing the filename up to the first space. I’ve included both the script and output below.
Thanks for any help and suggestions you may have. If you think I should be doing this in another way, please by all means, give me your suggestions. As I said, it’s been a long time since I did anything like this. I’m enjoying it though.
I’ve include the code first followed by example output.
for file in ./TBC/*.mp4
do
echo "Start of iteration"
echo "Full text of file name:" $file
#Remove everything up to "C/" (filename without path)
fn_orig=${file#*C/}
echo "Original file name:" $fn_orig
#Length of file name
fn_len=${#fn_orig}
echo "Filename Length:" $fn_len
#file name without path or extension
fn_base=${fn_orig:0:$fn_len-4}
echo "Base file name:" $fn_base
#new filename suffix
newsuffix=".conv.mp4"
fn_out=./CONV/$fn_base$newsuffix
echo "Converted file name:" $fn_out
ffmpeg -i $file -metadata title="$fn_orig" -c:v libx264 -c:a libfdk_aac -b:a 128k $fn_out
echo "End of iteration"
echo
done
echo "Script completed"With the ffmpeg line commented out, and two files in the ./TBC directory, this is the output that I get
Start of iteration
Full text of file name: ./TBC/Test file with spaces.mp4
Original filename: Test file with spaces.mp4
Filename Length: 25
Base filename: Test file with spaces
Converted file name: ./CONV/Test file with spaces.conv.mp4
End of iteration
Start of iteration
Full text of file name: ./TBC/Test_file_with_NO_spaces.mp4
Original file name: Test_file_with_NO_spaces.mp4
Filename Length: 28
Base file name: Test_file_with_NO_spaces
Converted file name: ./CONV/Test_file_with_NO_spaces.conv.mp4
End of iteration
Script completedI won’t bother to post the results when ffmpeg is uncommented, other than to state that it fails with the error :
./TBC/Test : No such file or directoryThe script then continues to the next file which completes successfully because it has no spaces in its name. The actual filename is "Test file with spaces.mp4" so you can see that ffmpeg stops after the word "Test" when it encounters a space.
I hope this has been clear and concise and hopefully someone will be able to point me in the right direction. There is a lot more that I want to do with this script such as parsing subdirectories and ignoring non-video files, etc.
I look forward to any insight you can give !
-
script ubuntu lucid : x264
4 mars 2012Dans le log du script d’installation j’ai cette erreur :
Téléchargement, compilation et installation de x264
-
Initialized empty Git repository in /usr/local/src/x264/.git/
-
Package x264 was not found in the pkg-config search path.
-
Perhaps you should add the directory containing `x264.pc’
-
to the PKG_CONFIG_PATH environment variable
-
No package ’x264’ found
si je tape "echo $PKG_CONFIG_PATH" j’ai une ligne vide
je suppose que la suite est en rapport :
-
Makefile :3 : config.mak : Aucun fichier ou dossier de ce type
-
cat : config.h : Aucun fichier ou dossier de ce type
-
./configure
-
Found yasm 0.8.0.2194
-
Minimum version is yasm-1.0.0
-
If you really want to compile without asm, configure with —disable-asm.
-
make : *** [config.mak] Erreur 1
-
Found yasm 0.8.0.2194
-
Minimum version is yasm-1.0.0
-
If you really want to compile without asm, configure with —disable-asm.
-