Recherche avancée

Médias (3)

Mot : - Tags -/pdf

Autres articles (52)

  • Gestion générale des documents

    13 mai 2011, par

    MédiaSPIP ne modifie jamais le document original mis en ligne.
    Pour chaque document mis en ligne il effectue deux opérations successives : la création d’une version supplémentaire qui peut être facilement consultée en ligne tout en laissant l’original téléchargeable dans le cas où le document original ne peut être lu dans un navigateur Internet ; la récupération des métadonnées du document original pour illustrer textuellement le fichier ;
    Les tableaux ci-dessous expliquent ce que peut faire MédiaSPIP (...)

  • Des sites réalisés avec MediaSPIP

    2 mai 2011, par

    Cette page présente quelques-uns des sites fonctionnant sous MediaSPIP.
    Vous pouvez bien entendu ajouter le votre grâce au formulaire en bas de page.

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

Sur d’autres sites (6412)

  • ffmpeg segments only the first part of my audio file

    30 juin 2012, par hammat

    I'm implementing a http live streaming server to send audio file to iOS devices.
    No problem with Apple's tools, mediafilesegmenter, my files are valid and it works fine.

    I'm trying now to segment the same file using ffmpeg. I've downloaded the last stable version which is the 0.10.2 for now.

    Here is how I try to segment my mp3 file :

    ./ffmpeg -re -i input.mp3 -f segment -segment_time 10 -segment_list outputList.m3u8 -acodec libmp3lame -map 0 output%03d.mp3

    It starts the mapping like expected but finish with only one .mp3 file.

    Did I miss something in the process ?
    Thanks in advance.

    edit

    Ok here is my latest command line :

    ffmpeg -i input.mp3 -c:a libmp3lame -b:a 128k -map 0:0 -f segment -segment_time 10 -segment_list outputlist.m3u8 -segment_format mp3 'output%03d.mp3'

    It still gives me only one file but the file is the hole song, not only one part.
    Here is the output of ffmpeg :

    ffmpeg version 0.10.2 Copyright (c) 2000-2012 the FFmpeg developers
    built on Apr 20 2012 07:08:29 with gcc 4.5.2  
    configuration: --enable-gpl --enable-version3 --enable-nonfree --enable-postproc --enable-libmp3lame  
       libavutil      51. 35.100 / 51. 35.100  
       libavcodec     53. 61.100 / 53. 61.100  
       libavformat    53. 32.100 /
           53. 32.100  
       libavdevice    53.  4.100 / 53.  4.100  
       libavfilter     2. 61.100 /  2. 61.100  
       libswscale      2.  1.100 /  2.  1.100  
       libswresample   0.  6.100 /  0.  6.100  
       libpostproc    52.  0.100 /  52.  0.100
       [mp3 @ 0x8e4f120] max_analyze_duration 5000000 reached at 5015510
    Input #0, mp3, from 'BeachHouse-Myth.mp3':  
       Metadata:
               title           : Myth
               artist          : Beach House
               track           : /
               album           : Bloom
               disc            : /
               genre           : Alternative
               TSRC            : USSUB1296501  
       Duration: 00:04:18.69, start: 0.000000, bitrate: 320 kb/s
               Stream #0:0: Audio: mp3, 44100 Hz, stereo, s16, 320 kb/s Output #0, segment, to 'stream%03d.mp3':   Metadata:
               title           : Myth
               artist          : Beach House
               track           : /
               album           : Bloom
               disc            : /
               genre           : Alternative
               TSRC            : USSUB1296501
               encoder         : Lavf53.32.100
               Stream #0:0: Audio: mp3, 44100 Hz, stereo, s16, 128 kb/s
    Stream mapping:  
       Stream #0:0 -> #0:0 (mp3 -> libmp3lame)
       Press [q] to stop, [?] for help
       Truncating packet of size 1024 to 105ate=   0.0kbits/s    
       Truncating packet of size 1024 to 1
       size=       0kB time=00:04:18.71 bitrate=   0.0kbits/s     video:0kB audio:4042kB global headers:0kB muxing overhead -100.000000%
  • Video streaming FFMPEG - VLC video starts black

    7 novembre 2020, par xKedar

    I am trying to stream my webcam when an event occurs to another machine.
Giving the fact that FFMPEG needs around 2 seconds since I call it to when it starts streaming I'm running it in background sending everything to a local socket that consumes it until the event happens and then I reverse the data to the other machine

    


    Here I capture the camera

    


    class ffmpegThread (Thread):
    def __init__(self):
        Thread.__init__(self)
     
    def run(self):
        cam, mic = detect_devices()
        command = 'ffmpeg -f dshow -i video='+cam+':audio='+mic+' -profile:v high -pix_fmt yuvj420p -level:v 4.1 -preset ultrafast -tune zerolatency -vcodec libx264 -r 14 -b:v 512k -s 240x160 -acodec aac -ac 2 -ab 32k -ar 44100 -f mpegts -flush_packets 0 udp://127.0.0.1:'+str(config.ffmpeg_port)+'?pkt_size=1316'
        p = Popen(command , stderr=PIPE)
        for line in iter(p.stderr.readline,''):
           if config.end: break
        p.terminate()
        return 0


    


    This is where I receive and forward the video

    


    
class sendVideoThread (Thread):
    def __init__(self, UDPsenderSocket):
        Thread.__init__(self)
        self.UDPsenderSocket = UDPsenderSocket
 
    def run(self):
        sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
        sock.bind(("127.0.0.1", config.ffmpeg_port))
        bufferSize  = 1348
        firstData = sock.recvfrom(bufferSize)
        while True:
            data = sock.recvfrom(bufferSize)
            if config.event == True:
                startTime = time.time()
                self.UDPsenderSocket.sendto(firstData[0], config.address)
                while time.time() - startTime < 14:
                    self.UDPsenderSocket.sendto(data[0], config.address) 
                    data = sock.recvfrom(bufferSize)                    
                config.event= False
            if config.end: sys.exit()



    


    And those are the vlc options on the other machine(not the whole code)

    


        def play(self):
        self.player = vlc.Instance(["--file-caching=0 --network-caching=0"]).media_player_new()
        self.player.set_mrl('udp://@0.0.0.0:'+str(config.vlcPlayer_port))
        self.player.set_hwnd(self.frame.winfo_id())
        self.player.audio_set_mute(False)
        self.player.play()



    


    The video reaches the other machine but it starts black with audio-only for some seconds then it starts working fine. I guess that by sending the video from a random moment(frame) when the event happens it may happen that vlc will miss some information about the video and needs the next frame with information to come in order to show the video, I was looking to something in order to have more frames with that info but I was not able to find it.

    


  • swr : split out DSP functions.

    14 juin 2014, par Ronald S. Bultje
    swr : split out DSP functions.
    

    DSP bits of swri_resample go into their own mini-DSP functions ; DSP
    init goes from a per-call branch in multiple_resample to a proper
    DSP init routine ; x86 bits go into x86/ ; swri_resample() moves out of
    resample_template.c into resample.c because it’s independent of DSP
    code or sample type ; multiple_resample() is simplified.

    Signed-off-by : Michael Niedermayer <michaelni@gmx.at>

    • [DH] libswresample/Makefile
    • [DH] libswresample/resample.c
    • [DH] libswresample/resample.h
    • [DH] libswresample/resample_dsp.c
    • [DH] libswresample/resample_template.c
    • [DH] libswresample/x86/Makefile
    • [DH] libswresample/x86/resample_x86_dsp.c