Recherche avancée

Médias (1)

Mot : - Tags -/MediaSPIP 0.2

Autres articles (112)

  • Personnaliser en ajoutant son logo, sa bannière ou son image de fond

    5 septembre 2013, par

    Certains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;

  • Websites made ​​with MediaSPIP

    2 mai 2011, par

    This page lists some websites based on MediaSPIP.

  • Creating farms of unique websites

    13 avril 2011, par

    MediaSPIP platforms can be installed as a farm, with a single "core" hosted on a dedicated server and used by multiple websites.
    This allows (among other things) : implementation costs to be shared between several different projects / individuals rapid deployment of multiple unique sites creation of groups of like-minded sites, making it possible to browse media in a more controlled and selective environment than the major "open" (...)

Sur d’autres sites (14998)

  • PHP exec() function commond finshed but last function not execute

    9 mars 2018, par Noeeka

    The PHP file should execute FFmpeg command after this command finished it should take data into the database. However, I found that the exec($command--FFmpeg) has been completed and it run pretty well but the data is not in the database.

    I have set php.ini ignore_user_abort = On

    It could run the PHP process in the background

    my could is as follows

    set_time_limit(0);
    $tumbfileName = time();
    $filepath = dirname(dirname(dirname(__FILE__))) . "/files/video/";
    $cmd = 'ffmpeg -i ' . dirname(dirname(dirname(__FILE__))).$content . ' -c:v libx264 -strict -2 ' . $filepath . "post_" . $tumbfileName . '.mp4';
    exec($cmd, $output, $error);

    $cmdImg="ffmpeg -y -ss 2 -i ".dirname(dirname(dirname(__FILE__))).$content." -vframes 1 -f image2 -s 400*300 ".$filepath . "notice_thumb_" . $tumbfileName . '.jpg';
    //$cmdImg = "ffmpeg -i " . dirname(dirname(dirname(__FILE__))).$content . " -f image2 -ss 10 -s 400*300 -vframes 10 " . $filepath . "notice_thumb_" . $tumbfileName . '.jpg';
    exec($cmdImg, $outputImg, $errorImg);
    $data = array(
           'content' => "/files/video/"."post_" . $tumbfileName . '.mp4',
           'author' => 'management',
           'deadline' => $deadline,
           'type' => $type,
           'datetime' => time(),
           'thumb' => "/files/video/"."notice_thumb_" . $tumbfileName . '.jpg'
    );                                                          
    $flag = $this->db->insert('notice_info', $data);
  • How to Manage User Uploaded Content and Storage

    6 novembre 2014, par Ben

    I’m building an app in PHP (Laravel 4 framework) where a teacher in their account can create a digital lesson for a student. Digital lessons can contain the following content :

    • Text (text from form, .doc, .txt, .pdf, etc.)
    • Images (.gif, .png, .jpg etc.)
    • Video (.avi, .mov, .mp4, etc.)
    • Audio (.mp3, etc.)

    Raw text entered from forms can obviously be stored in the DB against the lesson_id. All the other content formats will need to be stored somewhere, where I can manage and read the files, as well as keep track of the teachers storage total as I plan to bill for storage thresholds at 5GB, 10GB etc.

    On the create a lesson page, content files need to be uploaded as lesson attachments before the lesson is saved, so a teacher can visually see all the lessons content, and then hit save to create the lesson instantly.

    Here’s what I’ve come up with :

    1. Upload all lesson file attachments to AWS S3 to the teachers dedicated bucket, before the lesson is created. Add the teachers ID and date time to each filename.

    2. Force all uploaded video / audio files to be converted to .mp4, .mp3, etc. if they are not in an iDevice friendly format or they exceed a file size limit. Use FFmpeg to do this.

    3. When the lesson is saved and created, record the S3 file URL’s against the lesson ID in the DB.

    4. If the lesson has not been created after a specific period of time, run a cron job to check for uploaded S3 files with no lesson and delete them.

    I am unsure what is the best way to solve this problem as user uploaded content management is really new to me.

    What do you think of this approach ? Can you recommend an improved or better way to solve this problem ?

  • h264 : move the DPB init/uninit to init_context()/free_context()

    5 avril 2015, par Anton Khirnov
    h264 : move the DPB init/uninit to init_context()/free_context()
    

    Currently, the DPB is initialized in alloc_tables() and uninitialized in
    free_tables(), but those functions manage frame size-dependent
    variables, so DPB management does not logically belong in there.

    Since we want the init/uninit to happen exactly once per the context
    lifetime, init_context()/free_context() are the proper place for this
    code.

    • [DBH] libavcodec/h264.c
    • [DBH] libavcodec/h264_slice.c