Recherche avancée

Médias (1)

Mot : - Tags -/Christian Nold

Autres articles (40)

  • Les statuts des instances de mutualisation

    13 mars 2010, par

    Pour des raisons de compatibilité générale du plugin de gestion de mutualisations avec les fonctions originales de SPIP, les statuts des instances sont les mêmes que pour tout autre objets (articles...), seuls leurs noms dans l’interface change quelque peu.
    Les différents statuts possibles sont : prepa (demandé) qui correspond à une instance demandée par un utilisateur. Si le site a déjà été créé par le passé, il est passé en mode désactivé. publie (validé) qui correspond à une instance validée par un (...)

  • L’espace de configuration de MediaSPIP

    29 novembre 2010, par

    L’espace de configuration de MediaSPIP est réservé aux administrateurs. Un lien de menu "administrer" est généralement affiché en haut de la page [1].
    Il permet de configurer finement votre site.
    La navigation de cet espace de configuration est divisé en trois parties : la configuration générale du site qui permet notamment de modifier : les informations principales concernant le site (...)

  • Selection of projects using MediaSPIP

    2 mai 2011, par

    The examples below are representative elements of MediaSPIP specific uses for specific projects.
    MediaSPIP farm @ Infini
    The non profit organizationInfini develops hospitality activities, internet access point, training, realizing innovative projects in the field of information and communication technologies and Communication, and hosting of websites. It plays a unique and prominent role in the Brest (France) area, at the national level, among the half-dozen such association. Its members (...)

Sur d’autres sites (5054)

  • use ffmpeg in vba to change video format

    12 juin 2013, par Iban Arriola

    I want to change the video format of the embedded videos that appears in a presentation. I achieve to export the video file to another folder using the following code :

           Dim Finame As Variant
           Dim oApp As Object
           Dim StoreFolder As Variant
           Dim Videoname As Variant
           Dim FileNameFolder As Variant

           MkDir "C:\template\videoZip"

           Set oApp = CreateObject("Shell.Application")
           FileNameFolder = "C:\template\videoZip\"
           Finame = ActivePresentation.Path & "\" & ActivePresentation.Name
           StoreFolder = "C:\template\created_files\"
           oApp.Namespace("C:\template\videoZip\").CopyHere Finame
           Name "C:\template\videoZip\" & ActivePresentation.Name As "C:\template\videoZip\" & ActivePresentation.Name & ".zip"


           oApp.Namespace(FileNameFolder).CopyHere oApp.Namespace("C:\template\videoZip\" & ActivePresentation.Name & ".zip").items

           Dim firstCount As Integer
           Dim lastCount As Integer

           For j = 1 To videoNum
               firstCount = oApp.Namespace(StoreFolder).items.count
               Videoname = "C:\template\videoZip\ppt\media\media" & j & ".mp4"
               oApp.Namespace(StoreFolder).CopyHere Videoname
               lastCount = oApp.Namespace(StoreFolder).items.count
               If firstCount = lastCount Then
                   MsgBox "The video has problems loading and it will not be shown (Only mp4 supported)"
               End If
           Next j

           Set objFSO = CreateObject("Scripting.FileSystemObject")
           objFSO.deletefolder "C:\template\videoZip"
       End If

    As I said, with this peace of code I can get all the videos that are in the presentation. Now I want to change the format of them. I heard that it is possible using ffmpeg. Other solutions to change format are welcome too.

  • use ffmpeg in vba to change video format

    3 juillet 2020, par Iban Arriola

    I want to change the video format of the embedded videos that appears in a presentation. I achieve to export the video file to another folder using the following code :

    



            Dim Finame As Variant
        Dim oApp As Object
        Dim StoreFolder As Variant
        Dim Videoname As Variant
        Dim FileNameFolder As Variant

        MkDir "C:\template\videoZip"

        Set oApp = CreateObject("Shell.Application")
        FileNameFolder = "C:\template\videoZip\"
        Finame = ActivePresentation.Path & "\" & ActivePresentation.Name
        StoreFolder = "C:\template\created_files\"
        oApp.Namespace("C:\template\videoZip\").CopyHere Finame
        Name "C:\template\videoZip\" & ActivePresentation.Name As "C:\template\videoZip\" & ActivePresentation.Name & ".zip"


        oApp.Namespace(FileNameFolder).CopyHere oApp.Namespace("C:\template\videoZip\" & ActivePresentation.Name & ".zip").items

        Dim firstCount As Integer
        Dim lastCount As Integer

        For j = 1 To videoNum
            firstCount = oApp.Namespace(StoreFolder).items.count
            Videoname = "C:\template\videoZip\ppt\media\media" & j & ".mp4"
            oApp.Namespace(StoreFolder).CopyHere Videoname
            lastCount = oApp.Namespace(StoreFolder).items.count
            If firstCount = lastCount Then
                MsgBox "The video has problems loading and it will not be shown (Only mp4 supported)"
            End If
        Next j

        Set objFSO = CreateObject("Scripting.FileSystemObject")
        objFSO.deletefolder "C:\template\videoZip"
    End If


    



    As I said, with this peace of code I can get all the videos that are in the presentation. Now I want to change the format of them. I heard that it is possible using ffmpeg. Other solutions to change format are welcome too.

    


  • How do I change the speed of an audio file in Python, like in Audacity, without quality loss ?

    23 août 2023, par Somnia Quia

    I'm building a simple Python application that involves altering the speed of an audio track.
(I acknowledge that changing the framerate of an audio also make pitch appear different, and I do not care about pitch of the audio being altered).
I have tried using solution from abhi krishnan using pydub, which looks like this.

    


    from pydub import AudioSegment
sound = AudioSegment.from_file(…)

def speed_change(sound, speed=1.0):
    # Manually override the frame_rate. This tells the computer how many
    # samples to play per second
    sound_with_altered_frame_rate = sound._spawn(sound.raw_data, overrides={
         "frame_rate": int(sound.frame_rate * speed)
      })
     # convert the sound with altered frame rate to a standard frame rate
     # so that regular playback programs will work right. They often only
     # know how to play audio at standard frame rate (like 44.1k)
    return sound_with_altered_frame_rate.set_frame_rate(sound.frame_rate)


    


    However, the audio with changed speed sounds distorted, or crackled, which would not be heard with using Audacity to do the same, and I hope I find out a way to reproduce in Python how Audacity (or other digital audio editors) changes the speed of audio tracks.

    


    I presume that the quality loss is caused by the original audio having low framerate, which is 8kHz, and that .set_frame_rate(sound.frame_rate) tries to sample points of the audio with altered speed in the original, low framerate. Simple attempts of setting the framerate of the original audio or the one with altered framerate, and the one that were to be exported didn't work out.

    


    Is there a way in Pydub or in other Python modules that perform the task in the same way Audacity does ?