Recherche avancée

Médias (1)

Mot : - Tags -/ticket

Autres articles (93)

  • Le profil des utilisateurs

    12 avril 2011, par

    Chaque utilisateur dispose d’une page de profil lui permettant de modifier ses informations personnelle. Dans le menu de haut de page par défaut, un élément de menu est automatiquement créé à l’initialisation de MediaSPIP, visible uniquement si le visiteur est identifié sur le site.
    L’utilisateur a accès à la modification de profil depuis sa page auteur, un lien dans la navigation "Modifier votre profil" est (...)

  • Les sons

    15 mai 2013, par
  • Configurer la prise en compte des langues

    15 novembre 2010, par

    Accéder à la configuration et ajouter des langues prises en compte
    Afin de configurer la prise en compte de nouvelles langues, il est nécessaire de se rendre dans la partie "Administrer" du site.
    De là, dans le menu de navigation, vous pouvez accéder à une partie "Gestion des langues" permettant d’activer la prise en compte de nouvelles langues.
    Chaque nouvelle langue ajoutée reste désactivable tant qu’aucun objet n’est créé dans cette langue. Dans ce cas, elle devient grisée dans la configuration et (...)

Sur d’autres sites (6077)

  • How would I assign multiple MMAP's from single file descriptor ?

    9 juin 2011, par Alex Stevens

    So, for my final year project, I'm using Video4Linux2 to pull YUV420 images from a camera, parse them through to x264 (which uses these images natively), and then send the encoded stream via Live555 to an RTP/RTCP compliant video player on a client over a wireless network. All of this I'm trying to do in real-time, so there'll be a control algorithm, but that's not the scope of this question. All of this - except Live555 - is being written in C. Currently, I'm near the end of encoding the video, but want to improve performance.

    To say the least, I've hit a snag... I'm trying to avoid User Space Pointers for V4L2 and use mmap(). I'm encoding video, but since it's YUV420, I've been malloc'ing new memory to hold the Y', U and V planes in three different variables for x264 to read upon. I would like to keep these variables as pointers to an mmap'ed piece of memory.

    However, the V4L2 device has one single file descriptor for the buffered stream, and I need to split the stream into three mmap'ed variables adhering to the YUV420 standard, like so...

    buffers[n_buffers].y_plane = mmap(NULL, (2 * width * height) / 3,
                                       PROT_READ | PROT_WRITE, MAP_SHARED,
                                       fd, buf.m.offset);
    buffers[n_buffers].u_plane = mmap(NULL, width * height / 6,
                                       PROT_READ | PROT_WRITE, MAP_SHARED,
                                       fd, buf.m.offset +
                                       ((2 * width * height) / 3 + 1) /
                                       sysconf(_SC_PAGE_SIZE));
    buffers[n_buffers].v_plane = mmap(NULL, width * height / 6,
                                       PROT_READ | PROT_WRITE, MAP_SHARED,
                                       fd, buf.m.offset +
                                       ((2 * width * height) / 3 +
                                       width * height / 6 + 1) /
                                       sysconf(_SC_PAGE_SIZE));

    Where "width" and "height" is the resolution of the video (eg. 640x480).

    From what I understand... MMAP seeks through a file, kind of like this (pseudoish-code) :

    fd = v4l2_open(...);
    lseek(fd, buf.m.offset + (2 * width * height) / 3);
    read(fd, buffers[n_buffers].u_plane, width * height / 6);

    My code is located in a Launchpad Repo here (for more background) :
    http://bazaar.launchpad.net/ alex-stevens/+junk/spyPanda/files (Revision 11)

    And the YUV420 format can be seen clearly from this Wiki illustration : http://en.wikipedia.org/wiki/File:Yuv420.svg (I essentially want to split up the Y, U, and V bytes into each mmap'ed memory)

    Anyone care to explain a way to mmap three variables to memory from the one file descriptor, or why I went wrong ? Or even hint at a better idea to parse the YUV420 buffer to x264 ? :P

    Cheers ! ^^

  • How to add arbitrary or custom metadata in MP4 ?

    13 avril 2021, par 大大大大萝卜凉

    The MP4 muxer in ffmpeg only allows certain metadata by default. I would like to add :

    


    com.android.model: Mi 10 Pro
xyz: +22.9835+113.3621/
com.android.version: 1
com.android.manufacturer: Xiaomi


    


    How can I add this with ffmpeg ?

    


  • What are the correct conversion steps to generate a video from PDF with ffmpeg and mp4box

    25 juin 2020, par Michael Rall

    I need to convert a PDF-Document to a DASH-compatible stream. Every page of the PDF should be displayed for one second. Quality should be rather good, so that text and line graphics can still be read clearly. Additionally I want to be able to seek every page, so keyframes(?) should be (exactly) every second.

    


    Im using poppler-tools to extract the pdf-pages as png's -> works

    


    Im using ffmpeg to convert the single images to an x264 encoded mp4 video -> works (but maybe problematic)

    


    string.Format("-r 1 -i \"{0}.page_%d.png\" -r 24 -vcodec libx264 -pix_fmt yuv420p {0}.output.mp4", basePath)


    


    Im using MP4Box to convert that video to dash -> works (but needs improvement)

    


    string.Format("-dash 1000 -frag 1000 -rap -segment-name {1}_dash_$RepresentationID$_$Number$ -url-template {0}.output.mp4 -out \"{0}.{2}\"", basePath, tempDataId, STREAM_MANIFEST_FILE_POSTFIX)


    


    Now I have 2 Problems/Questions

    


      

    1. Are the settings for framerate, quality, outputformat correct for the goals I want to achieve
    2. 


    3. When displaying the resulting DASH-Stream in the Demo-Player from https://github.com/Dash-Industry-Forum/dash.js/wiki it plays the stream, but as soon as I try to seek the player starts loading forever. Setting the position to start and let it play again works. The network tab in my browser-debugger shows that the player tries to load the segments and gets them successfully.
    4. 


    


    I guess its a problem with keyframes, fragments or similar. Can somebody correct my conversion steps ?

    


    kind regards