
Recherche avancée
Médias (91)
-
Les Miserables
9 décembre 2019, par
Mis à jour : Décembre 2019
Langue : français
Type : Textuel
-
VideoHandle
8 novembre 2019, par
Mis à jour : Novembre 2019
Langue : français
Type : Video
-
Somos millones 1
21 juillet 2014, par
Mis à jour : Juin 2015
Langue : français
Type : Video
-
Un test - mauritanie
3 avril 2014, par
Mis à jour : Avril 2014
Langue : français
Type : Textuel
-
Pourquoi Obama lit il mes mails ?
4 février 2014, par
Mis à jour : Février 2014
Langue : français
-
IMG 0222
6 octobre 2013, par
Mis à jour : Octobre 2013
Langue : français
Type : Image
Autres articles (109)
-
MediaSPIP 0.1 Beta version
25 avril 2011, parMediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
The zip file provided here only contains the sources of MediaSPIP in its standalone version.
To get a working installation, you must manually install all-software dependencies on the server.
If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...) -
Multilang : améliorer l’interface pour les blocs multilingues
18 février 2011, parMultilang est un plugin supplémentaire qui n’est pas activé par défaut lors de l’initialisation de MediaSPIP.
Après son activation, une préconfiguration est mise en place automatiquement par MediaSPIP init permettant à la nouvelle fonctionnalité d’être automatiquement opérationnelle. Il n’est donc pas obligatoire de passer par une étape de configuration pour cela. -
HTML5 audio and video support
13 avril 2011, parMediaSPIP 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 (...)
Sur d’autres sites (7934)
-
How to install MPD filter "ffmpeg" into MPD running on RaspberryPi [closed]
13 mai, par Weston MitchellI’m using Moode audio player OS on a Raspberry Pi 5 to play audio through two USB devices : headphones (card 3 : Device_1) for the full spectrum and a subwoofer (card 0 : Device) for low frequencies (20–100Hz) in a meditation lounge setup. The audio source is a NAS on a Mac. My goal is simultaneous playback : headphones in stereo, subwoofer in mono with low-pass filtering. I have configured the mpd.conf file to setup audio ouputs for both devices. Now I need to apply a lowpass filter to the subwoofer device. I tried using MDP's "ffmpeg" as a lowpass filter, but the logs say :




Failed to initialize filter chain for "Subwoofer" : No such filter plugin : ffmpeg




So I checked MPD's list of filters using
mpd --version
and it shows only one filter :



Decoder plugins :

[mpg123] mp3

[mad] mp3 mp2

[vorbis] ogg oga

[oggflac] ogg oga

[flac] flac

[opus] opus ogg oga

[dsdiff] dff

[dsf] dsf

[faad] aac

[wavpack] wv

[adplug] amd d00 hsc laa rad raw sa2

[ffmpeg] 264 265 ...

Filters :

soxr

Tag plugins :

id3tag

...




So it's listed as a Decoder, but not a as a filter. MPD docs says it can be used as a filter : MPD Docs - Filters


So how do I add the ffmpeg to the list of filters ?


-
Button "Clean FFMeta" does nothing after compiling with PyInstaller
6 mai, par Leonie HoldermannI’m working on my first Python project and I’ve compiled it into an executable using PyInstaller with the following command :


pyinstaller --onefile --noconsole app.py



However, when I run the executable, the button "Clean FFMeta" which triggers the clean_ffmeta() function does nothing. Additionally, changing the language or the chapter settings under the "Options -> Chapter settings" menu doesn’t seem to affect anything either. It all works perfectly in the Python script before compilation, but once compiled into an .exe, none of these functions respond.


I've reviewed the code, and the button is correctly linked to the function, but I suspect something might be going wrong during the compilation process.


What I have tried :


- 

- Checked that all dependencies are included.
- Verified that the configuration and language changes are being correctly applied before compilation.
- Tried running the executable from a console to check for error messages, but there are none visible (since I used —noconsole).








What I expect :


- 

- The "Clean FFMeta" button should clean the FFMeta file based on the
user settings.
- Language and chapter settings should be updated and reflected in the GUI immediately.






Code :
Below is a simplified version of my code, especially the sections related to the "Clean FFMeta" functionality and language/chapter settings.


def clean_ffmeta():
if not config.get("cd_in_path"):
 show_error(texts[current_language]["error"] + " No CD_IN path configured.")
 return

chapter_path = os.path.join(config["cd_in_path"], "chapters.ffmeta")
cleaned_chapter_path = os.path.join(config["cd_in_path"], "chapters_cleaned.ffmeta")

if not os.path.exists(chapter_path):
 show_error(texts[current_language]["no_chapters_file"])
 return

write_to_console("Starting to clean FFMeta...")
thread = threading.Thread(target=clean_ffmeta_thread, args=(chapter_path, cleaned_chapter_path))
thread.start()

def clean_ffmeta_thread(chapter_path, cleaned_chapter_path):
 try:
 chapter_action = config.get("chapter_action", "clean")
 keep_empty = config.get("chapter_keep_empty", False)

 write_to_console(f"Chapter action: {chapter_action}, Keep empty: {keep_empty}")

 with open(chapter_path, "r", encoding="utf-8") as f:
 lines = f.readlines()

 new_lines = []
 chapter_counter = 0

 for line in lines:
 stripped_line = line.strip()
 if stripped_line.startswith("title="):
 title_content = stripped_line[6:]
 
 if chapter_action == "clean":
 if title_content == "":
 if keep_empty:
 new_lines.append(line)
 else:
 write_to_console("Empty title skipped.")
 continue
 else:
 new_lines.append(line)
 
 elif chapter_action == "number":
 chapter_counter += 1
 chapter_title = f"{texts[current_language]['chapter']} {chapter_counter}"
 new_lines.append(f"title={chapter_title}\n")
 write_to_console(f"Renamed to: {chapter_title}")
 else:
 new_lines.append(line)

 with open(cleaned_chapter_path, "w", encoding="utf-8") as f:
 f.writelines(new_lines)

 write_to_console(f"FFMeta cleaned and saved as '{cleaned_chapter_path}'.")

 except Exception as e:
 write_to_console(f"Error cleaning FFMeta: {str(e)}")

def open_chapter_settings():
 global chapter_settings_window, chapter_action_var
 global chapter_keep_empty_checkbox, chapter_save_button

 chapter_settings_window = tk.Toplevel(root)
 chapter_settings_window.title(texts[current_language]["chapter_setting_title"])
 chapter_settings_window.geometry("300x250")
 chapter_settings_window.resizable(False, False)
 
 chapter_action_var = tk.StringVar(value=config.get("chapter_action", "clean"))
 chapter_keep_empty_var = tk.BooleanVar(value=config.get("chapter_keep_empty", False))
 
 tk.Label(
 chapter_settings_window,
 text=texts[current_language]["chapter_setting_choose_option"]
 ).pack(pady=(10, 5))
 
 tk.Radiobutton(
 chapter_settings_window,
 text=texts[current_language]["chapter_setting_clean"],
 variable=chapter_action_var,
 value="clean"
 ).pack(pady=5)

 tk.Radiobutton(
 chapter_settings_window,
 text=texts[current_language]["chapter_setting_number"],
 variable=chapter_action_var,
 value="number"
 ).pack(pady=5)

 chapter_keep_empty_checkbox = tk.Checkbutton(
 chapter_settings_window,
 text=texts[current_language]["chapter_setting_keep_empty"],
 variable=chapter_keep_empty_var
 )
 chapter_keep_empty_checkbox.pack(pady=5)

 chapter_save_button = tk.Button(
 chapter_settings_window,
 text=texts[current_language]["chapter_setting_save"],
 command=lambda: save_chapter_settings(chapter_keep_empty_var, chapter_settings_window)
 )
 chapter_save_button.pack(pady=10)

def save_chapter_settings(keep_empty_var, window):
 config["chapter_action"] = chapter_action_var.get()
 config["chapter_keep_empty"] = keep_empty_var.get()
 save_config()
 write_to_console(f"Chapter settings saved: Action={config['chapter_action']}, Keep empty={config['chapter_keep_empty']}")
 window.destroy()

options_menu = tk.Menu(menu, tearoff=0)
options_menu.add_command(label="Check pip-ffmpeg", command=check_pip_ffmpeg)
options_menu.add_command(label=texts[current_language]["menu_chapter_settings"], command=open_chapter_settings)
menu.add_cascade(label="Options", menu=options_menu)

btn3 = tk.Button(btn_frame, text="3. Clean FFMeta", command=clean_ffmeta)
btn3.grid(row=0, column=2, padx=5)



Here you find the entire project code of the entire project : https://www.pythonmorsels.com/p/32hkh/


Why is the clean_chapters function not working ?


-
ffmpeg throws error "Invalid file index 1 in filtergraph description" when used with concat and -/filter_complex [closed]
20 février, par Ernst VI want to create mp4 videos from many small .jpg files (time-lapse). Each image is shown for 2 seconds and then fades to the next. This works fine when I issue the command with a few images (see below). But when the number of images reaches hundreds or thousands, I can no longer put them into a single command, but have to put the filenames and the complex filter into .txt files.


Whatever I try, I always get the error
"Invalid file index 1 in filtergraph description"
.

This works fine :


ffmpeg -loop 1 -i "image1.jpg" -loop 1 -i "image2.jpg" -loop 1 -i "image3.jpg" -loop 1 -i "image4.jpg" -loop 1 -i "image5.jpg" -filter_complex "[0:v]trim=0:2,setpts=PTS-STARTPTS[v0]; [1:v]trim=0:2,setpts=PTS-STARTPTS[v1]; [2:v]trim=0:2,setpts=PTS-STARTPTS[v2]; [3:v]trim=0:2,setpts=PTS-STARTPTS[v3]; [4:v]trim=0:2,setpts=PTS-STARTPTS[v4]; [v0][v1] xfade=transition=fade:duration=1:offset=1 [xf1]; [xf1][v2] xfade=transition=fade:duration=1:offset=2 [xf2]; [xf2][v3] xfade=transition=fade:duration=1:offset=3 [xf3]; [xf3][v4] xfade=transition=fade:duration=1:offset=4 [xf4]" -map "[xf4]" -c:v libx264 -crf 18 -pix_fmt yuv420p output.mp4



But when I put the input files and the filter in txt files, it fails with the error above :


ffmpeg -stream_loop 1 -f concat -safe 0 -i concat_list.txt -/filter_complex filter_script.txt -map "[xf4]" -c:v libx264 -crf 18 -pix_fmt yuv420p output.mp4



This is the
concat_list.txt
:

file 'image1.jpg'
file 'image2.jpg'
file 'image3.jpg'
file 'image4.jpg'
file 'image5.jpg'



This is the
filter_script.txt
:

[0:v]trim=0:2,setpts=PTS-STARTPTS[v0];[1:v]trim=0:2,setpts=PTS-STARTPTS[v1];[2:v]trim=0:2,setpts=PTS-STARTPTS[v2];[3:v]trim=0:2,setpts=PTS-STARTPTS[v3];[4:v]trim=0:2,setpts=PTS-STARTPTS[v4];[v0][v1] xfade=transition=fade:duration=1:offset=1 [xf1];[xf1][v2] xfade=transition=fade:duration=1:offset=2 [xf2];[xf2][v3] xfade=transition=fade:duration=1:offset=3 [xf3];[xf3][v4] xfade=transition=fade:duration=1:offset=4 [xf4]



I tried adding/removing line breaks, semicolons, etc. Nothing helped.
Any idea what is going wrong here ? Thank you very much !


My ffmpeg version is the most recent one :


ffmpeg version 2025-02-17-git-b92577405b-full_build-www.gyan.dev