Recherche avancée

Médias (0)

Mot : - Tags -/optimisation

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

Autres articles (34)

  • Publier sur MédiaSpip

    13 juin 2013

    Puis-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

  • Submit enhancements and plugins

    13 avril 2011

    If you have developed a new extension to add one or more useful features to MediaSPIP, let us know and its integration into the core MedisSPIP functionality will be considered.
    You can use the development discussion list to request for help with creating a plugin. As MediaSPIP is based on SPIP - or you can use the SPIP discussion list SPIP-Zone.

  • D’autres logiciels intéressants

    12 avril 2011, par

    On ne revendique pas d’être les seuls à faire ce que l’on fait ... et on ne revendique surtout pas d’être les meilleurs non plus ... Ce que l’on fait, on essaie juste de le faire bien, et de mieux en mieux...
    La liste suivante correspond à des logiciels qui tendent peu ou prou à faire comme MediaSPIP ou que MediaSPIP tente peu ou prou à faire pareil, peu importe ...
    On ne les connais pas, on ne les a pas essayé, mais vous pouvez peut être y jeter un coup d’oeil.
    Videopress
    Site Internet : (...)

Sur d’autres sites (4935)

  • Frame duration issues when trimming videos in MATLAB/ffmpeg ?

    18 septembre 2024, par twilightecologist

    I have two videos (A.MOV and B.MOV), that are supposed to be perfectly synced. However, Video A (3708 frames), has 5 more frames than Video B (3703 frames). When I look at the timestamps of these frames, the extra A frames are at the very end of the video. In addition, the last frame in each video is a "padded" frame, with a duration much longer (around 10 times) than that of the other frames.

    


    I need my videos to be perfectly synced, with the same frame number. Since the extra frames are at the end of the video, I want to trim off the extra frames in A, as well as trim the "padded" long frame off of each video.

    


    I currently am running the below MATLAB code to do so,

    


    % Specify the input and output file names
inputVideoFile = 'A.MOV';
intermediateVideoFile = 'A_trim_temp.mp4'; % Temporary file
finalOutputFile = 'A_trim_mat.mp4'; % Final output file
% Create VideoReader object
videoReader = VideoReader(inputVideoFile);
% Get the total number of frames and other properties
numFrames = videoReader.NumFrames;
frameRate = videoReader.FrameRate;
videoHeight = videoReader.Height;
videoWidth = videoReader.Width;
% Create VideoWriter object
videoWriter = VideoWriter(intermediateVideoFile, 'MPEG-4');
videoWriter.FrameRate = frameRate;
open(videoWriter);
% Read and write frames except the last 5
for i = 1:(numFrames - 5)
    frame = read(videoReader, i);
    writeVideo(videoWriter, frame);
end
% Close the VideoWriter object
close(videoWriter);
% Handle audio extraction and trimming
% This requires an external tool like FFmpeg, as MATLAB does not handle audio directly
% Command to extract audio
audioExtractCommand = sprintf('ffmpeg -i "%s" -q:a 0 -map a audio_original.wav', inputVideoFile);
[status, cmdout] = system(audioExtractCommand);
if status ~= 0
    error('Error extracting audio: %s', cmdout);
end
% Command to trim audio (matching the length of the trimmed video)
audioTrimCommand = sprintf('ffmpeg -i audio_original.wav -ss 0 -t %f -c copy audio_trimmed.wav', (numFrames - 5) / frameRate);
[status, cmdout] = system(audioTrimCommand);
if status ~= 0
    error('Error trimming audio: %s', cmdout);
end
% Command to merge trimmed audio with the video
audioMergeCommand = sprintf('ffmpeg -i "%s" -i audio_trimmed.wav -c:v copy -c:a aac -strict experimental "%s"', intermediateVideoFile, finalOutputFile);
[status, cmdout] = system(audioMergeCommand);
if status ~= 0
    error('Error merging audio and video: %s', cmdout);
end
% Clean up temporary audio files
delete('audio_original.wav');
delete('audio_trimmed.wav');
delete(intermediateVideoFile); % Delete the intermediate file


    


    When I run the above code for Video B, I change

    


    for i = 1:(numFrames - 5)


    


    to

    


    for i = 1:(numFrames - 1)


    


    to remove the padded last frame.

    


    When I run this for both videos, they both return the same frame number (yay !). The timestamps of every frame between A_trim_mat and B_trim_mat match, except for the timestamp of the last frame ( A_trim_mat = 30.8910, B_trim_mat = 30.8890), and perhaps most concerningly, the frame duration between the last two frames of each video is negative (A_trim_mat = -0.0063, B_trim_mat = -0.0083). The duration for all other frames is constant at 0.0083 for both videos.

    


    Any suggestions for how to remedy this are much appreciated. Ideally, I want the timestamps for every frame to match between A and B, and I want the frame duration for each frame to match between A and B.

    


  • How to get first packet of data using ffmpeg ?

    29 novembre 2017, par Ashok Tandan

    A program is streaming 2 things : a video and a KLV data.I am in a situation where running ffmpeg should get me first frame of image and first packet/frame of data also.I am able to get first frame as soon as i run ffmpeg command,now i want to get corresponding data packet/data.

  • Embedding SMPTE 336M KLV data into video

    8 décembre 2023, par Mateo

    I have a drone video in .MP4 format, and an accompanying log file containing various timecoded data, e.g. GPS location, altitude.

    



    I need to embed the data into the video in the SMPTE 336M (KLV Data Encoding Protocol Using Key-Length-Value) standard format.

    



    I've successfully extracted KLV data from a MPEG2-TS file using FFMPEG and a parser in Node.

    



    Now I need to go the other way : to generate KLV data from my log file and insert it into the relevant video. How this is done ?