
Recherche avancée
Médias (1)
-
Sintel MP4 Surround 5.1 Full
13 mai 2011, par
Mis à jour : Février 2012
Langue : English
Type : Video
Autres articles (48)
-
La file d’attente de SPIPmotion
28 novembre 2010, parUne file d’attente stockée dans la base de donnée
Lors de son installation, SPIPmotion crée une nouvelle table dans la base de donnée intitulée spip_spipmotion_attentes.
Cette nouvelle table est constituée des champs suivants : id_spipmotion_attente, l’identifiant numérique unique de la tâche à traiter ; id_document, l’identifiant numérique du document original à encoder ; id_objet l’identifiant unique de l’objet auquel le document encodé devra être attaché automatiquement ; objet, le type d’objet auquel (...) -
Websites made with MediaSPIP
2 mai 2011, parThis page lists some websites based on MediaSPIP.
-
Creating farms of unique websites
13 avril 2011, parMediaSPIP 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 (4795)
-
Invalid argument error in writing video file using moviepy and ffmpeg
28 janvier 2024, par KresrebI have this code that used to work fine and now isn't. I have this error :


Traceback (most recent call last):
 File "D:\videos\tiktoks\faitsasavoir\bot\mre.py", line 18, in <module>
 clip_final.write_videofile(f"rendus_finaux/output.mp4", fps=24)
 File "", line 2, in write_videofile
 File "C:\Users\Brice\AppData\Local\Programs\Python\Python39\lib\site-packages\moviepy\decorators.py", line 54, in requires_duration
 return f(clip, *a, **k)
 File "", line 2, in write_videofile
 File "C:\Users\Brice\AppData\Local\Programs\Python\Python39\lib\site-packages\moviepy\decorators.py", line 135, in use_clip_fps_by_default
 return f(clip, *new_a, **new_kw)
 File "", line 2, in write_videofile
 File "C:\Users\Brice\AppData\Local\Programs\Python\Python39\lib\site-packages\moviepy\decorators.py", line 22, in convert_masks_to_RGB
 return f(clip, *a, **k)
 File "C:\Users\Brice\AppData\Local\Programs\Python\Python39\lib\site-packages\moviepy\video\VideoClip.py", line 300, in write_videofile
 ffmpeg_write_video(self, filename, fps, codec,
 File "C:\Users\Brice\AppData\Local\Programs\Python\Python39\lib\site-packages\moviepy\video\io\ffmpeg_writer.py", line 228, in ffmpeg_write_video
 writer.write_frame(frame)
 File "C:\Users\Brice\AppData\Local\Programs\Python\Python39\lib\site-packages\moviepy\video\io\ffmpeg_writer.py", line 180, in write_frame
 raise IOError(error)
OSError: [Errno 22] Invalid argument

MoviePy error: FFMPEG encountered the following error while writing file rendus_finaux/output.mp4:

 b'rendus_finaux/output.mp4: No such file or directory\r\n'
</module>


It tried different versions of
moviepy
, Python and reinstallingffmpeg
etc, but couldn't solve it. My main idea is that is a version problem, but i can't find out.

I recreated the error with this mre, it's just a code to make a video from multiple images. Thank you for your help.


from moviepy.editor import ImageClip, CompositeVideoClip, concatenate_videoclips
 
 DURATION_PER_IMAGE = 5
 
 images = ["D:/videos/image1.png","D:/videos/image1.jpg"]
 
 clips = []
 for image in images:
 #Main image
 clip = ImageClip(image).set_duration(DURATION_PER_IMAGE).resize(width=1080)
 clip = clip.resize(lambda t : 1+0.02*t)
 
 #Create clip composite
 clip_composite = CompositeVideoClip([clip.set_position("center")], size=(1080,1920))
 clips.append(clip_composite) # Add created clip to the list of clips
 
 clip_final = concatenate_videoclips(clips)
 clip_final.write_videofile(f"rendus_finaux/output.mp4", fps=24)



-
How to convert video file to audio file by using FFMPEG ?
15 janvier 2020, par Aamir NaseerI’m making video to audio converter app but need help to convert video to audio using ffmpeg. I checked many answers and websites but their answers are not easy to understand and I’m confused with command that is used to convert. What is the proper command to convert video to audio and is I’m executing the command in right way ?
public class VideoConvertActivity extends AppCompatActivity {
private VideoView videoView;
private Button convertButton;
private String filePath;
private FFmpeg ffmpeg;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_video_convert);
videoView = findViewById(R.id.videoviewID);
convertButton = findViewById(R.id.convertbuttonID);
ffmpeg = FFmpeg.getInstance(VideoConvertActivity.this);
// in variable video i'm getting the path of video path from previous activity through intent and that video will have to convert to audio file
Intent extras = getIntent();
final String video = extras.getStringExtra("video");
videoView.setVideoPath(video);
videoView.start();
convertButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
try {
File moviesDir = Environment.getExternalStoragePublicDirectory(
Environment.DIRECTORY_MUSIC
);
String filePrefix = "convert_audio";
String fileExtn = ".mp3";
File dest = new File(moviesDir, filePrefix + fileExtn);
int fileNo = 0;
while (dest.exists()) {
fileNo++;
dest = new File(moviesDir, filePrefix + fileNo + fileExtn);
}
filePath = dest.getAbsolutePath();
// to execute "ffmpeg -version" command you just need to pass "-version"
String[] command = {"-y", "-i", video, "-vn", "-ar", "44100", "-ac", "2", "-b:a", "256k", "-f", "mp3", filePath};
ffmpeg.execute(command, new ExecuteBinaryResponseHandler() {
@Override
public void onStart() {
Toast.makeText(VideoConvertActivity.this,"Started",Toast.LENGTH_LONG).show();
}
@Override
public void onProgress(String message) {
Toast.makeText(VideoConvertActivity.this,"Progress",Toast.LENGTH_LONG).show();
}
@Override
public void onFailure(String message) {
Toast.makeText(VideoConvertActivity.this,"Failed",Toast.LENGTH_LONG).show();
}
@Override
public void onSuccess(String message) {
Toast.makeText(VideoConvertActivity.this,"Succeed",Toast.LENGTH_LONG).show();
}
@Override
public void onFinish() {
Toast.makeText(VideoConvertActivity.this,"Finished",Toast.LENGTH_LONG).show();
}
});
} catch (FFmpegCommandAlreadyRunningException e) {
// Handle if FFmpeg is already running
}
Toast.makeText(VideoConvertActivity.this,"Converted Successfully",Toast.LENGTH_SHORT).show();
}
});
}
} -
How can i combine a 1 video file (flv) with image file using ffmpeg ?
6 mars 2016, par user6964I have the following question. I need to combine 1 video (.Flv) to an image (png or jpg) generating a new video (.Flv) and then combine it with another video (.Flv). The flow should be as follows :
First, combine a video image where the video should play normally until the last second and then the image should appear.
Second, combining the resulting video with another video.
I tried to do the first step with the following command :
ffmpeg-i-loop_input movie_1.flv picture.png-i-acodec copy-shortest movie_output.flv
But the result is that the image is displayed over video.
Then try connecting 2 flv videos with the following command :
ffmpeg-i-i movie_2.flv output_final.flv movie_output.flv
But only shows 1 video in "output_final.flv".
Can you tell me I’m doing wrong in my command ?
Thank you.