
Recherche avancée
Médias (1)
-
SWFUpload Process
6 septembre 2011, par
Mis à jour : Septembre 2011
Langue : français
Type : Texte
Autres articles (111)
-
Dépôt de média et thèmes par FTP
31 mai 2013, parL’outil MédiaSPIP traite aussi les média transférés par la voie FTP. Si vous préférez déposer par cette voie, récupérez les identifiants d’accès vers votre site MédiaSPIP et utilisez votre client FTP favori.
Vous trouverez dès le départ les dossiers suivants dans votre espace FTP : config/ : dossier de configuration du site IMG/ : dossier des média déjà traités et en ligne sur le site local/ : répertoire cache du site web themes/ : les thèmes ou les feuilles de style personnalisées tmp/ : dossier de travail (...) -
Sélection de projets utilisant MediaSPIP
29 avril 2011, parLes exemples cités ci-dessous sont des éléments représentatifs d’usages spécifiques de MediaSPIP pour certains projets.
Vous pensez avoir un site "remarquable" réalisé avec MediaSPIP ? Faites le nous savoir ici.
Ferme MediaSPIP @ Infini
L’Association Infini développe des activités d’accueil, de point d’accès internet, de formation, de conduite de projets innovants dans le domaine des Technologies de l’Information et de la Communication, et l’hébergement de sites. Elle joue en la matière un rôle unique (...) -
Other interesting software
13 avril 2011, parWe don’t claim to be the only ones doing what we do ... and especially not to assert claims to be the best either ... What we do, we just try to do it well and getting better ...
The following list represents softwares that tend to be more or less as MediaSPIP or that MediaSPIP tries more or less to do the same, whatever ...
We don’t know them, we didn’t try them, but you can take a peek.
Videopress
Website : http://videopress.com/
License : GNU/GPL v2
Source code : (...)
Sur d’autres sites (12680)
-
swscale/utils : Fix color range of gray16
18 mars 2014, par Carl Eugen Hoyosswscale/utils : Fix color range of gray16
Improves rgb -> gray16 conversion
Fixes Ticket3422
The pam and png output files look visually similar, in both cases the
dynamics increase to 0x0 -> 0xfffb.Signed-off-by : Michael Niedermayer <michaelni@gmx.at>
- [DH] libswscale/utils.c
- [DH] tests/ref/fate/filter-pixdesc
- [DH] tests/ref/fate/filter-pixfmts-copy
- [DH] tests/ref/fate/filter-pixfmts-crop
- [DH] tests/ref/fate/filter-pixfmts-field
- [DH] tests/ref/fate/filter-pixfmts-fieldorder
- [DH] tests/ref/fate/filter-pixfmts-hflip
- [DH] tests/ref/fate/filter-pixfmts-il
- [DH] tests/ref/fate/filter-pixfmts-null
- [DH] tests/ref/fate/filter-pixfmts-scale
- [DH] tests/ref/fate/filter-pixfmts-vflip
- [DH] tests/ref/lavf/pam
- [DH] tests/ref/lavf/png
-
Getting jibberish while using ffmpeg in android
27 février 2013, par StackOverflowedI'm trying decode an audio file into PCM to use with AudioTrack. The audio is squeeky, squelchy, and just plain jibberish and for a random second sounds like it should but mainly is completely muddled. I'm not sure where my mistake is, is it in how the array is passed back to playSound ?
Thank you in advance, I would really appreciate help on this matter as it's been kicking my ass for a while.
This is my java code :
public void init() {
int bufSize = AudioTrack.getMinBufferSize(44100,
AudioFormat.CHANNEL_OUT_STEREO,
AudioFormat.ENCODING_PCM_16BIT);
track = new AudioTrack(AudioManager.STREAM_MUSIC,
44100,
AudioFormat.CHANNEL_OUT_STEREO,
AudioFormat.ENCODING_PCM_16BIT,
bufSize,
AudioTrack.MODE_STREAM);
log("STARTING!!! _________________________ <--");
byte[] array = new byte[bufSize];
try {
fos = new FileOutputStream("/sdcard/acdc.bin");
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
decoder("/sdcard/acdc.ogg", array);
}
void playSound(byte[] buf, int size) {
try {
fos.write(buf, 0, size);
} catch (IOException e) {
e.printStackTrace();
}
if(track.getPlayState()!=AudioTrack.PLAYSTATE_PLAYING) {
track.play();
}
int wrote = track.write(buf, 0, size);
if (wrote != size)
log("WRITING: " + wrote + " but size was: " + size);
}This is my c function :
void Java_com_example_ffmpegsample_MainActivity_decoder(JNIEnv* env, jobject obj,jstring file,jbyteArray array)
{
jboolean isfilenameCopy;
const char * filename = (*env)->GetStringUTFChars(env, file, &isfilenameCopy);
AVCodec *codec;
AVCodecContext *c= NULL;
AVFormatContext *pFormatCtx;
AVCodecContext *pCodecCtx;
int out_size, len;
FILE *f, *outfile;
uint8_t *outbuf;
uint8_t inbuf[AUDIO_INBUF_SIZE + FF_INPUT_BUFFER_PADDING_SIZE];
AVPacket avpkt;
LOGI("HERE");
jclass cls = (*env)->GetObjectClass(env, obj);
LOGI(cls);
jmethodID play = (*env)->GetMethodID(env, cls, "playSound", "([BI)V");//At the begining of your main function
av_init_packet(&avpkt);
av_register_all();
LOGI("AUDIO DECODER");
printf("Audio decoding\n");
int err;
err = av_open_input_file(&pFormatCtx, filename, NULL, 0, NULL);
if (err!=0) {
LOGI("COULD NOT AV_OPEN file");
return;
}
if(av_find_stream_info(pFormatCtx)<0) {
LOGE("Unable to get stream info");
return;
}
int audioStream = -1;
int i;
for (i=0; inb_streams; i++) {
if(pFormatCtx->streams[i]->codec->codec_type==CODEC_TYPE_AUDIO) {
audioStream = i;
break;
}
}
if(audioStream==-1) {
LOGE("Unable to find audio stream");
return;
}
LOGI("Audio stream is [%d]", audioStream);
pCodecCtx=pFormatCtx->streams[audioStream]->codec;
codec = avcodec_find_decoder(pCodecCtx->codec_id);
/* find the mpeg audio decoder */
// codec = avcodec_find_decoder(CODEC_ID_AAC);
if (!codec) {
LOGI("NO CODEC");
fprintf(stderr, "codec not found\n");
return;
}
//c= avcodec_alloc_context();
c = pCodecCtx;
/* open it */
if (avcodec_open(c, codec) < 0) {
fprintf(stderr, "could not open codec\n");
LOGI("NOT LOADING CODEC");
return;
}
outbuf = malloc(AVCODEC_MAX_AUDIO_FRAME_SIZE);
f = fopen(filename, "rb");
if (!f) {
fprintf(stderr, "could not open %s\n", filename);
LOGI("COULD NOT OPEN FILE");
return;
}
/* decode until eof */
avpkt.data = inbuf;
avpkt.size = fread(inbuf, 1, AUDIO_INBUF_SIZE, f);
while (avpkt.size > 0) {
LOGI("............................." + avpkt.size);
out_size = AVCODEC_MAX_AUDIO_FRAME_SIZE;
len = avcodec_decode_audio3(c, (short *)outbuf, &out_size, &avpkt);
if (len < 0) {
fprintf(stderr, "Error while decoding\n");
LOGI("ERROR DECODING, error: %d", len);
return;
}
if (out_size > 0) {
/* if a frame has been decoded, output it */
jbyte *bytes = (*env)->GetByteArrayElements(env, array, NULL);
memcpy(bytes, outbuf, out_size); //
(*env)->ReleaseByteArrayElements(env, array, bytes, 0);
(*env)->CallVoidMethod(env, obj, play, array, out_size);
}
avpkt.size -= len;
avpkt.data += len;
if (avpkt.size < AUDIO_REFILL_THRESH) {
/* Refill the input buffer, to avoid trying to decode
* incomplete frames. Instead of this, one could also use
* a parser, or use a proper container format through
* libavformat. */
memmove(inbuf, avpkt.data, avpkt.size);
avpkt.data = inbuf;
len = fread(avpkt.data + avpkt.size, 1,
AUDIO_INBUF_SIZE - avpkt.size, f);
if (len > 0)
avpkt.size += len;
}
}
fclose(f);
free(outbuf);
avcodec_close(c);
av_free(c);
} -
What is Behavioural Segmentation and Why is it Important ?
28 septembre 2023, par Erin — Analytics Tips