Recherche avancée

Médias (1)

Mot : - Tags -/wave

Autres articles (31)

  • Encodage et transformation en formats lisibles sur Internet

    10 avril 2011

    MediaSPIP transforme et ré-encode les documents mis en ligne afin de les rendre lisibles sur Internet et automatiquement utilisables sans intervention du créateur de contenu.
    Les vidéos sont automatiquement encodées dans les formats supportés par HTML5 : MP4, Ogv et WebM. La version "MP4" est également utilisée pour le lecteur flash de secours nécessaire aux anciens navigateurs.
    Les documents audios sont également ré-encodés dans les deux formats utilisables par HTML5 :MP3 et Ogg. La version "MP3" (...)

  • Emballe médias : à quoi cela sert ?

    4 février 2011, par

    Ce 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" ;

  • Use, discuss, criticize

    13 avril 2011, par

    Talk to people directly involved in MediaSPIP’s development, or to people around you who could use MediaSPIP to share, enhance or develop their creative projects.
    The bigger the community, the more MediaSPIP’s potential will be explored and the faster the software will evolve.
    A discussion list is available for all exchanges between users.

Sur d’autres sites (4046)

  • How to contribute to open source, for companies

    18 octobre 2010, par Dark Shikari — development, open source, x264

    I have seen many nigh-incomprehensible attempts by companies to contribute to open source projects, including x264. Developers are often simply boggled, wondering why the companies seem incapable of proper communication. The companies assume the developers are being unreceptive, while the developers assume the companies are being incompetent, idiotic, or malicious. Most of this seems to boil down to a basic lack of understanding of how open source works, resulting in a wide variety of misunderstandings. Accordingly, this post will cover the dos and don’ts of corporate contribution to open source.

    Do : contact the project using their preferred medium of communication.

    Most open source projects use public methods of communication, such as mailing lists and IRC. It’s not the end of the world if you mistakenly make contact with the wrong people or via the wrong medium, but be prepared to switch to the correct one once informed ! You may not be experienced using whatever form of communication the project uses, but if you refuse to communicate through proper channels, they will likely not be as inclined to assist you. Larger open source projects are often much like companies in that they have different parts to their organization with different roles. Don’t assume that everyone is a major developer !

    If you don’t know what to do, a good bet is often to just ask someone.

    Don’t : contact only one person.

    Open source projects are a communal effort. Major contributions are looked over by multiple developers and are often discussed by the community as a whole. Yet many companies tend to contact only a single person in lieu of dealing with the project proper. This has many flaws : to begin with, it forces a single developer (who isn’t paid by you) to act as your liaison, adding yet another layer between what you want and the people you want to talk to. Contribution to open source projects should not be a game of telephone.

    Of course, there are exceptions to this : sometimes a single developer is in charge of the entirety of some particular aspect of a project that you intend to contribute to, in which case this might not be so bad.

    Do : make clear exactly what it is you are contributing.

    Are you contributing code ? Development resources ? Money ? API documentation ? Make it as clear as possible, from the start ! How developers react, which developers get involved, and their expectations will depend heavily on what they think you are providing. Make sure their expectations match reality. Great confusion can result when they do not.

    This also applies in the reverse — if there’s something you need from the project, such as support or assistance with development of your patch, make that explicitly clear.

    Don’t : code dump.

    Code does not have intrinsic value : it is only useful as part of a working, living project. Most projects react very negatively to large “dumps” of code without associated human resources. That is, they expect you to work with them to finalize the code until it is ready to be committed. Of course, it’s better to work with the project from the start : this avoids the situation of writing 50,000 lines of code independently and then finding that half of it needs to be rewritten. Or, worse, writing an enormous amount of code only to find it completely unnecessary.

    Of course, the reverse option — keeping such code to yourself — is often even more costly, as it forces you to maintain the code instead of the official developers.

    Do : ignore trolls.

    As mentioned above, many projects use public communication methods — which, of course, allow anyone to communicate, by nature of being public. Not everyone on a project’s IRC or mailing list is necessarily qualified to officially represent the project. It is not too uncommon for a prospective corporate contributor to be turned off by the uninviting words of someone who isn’t even involved in the project due to assuming that they were. Make sure you’re dealing with the right people before making conclusions.

    Don’t : disappear.

    If you are going to try to be involved in a project, you need to stay in contact. We’ve had all too many companies who simply disappear after the initial introduction. Some tell us that we’ll need an NDA, then never provide it or send status updates. You may know why you’re not in contact — political issues at the company, product launch crunches, a nice vacation to the Bahamas — but we don’t ! If you disappear, we will assume that you gave up.

    Above all, don’t assume that being at a large successful company makes you immune to these problems. If anything, these problems seem to be the most common at the largest companies. I didn’t name any names in this post, but practically every single one of these rules has been violated at some point by companies looking to contribute to x264. In the larger scale of open source, these problems happen constantly. Don’t fall into the same traps that many other companies have.

    If you’re an open source developer reading this post, remember it next time you see a company acting seemingly nonsensically in an attempt to contribute : it’s quite possible they just don’t know what to do. And just because they’re doing it wrong doesn’t mean that it isn’t your responsibility to try to help them do it right.

  • MP4Box / FFMPEG concat loses audio after first clip

    17 novembre 2017, par user1615343

    So I am certainly no expert when it comes to either of these tools, but I have a web-based project that’s executing commands on an Amazon Linux server to concatenate two video files that are uploaded.

    Both files are converted to mp4s first using FFMPEG, and those play perfectly in a browser after conversion :

    ffmpeg -i file1.mpg -c:v libx264 -crf 22 -c:a aac -strict -2 -movflags faststart file2.mp4

    Then, I attempt to combine these two resulting mp4s into a single mp4. I tried using FFMPEG to do this but to no avail. Switching to try MP4Box got me much closer : the videos are concatenated together, but the audio stops playing at the end of the first clip, and the second clip is silent.

    MP4Box -force-cat -keepsys -add file.mp4 -cat file2.mp4 out.mp4

    I’ve tried varying versions of the above command with no better results. Any input is greatly appreciated.

    EDIT : info on .mp4 files using

    ffmpeg -i file1.mp4 -i file2.mp4

    ffmpeg -i 1510189259715DogRunsintoGlassDoor_315a03a8e20acfc.mp4 -i
    1510189273549NewhouseMoonMoonneverseenstairsbeforefunnydog_285a03a8e6aab25.mp4

    ffmpeg version N-61041-g52a2138 Copyright (c) 2000-2014 the FFmpeg
    developers

    built on Mar 2 2014 05:45:04 with gcc 4.6 (Debian 4.6.3-1)

    configuration : —prefix=/root/ffmpeg-static/64bit
    —extra-cflags=’-I/root/ffmpeg-static/64bit/include -static’ —extra-ldflags=’-L/root/ffmpeg-static/64bit/lib -static’ —extra-libs=’-lxml2 -lexpat -lfreetype’ —enable-static —disable-shared —disable-ffserver —disable-doc —enable-bzlib —enable-zlib —enable-postproc —enable-runtime-cpudetect —enable-libx264 —enable-gpl —enable-libtheora —enable-libvorbis —enable-libmp3lame —enable-gray —enable-libass —enable-libfreetype —enable-libopenjpeg —enable-libspeex —enable-libvo-aacenc —enable-libvo-amrwbenc —enable-version3 —enable-libvpx

    libavutil 52. 66.100 / 52. 66.100

    libavcodec 55. 52.102 / 55. 52.102

    libavformat 55. 33.100 / 55. 33.100

    libavdevice 55. 10.100 / 55. 10.100

    libavfilter 4. 2.100 / 4. 2.100

    libswscale 2. 5.101 / 2. 5.101

    libswresample 0. 18.100 / 0. 18.100

    libpostproc 52. 3.100 / 52. 3.100

    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from
    ’1510189259715DogRunsintoGlassDoor_315a03a8e20acfc.mp4’ :

    Metadata :

    major_brand : isom

    minor_version : 512

    compatible_brands : isomiso2avc1mp41

    encoder : Lavf55.33.100

    Duration : 00:00:04.92, start : 0.023220, bitrate : 634 kb/s

    Stream #0:0(und) : Video : h264 (High) (avc1 / 0x31637661), yuv420p,
    360x360 [SAR 1:1 DAR 1:1], 501 kb/s, 30 fps, 30 tbr, 15360 tbn, 60 tbc
    (default)

    Metadata :

    handler_name : VideoHandler

    Stream #0:1(und) : Audio : aac (mp4a / 0x6134706D), 44100 Hz, mono,
    fltp, 132 kb/s (default)

    Metadata :

    handler_name : SoundHandler

    Input #1, mov,mp4,m4a,3gp,3g2,mj2, from
    ’1510189273549NewhouseMoonMoonneverseenstairsbeforefunnydog_285a03a8e6aab25.mp4’ :

    Metadata :

    major_brand : isom

    minor_version : 512

    compatible_brands : isomiso2avc1mp41

    encoder : Lavf55.33.100

    Duration : 00:00:18.79, start : 0.023220, bitrate : 455 kb/s

    Stream #1:0(und) : Video : h264 (High) (avc1 / 0x31637661), yuv420p,
    362x360 [SAR 1:1 DAR 181:180], 320 kb/s, 29.94 fps, 29.94 tbr, 11976
    tbn, 59.88 tbc (default)

    Metadata :

    handler_name : VideoHandler

    Stream #1:1(eng) : Audio : aac (mp4a / 0x6134706D), 44100 Hz, stereo,
    fltp, 129 kb/s (default)

    Metadata :

    handler_name : SoundHandler

    At least one output file must be specified

  • Reason for write EPIPE error in my implentation ?

    18 mai 2019, par Chrisl446

    So I currently have a small node.js express application for uploading images using sharp & thumbnails created from .mp4 videos using simple-thumbnail package/ffmpeg.

    The app works perfectly when uploading an image, the file is uploaded sharp processes it, then passes it along and it ends up in my amazon s3 bucket as expected. No errors what so ever.

    However, when I upload an mp4 video that I use to create and upload a thumbnail from by using simple-thumbnails genThumbnail() function, which uses ffmpeg child process, the thumbnail uploads successully to my s3 bucket, HOWEVER my app returns an EPIPE write error and NOT the url of the uploaded files url on S3.

    What is causing this and how can I fix it, considering it’s pretty much working aside from the EPIPE error that is being returned ? Thanks ahead !

    The packages of concern used are as follows :

    aws-sdk

    multer

    multer-s3 <- this one with the transform option, not the standard multer-s3 package

    simple-thumbnail

    const express = require('express');
    const app = express();

    const aws = require('aws-sdk');
    const multer = require('multer');
    const multerS3 = require('multer-s3'); //github:gmenih341/multer-s3 version of multer-s3 with transform option
    const sharp = require('sharp');
    const genThumbnail = require('simple-thumbnail');

    app.use((req, res, next) => {
       res.header('Access-Control-Allow-Origin', '*');
       res.header('Access-Control-Allow-Headers', 'Orgin, X-Requested-With, Content-Type, Accept, Authorization');
       if (req.method === 'OPTIONS') {
           res.header('Access-Control-Allow-Methods', 'POST');
           return res.status(200).json({});
       }
       next();
    });

    let uniqueFileName;
    let s3BucketName = 'bucketname';

    let s3 = new aws.S3({
       accessKeyId: ACCESS_KEY,
       secretAccessKey: SECRET_KEY,
       Bucket: s3BucketName
    });

    let upload = multer({
       storage: multerS3({
           s3: s3,
           bucket: s3BucketName,
           acl: 'public-read',
           cacheControl: 'max-age=31536000',
           contentType: multerS3.AUTO_CONTENT_TYPE,
           shouldTransform: true,
           transforms: [{
               id: 'thumbnail',
               key: function (req, file, cb) {
                   uniqueFileName = Date.now().toString();
                   cb(null, uniqueFileName + '.jpg')
               },
               transform: function (req, file, cb) {
                   if (file.mimetype == 'video/mp4') {
                       //When using simple-thumbnails' getThumbnail() on an mp4 video it uploads succesfully to S3 but node returns EPIPE write error
                       cb(null, genThumbnail(null, null, '250x?'))
                   } else {
                       //When using sharp to resize an image this works perfectly and retuns the JSON below with the files S3 URL
                       cb(null, sharp().jpeg())
                   }

               }
           }]
       })
    });

    app.post('/upload', upload.array('theFile'), (req, res) => {
       res.json({
           fileS3Url: 'https://s3.amazonaws.com/'+ s3BucketName +'/' + uniqueFileName
       });
    });

    app.use((req, res, next) => {
       const error = new Error('Not found');
       error.status = 404;
       next(error);
    });

    app.use((error, req, res, next) => {
       res.status(error.status || 500);
       res.json({
           error: {
               message: error.message
           }
       });
    });

    module.exports = app;