Recherche avancée

Médias (0)

Mot : - Tags -/auteurs

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (26)

  • Support audio et vidéo HTML5

    10 avril 2011

    MediaSPIP 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, par

    MediaSPIP 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 (...)

  • De l’upload à la vidéo finale [version standalone]

    31 janvier 2010, par

    Le chemin d’un document audio ou vidéo dans SPIPMotion est divisé en trois étapes distinctes.
    Upload et récupération d’informations de la vidéo source
    Dans un premier temps, il est nécessaire de créer un article SPIP et de lui joindre le document vidéo "source".
    Au moment où ce document est joint à l’article, deux actions supplémentaires au comportement normal sont exécutées : La récupération des informations techniques des flux audio et video du fichier ; La génération d’une vignette : extraction d’une (...)

Sur d’autres sites (2451)

  • Laravel MySQL DB not updating after long process

    11 mai 2022, par slanginbits

    I'm doing some video encoding using Laravel and FFMpeg using https://github.com/protonemedia/laravel-ffmpeg

    


    During the video conversion, I can perform some db updates to update the percentage complete in hls_percent field :

    


            $ffmpeg_cmd = FFMpeg::fromDisk('local_videos')
            ->open($video->filename)
            ->exportForHLS()
            ->toDisk('local_videos')
            ->setSegmentLength(3) // optional
            ->setKeyFrameInterval($key_interval) // optional
            ->onProgress(function ($percentage, $remaining = 0, $rate = 0) use ($id) {
                ItemVideo::where('id', $id)->update(['hls_percent' => $percentage]);                
            });


    


    This process works fine and the hls_percent value gets updated to 100 and the encoded video files are generated.

    


    After some files are moved, (takes several seconds) a final db update is not done.

    


    ItemVideo::where('id', $id)->update(['hls_complete' => 1]);


    


    The timeout only happens while encoding a large 150MB (10 min duration) mp4 file. Smaller/shorter videos complete the process without any issues.

    


    I have increased the following in php.ini

    


    memory_limit = 512M 
post_max_size =  1024M
upload_max_filesize = 1024M
max_execution_time = 2400
max_input_time = 2400
default_socket_timeout = 2400


    


    I modified the global variables in the MySQL database server to higher timeouts
as instructed here https://sebhastian.com/lost-connection-mysql-server-during-query/

    


    connect_timeout 2400
delayed_insert_timeout 300
have_statement_timeout YES
innodb_flush_log_at_timeout 1
innodb_lock_wait_timeout 50
innodb_rollback_on_timeout OFF
interactive_timeout 28800
lock_wait_timeout 31536000
mysqlx_connect_timeout 30
mysqlx_idle_worker_thread_timeout 60
mysqlx_interactive_timeout 28800
mysqlx_port_open_timeout 0
mysqlx_read_timeout 30
mysqlx_wait_timeout 28800
mysqlx_write_timeout 60
net_read_timeout 2400
net_write_timeout 2400
replica_net_timeout 2400
rpl_stop_replica_timeout 31536000
rpl_stop_slave_timeout 31536000
slave_net_timeout 2400
ssl_session_cache_timeout 2400
wait_timeout 28800


    


    apache2handler :

    


    Max Requests Per Child : 0 - Keep Alive : on - Max Per Connection : 100
Timeouts Connection : 300 - Keep-Alive : 5

    


    I'm not getting an error messages in laravel or /var/log/apache2/error.log

    


    What else am I missing ? How can I keep the MySQL connection alive to make the final update ?

    


  • inotifywait -m does not process more than 1 file after long running process

    2 mai 2022, par Yllier123

    I have a script that detects files on close_write and runs an 5 minute process on them. These files are written to the directory in batches of up to 100. The issue is that inotifywait only detects the first file in the batch and does not process the subsequent files unless they are removed from the directory by hand and put back. Here is my script :

    


    #!/bin/bash

inotifywait -r -e close_write -e moved_to --format "%f" $TARGET -m | while read file
    do
        if [[ "$file" =~ .*mp4$ ]]; then
            echo "Detected $file"
            /usr/bin/python3 LongRunningProgram.py -i $TARGET/$file -o $PROCESSED -u $UPLOADPATH -c $C
        fi
    done


    


    it is maintained by a systemctl service written like so :

    


    [Unit]
Description=Description
After=network.target

[Service]
Type=idle
user=pi
WorkingDirectory=/home/pi
ExecStart=/bin/bash /home/pi/notify.sh OutPath C
Restart=on-failure

[Install]
WantedBy=multi-user.target


    


    I am confused as to why it only seems to recognize the first file but not subsequent files when run like this, however if I replace the long running program with sleep 300 it seems to work fine.

    


  • FFmpeg taking too long to process video (x264)

    19 avril 2022, par hugger

    I am succesfully processing my video into x264. I am happy with the output and file size I am generating, but the video seems to take as long as the video is to process.

    


    For example, if the video is 10 seconds long, it will take 10 seconds to process the video, etc...

    


    Even if I put -crf 50, it will take the same time. I find this odd behaviour.

    


    Note : I am using FFmpeg with FFmpegKit (React Native) : https://github.com/tanersener/ffmpeg-kit

    


    I am using full-gpl in order to be able to encode to x264. I am not sure what is wrong here or if this is normal behaviour ?

    


    Here is my FFmpeg command I am executing :

    


    `-y -i ${media.path} -c:v libx264 -preset veryfast -tune fastdecode -crf 20 -vf "crop=1350:1080, scale=960:780" -c:a copy -movflags faststart ${path}`


    


    I appreciate all the help I can get here to speed this up / fix this issue.

    


    Cheers !