
Recherche avancée
Médias (91)
-
Collections - Formulaire de création rapide
19 février 2013, par
Mis à jour : Février 2013
Langue : français
Type : Image
-
Les Miserables
4 juin 2012, par
Mis à jour : Février 2013
Langue : English
Type : Texte
-
Ne pas afficher certaines informations : page d’accueil
23 novembre 2011, par
Mis à jour : Novembre 2011
Langue : français
Type : Image
-
The Great Big Beautiful Tomorrow
28 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Texte
-
Richard Stallman et la révolution du logiciel libre - Une biographie autorisée (version epub)
28 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Texte
-
Rennes Emotion Map 2010-11
19 octobre 2011, par
Mis à jour : Juillet 2013
Langue : français
Type : Texte
Autres articles (105)
-
Publier sur MédiaSpip
13 juin 2013Puis-je poster des contenus à partir d’une tablette Ipad ?
Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir -
Support audio et vidéo HTML5
10 avril 2011MediaSPIP utilise les balises HTML5 video et audio pour la lecture de documents multimedia en profitant des dernières innovations du W3C supportées par les navigateurs modernes.
Pour les navigateurs plus anciens, le lecteur flash Flowplayer est utilisé.
Le lecteur HTML5 utilisé a été spécifiquement créé pour MediaSPIP : il est complètement modifiable graphiquement pour correspondre à un thème choisi.
Ces technologies permettent de distribuer vidéo et son à la fois sur des ordinateurs conventionnels (...) -
HTML5 audio and video support
13 avril 2011, parMediaSPIP uses HTML5 video and audio tags to play multimedia files, taking advantage of the latest W3C innovations supported by modern browsers.
The MediaSPIP player used has been created specifically for MediaSPIP and can be easily adapted to fit in with a specific theme.
For older browsers the Flowplayer flash fallback is used.
MediaSPIP allows for media playback on major mobile platforms with the above (...)
Sur d’autres sites (9448)
-
How to play videos that only contain P frames (no I frames) on iOS ?
9 septembre 2016, par Clement WangI am trying to play a raw .264 file on iOS that only contains P frames (no keyframes included), but it fails to play with multiple open source FFmpeg video players such as kxmovie or ijkplayer.
The error log shows
non-existing PPS 0 referenced
, however the SPS and PPS information is already embedded in the frames. I am wondering if it is possible to play P-frame only videos with a modified version of FFmpeg or any other open source library/player. -
how to play mp3 using ffmpeg
5 novembre 2013, par AriI'm trying to play audio mp3 file using ffmpeg in android
but I'm facing a problem in the below mentioned codehow to play mp3 using ffmpeg
void JNICALL Java_com_music_MainActivity_loadFile(JNIEnv* env, jobject obj,jstring file,jbyteArray array)
{
jboolean isfilenameCopy;
const char * filename = (*env)->GetStringUTFChars(env, file, &isfilenameCopy);
AVCodec *codec;
AVCodecContext *c= NULL;
int out_size, len;
FILE *f, *outfile;
uint8_t *outbuf;
uint8_t inbuf[AUDIO_INBUF_SIZE + FF_INPUT_BUFFER_PADDING_SIZE];
AVPacket avpkt;
jclass cls = (*env)->GetObjectClass(env, obj);
jmethodID play = (*env)->GetMethodID(env, cls, "playSound", "([BI)V");//At the begining of your main function
av_init_packet(&avpkt);
printf("Audio decoding\n");
__android_log_print(ANDROID_LOG_INFO, DEBUG_TAG, "inside load file");
/* find the mpeg audio decoder */
codec = avcodec_find_decoder(CODEC_ID_MP3);
if (!codec) {
fprintf(stderr, "codec not found\n");
exit(1);
}
c= avcodec_alloc_context();
/* open it */
if (avcodec_open(c, codec) < 0) {
fprintf(stderr, "could not open codec\n");
exit(1);
}
__android_log_print(ANDROID_LOG_INFO, DEBUG_TAG, "open avcode");
outbuf = malloc(AVCODEC_MAX_AUDIO_FRAME_SIZE);
__android_log_print(ANDROID_LOG_INFO, DEBUG_TAG, "open %s",outbuf);
f = fopen(filename, "rb");
if (!f) {
fprintf(stderr, "could not open %s\n", filename);
exit(1);
}
/* decode until eof */
avpkt.data = inbuf;
avpkt.size = fread(inbuf, 1, AUDIO_INBUF_SIZE, f);
__android_log_print(ANDROID_LOG_INFO, DEBUG_TAG, "data =%s and size %d",avpkt.data,avpkt.size);
while (avpkt.size > 0) {
out_size = AVCODEC_MAX_AUDIO_FRAME_SIZE;
len = avcodec_decode_audio3(c, (short *)outbuf, &out_size, &avpkt);
__android_log_print(ANDROID_LOG_INFO, DEBUG_TAG, "length =%d",len);
if (len < 0) {
fprintf(stderr, "Error while decoding\n");
__android_log_print(ANDROID_LOG_INFO, DEBUG_TAG, " failed length =%d",errno);
exit(1);
}
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);
}i am getting the len = - 1 in
len = avcodec_decode_audio3(c, (short *)outbuf, &out_size, &avpkt);
what am i doing wrong ??
please help
-
play m3u8 video from laravel storage
21 janvier 2020, par JennsenMy question is the same as how to play m3u8 videos from laravel storage but this one did not get answers.
If I play the video from the public folder it does it without problems.
but if I want to play it from storage this doesn’t work.
public function watch(Request $request, Episode $episode)
{
$video = Storage::disk('videos')->get($episode->video);
return new Response($video, 200, ['Content-Type' => 'application/x-mpegURL', 'isHls' => true]);
}this is the definition of my disk in config/filesystems.php
'videos' => [
'driver' => 'local',
'root' => storage_path('app/videos'),
'url' => env('APP_URL').'/storage',
'visibility' => 'public',
],this is my conversion code (job)
*/
public function handle()
{
$path = $this->episode->id . '.m3u8';
$lowBitrate = (new X264 ('aac'))->setKiloBitrate(500)->setVideoCodec('libx264');
$midBitrate = (new X264 ('aac'))->setKiloBitrate(1000)->setVideoCodec('libx264');
$highBitrate = (new X264 ('aac'))->setKiloBitrate(3000)->setVideoCodec('libx264');
FFMpeg::fromDisk('tmp')->open($this->episode->video)
->exportForHLS()
->dontSortFormats()
->setSegmentLength(10)
->toDisk('local')
->addFormat($lowBitrate, function($media) {
$media->addFilter(function ($filters) {
$filters->resize(new \FFMpeg\Coordinate\Dimension(640, 480));
});
})
->addFormat($midBitrate, function($media) {
$media->addFilter(function ($filters) {
$filters->resize(new \FFMpeg\Coordinate\Dimension(1280, 960));
});
})
->addFormat($highBitrate, function($media) {
$media->addFilter(function ($filters) {
$filters->resize(new \FFMpeg\Coordinate\Dimension(1280, 960));
});
})
->save($path);
$this->episode->update([
'video' => $path,
]);
FFMpeg::cleanupTemporaryFiles();
}