
Recherche avancée
Autres articles (56)
-
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" (...) -
Support audio et vidéo HTML5
10 avril 2011MediaSPIP 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 (...)
Sur d’autres sites (7656)
-
avformat/mxfdec : treat Random Index Pack as end of file
26 mars 2023, par Marton Balintavformat/mxfdec : treat Random Index Pack as end of file
RIP, if exists is the last KLV item in the MXF files therefore we can stop
parsing the file if it is encountered. This allows us to support files created by
broken muxers such as OpenCube MXFTk Advanced 2.8.0.0.1. which dumps some extra
garbage after the RIP.Signed-off-by : Marton Balint <cus@passwd.hu>
-
FFmpegPCMAudio not playing in discord no error
9 mars 2023, par Anton AbboudOkey, it might be something obvious that ive missed but i really can't find the issue. I am currently making a discord-music-bot which has worked fine before. However as soon as i moved over to yt-dlp from youtube-dl (due to an error with youtube-dl) FFmpegPCMAudio doesn't play the music. It read through the code like normal but it simply doesn't play the sound. It even downloads the music from youtube so I am a bit confused. Here is what my code looks like :


class music_cog(commands.Cog):
 
 #Searching the keyword on youtube
 def search_yt(self, item):
 with yt_dlp.YoutubeDL(self.YDL_OPTIONS) as ydl:
 try: 
 info = ydl.extract_info("ytsearch:%s" % item, download=False)['entries'][0]
 except Exception: 
 return False

 return {'source': info['formats'][0]['url'], 'title': info['title']}

 def play_next(self):
 if len(self.music_queue) > 0:
 self.is_playing = True

 
 #Get the first url
 my_url = self.music_queue[0][0]['source']

 global current_song_title
 current_song_title = self.music_queue[0][0]['title']

 #Remove the first song in queue as you are currently playing it
 self.music_queue.pop(0)

 self.vc.play(nextcord.FFmpegPCMAudio(my_url, **self.FFMPEG_OPTIONS), after=lambda e: self.play_next())
 else:
 self.is_playing = False

 # Infinite loop checking if there is a song in queue
 async def play_music(self, ctx):
 if len(self.music_queue) > 0:
 self.is_playing = True
 my_url = self.music_queue[0][0]['source']
 
 global current_song_title
 current_song_title = self.music_queue[0][0]['title']
 
 #Try to connect to voice channel if bot is not already connected
 if self.vc == None or not self.vc.is_connected():
 self.vc = await self.music_queue[0][1].connect()

 #In case the bot fails to connect
 if self.vc == None:
 await ctx.send("Could not connect to the voice channel")
 return
 else:
 await self.vc.move_to(self.music_queue[0][1])
 
 self.music_queue.pop(0)
 print("hello")
 self.vc.play(nextcord.FFmpegPCMAudio(my_url, **self.FFMPEG_OPTIONS), after=lambda e: self.play_next())
 
 else:
 self.is_playing = False

 @commands.command(name="play", aliases=["p"], help="Plays a selected song from youtube")
 async def play(self, ctx, *args):
 query = " ".join(args)
 
 if ctx.author.voice is None:
 #User needs to be connected so that the bot knows where to go
 await ctx.send("Connect to a voice channel!")
 
 elif self.is_paused:
 self.vc.resume()
 
 else:
 global song
 song = self.search_yt(query)
 if type(song) == type(True):
 #In case the song is not able to download
 await ctx.send("Could not download the song. Incorrect format try another keyword. This could be due to playlist or a livestream format.")
 else:
 await ctx.send(f"{song['title']} added to the queue, and gets played if nothing else is in the queue or currently playing")
 voice_channel = ctx.author.voice.channel
 self.music_queue.append([song, voice_channel])
 
 if self.is_playing == False:
 await self.play_music(ctx)



I have tried searching on how to use FFmpeg even though I have made it work before. but I haven't found anything of use. I wanted to convert back to youtube-dl but realized that it still won't work because of an issue in thier code. I can't really try anything else since im not getting an error. The terminal displays :


[youtube:search] Extracting URL: ytsearch:heh 
[download] Downloading playlist: heh 
[youtube:search] query "heh": Downloading web client config
[youtube:search] query "heh" page 1: Downloading API JSON 
[youtube:search] Playlist heh: Downloading 1 items of 1 
[download] Downloading item 1 of 1
[youtube] Extracting URL: https://www.youtube.com/watch?v=8EhaZG7i9Bk
[youtube] 8EhaZG7i9Bk: Downloading webpage
[youtube] 8EhaZG7i9Bk: Downloading android player API JSON 
[download] Finished downloading playlist: heh 
hello



I used "heh" as an example searchword and "hello" to check if the code actually read what it where it is supposed to play the audio.


Please help !


-
The system cannot find the file specified error when trying to execute FFMpeg command with C# (same code works fine in a different app)
5 mars 2023, par m_krI know there are similar questions to this one. I have gone through every single one I could find and nothing worked for me. Here is my issue :


I am trying to execute a FFMpeg command in command-line through .NET.


Before anything I tried doing it with the following code :


public static string executeCommand(string commandToBeExecuted)
 {
 Process cmd = new Process();
 cmd.StartInfo.FileName = "cmd.exe";
 cmd.StartInfo.RedirectStandardInput = true;
 cmd.StartInfo.RedirectStandardOutput = true;
 cmd.StartInfo.CreateNoWindow = true;
 cmd.StartInfo.UseShellExecute = false;
 cmd.Start();

 cmd.StandardInput.WriteLine(commandToBeExecuted);
 cmd.StandardInput.Flush();
 cmd.StandardInput.Close();
 cmd.WaitForExit();
 return cmd.StandardOutput.ReadToEnd();
 }



Sending the "ffmpeg -h" command in commandToBeExecuted. This did not work.


I next tried the following solution :


public static string ffmpegCommand(string commandToBeExecuted)
 {
 ProcessStartInfo startInfo = new ProcessStartInfo();
 startInfo.CreateNoWindow = false;
 startInfo.UseShellExecute = false;
 startInfo.FileName = "c:\\ffmpeg\\bin\\ffmpeg.exe";
 startInfo.WindowStyle = ProcessWindowStyle.Hidden;
 startInfo.Arguments = "-h";

 startInfo.RedirectStandardOutput = true;
 startInfo.RedirectStandardError = true;


 Process exeProcess = Process.Start(startInfo);

 // string error = exeProcess.StandardError.ReadToEnd();
 string output = exeProcess.StandardOutput.ReadToEnd();
 exeProcess.WaitForExit();
 return output;
 }



This returns the following error :




The system cannot find the file specified




I am assuming this is referring to this part of the code :


startInfo.FileName = "c:\\ffmpeg\\bin\\ffmpeg.exe";



However, I checked and this is the correct path to my ffmpeg.exe file. On an even weirder note, this code works correct when tested in a new .net console application. However, I am creating an extension for OutSystems in integration, and when testing this code there it no longer works. The long exception from the logs is the following :




CssbobffmpegCommandTestFolder
System.ComponentModel.Win32Exception : The system cannot find the file specified
at Object.s [as getException] (https://personal-jwy0bfog.outsystemscloud.com/FFMpegCommandGeneratorFFProbeVisual/scripts/OutSystems.js?RnlDcii3Xz75iIHHERIZtA:2:10241)
at c.onSuccess (https://personal-jwy0bfog.outsystemscloud.com/FFMpegCommandGeneratorFFProbeVisual/scripts/OutSystems.js?RnlDcii3Xz75iIHHERIZtA:3:7232)
at XMLHttpRequest. (https://personal-jwy0bfog.outsystemscloud.com/FFMpegCommandGeneratorFFProbeVisual/scripts/OutSystems.js?RnlDcii3Xz75iIHHERIZtA:3:2648)




I researched similar problems and tried the following solutions :


In place of :


startInfo.FileName = "c:\\ffmpeg\\bin\\ffmpeg.exe";



I tried :


startInfo.WorkingDirectory = "c:\\ffmpeg\\bin";
 startInfo.FileName = @"ffmpeg.exe";



I also tried changing the :


startInfo.Arguments = "-h";



to :


startInfo.Arguments = "/C -h";



I tried to "add new item" to my solution : the ffmpeg.exe file, and I tried the following logic :


public static string testingNewApproachTwoThree(string commandToBeExecuted)
 {
 string res;
 ProcessStartInfo startInfo = new ProcessStartInfo();

 startInfo.CreateNoWindow = false;
 startInfo.UseShellExecute = false;
 startInfo.FileName = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "ffmpeg\\ffmpeg.exe");
 startInfo.Arguments = "-h";
 startInfo.RedirectStandardOutput = true;
 //startInfo.RedirectStandardError = true;

 res = string.Format(
 "Executing \"{0}\" with arguments \"{1}\".\r\n",
 startInfo.FileName,
 startInfo.Arguments) + " NEXT: ";

 try
 {
 using (Process process = Process.Start(startInfo))
 {
 while (!process.StandardOutput.EndOfStream)
 {
 res = res + process.StandardOutput.ReadLine();

 }

 process.WaitForExit();
 }
 }
 catch (Exception ex)
 {
 res = res + "exception:" + ex.Message;
 }

 return res;
 }



as suggested in a different question.


I tried changing the capitalization of letters in the specified filepath to make sure it matches the naming of my folders. Nothing worked.


Any ideas ?