Recherche avancée

Médias (33)

Mot : - Tags -/creative commons

Autres articles (100)

  • Personnaliser en ajoutant son logo, sa bannière ou son image de fond

    5 septembre 2013, par

    Certains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;

  • Le profil des utilisateurs

    12 avril 2011, par

    Chaque utilisateur dispose d’une page de profil lui permettant de modifier ses informations personnelle. Dans le menu de haut de page par défaut, un élément de menu est automatiquement créé à l’initialisation de MediaSPIP, visible uniquement si le visiteur est identifié sur le site.
    L’utilisateur a accès à la modification de profil depuis sa page auteur, un lien dans la navigation "Modifier votre profil" est (...)

  • Configurer la prise en compte des langues

    15 novembre 2010, par

    Accéder à la configuration et ajouter des langues prises en compte
    Afin de configurer la prise en compte de nouvelles langues, il est nécessaire de se rendre dans la partie "Administrer" du site.
    De là, dans le menu de navigation, vous pouvez accéder à une partie "Gestion des langues" permettant d’activer la prise en compte de nouvelles langues.
    Chaque nouvelle langue ajoutée reste désactivable tant qu’aucun objet n’est créé dans cette langue. Dans ce cas, elle devient grisée dans la configuration et (...)

Sur d’autres sites (12830)

  • Add headers to mpegts.js request

    8 avril 2023, par Alex Dalen

    I'm very new in web technologies. I have a .ts video accessed by my api and for security reason I need to add 'x-access-token' to my request, but really do not how. Maybe you know ?

    


    play(){
  if (mpegts.getFeatureList().mseLivePlayback) {
    var videoElement = document.getElementById('video-js-node');
    var player = mpegts.createPlayer({
       type: 'm2ts',
       isLive: true,
       headers: {'x-access-token': localStorage.getItem('data')},
       url: `/my/api/${record}`,
     });
     player.attachMediaElement(videoElement);
     player.load();
     player.play();
  }
}


    


  • MVC RTSP forwarding request

    27 octobre 2015, par Benny Chen

    I’d like to restream my rtsp ip camera to be accessible from outside by make request to my web server. I have play around using ffserver and ffmpeg. But it always gave me about 10 seconds of latency on whatever setting. I have tried -fflags nobuffer, playing the value of probesize and analyzeduration, add zerolatency, etc. So I gave up using ffserver to be used as restreaming server.

    If there is no restreaming, just using the ffmpeg to output to a file or view, it gaves low latency below 1 sec.

    Now I am thinking to let the client to have indirect access to the camera to eliminate using restreaming server. My question is, how to forward a rtsp request coming to my server to my ip camera. My web server has 2 network interface. One for internal, which the ip camera connected, and the other for public access. I’d like to keep my ip camera keep private in internal network/not exposed to the internet. So I would like to forward incoming rtsp request to my ip camera.

    I work in MVC and IIS 7.5

  • Google Speech API "Sample rate in request does not match FLAC header"

    13 février 2017, par kjdion84

    I’m trying to convert an mp4 video clip into a FLAC audio file and then have google speech spit out the words from the video so that I can detect if specific words were said.

    I have everything working except that I am getting an error from the Speech API :

    {
     "error": {
       "code": 400,
       "message": "Sample rate in request does not match FLAC header.",
       "status": "INVALID_ARGUMENT"
     }
    }

    I am using FFMPEG in order to convert the mp4 into a FLAC file. I am specifying that the FLAC file be 16 bits in the command, but when I right click on the FLAC file Windows is telling me it is 302kbps.

    Here is my PHP code :

    // convert mp4 video to 16 bit flac audio file
    $cmd = 'C:/wamp/www/ffmpeg/bin/ffmpeg.exe -i C:/wamp/www/test.mp4 -c:a flac -sample_fmt s16 C:/wamp/www/test.flac';
    exec($cmd, $output);

    // convert flac to text so we can detect if certain words were said
    $data = array(
       "config" => array(
           "encoding" => "FLAC",
           "sampleRate" => 16000,
           "languageCode" => "en-US"
       ),
       "audio" => array(
           "content" => base64_encode(file_get_contents("test.flac")),
       )
    );

    $json_data = json_encode($data);

    $ch = curl_init();
    curl_setopt($ch, CURLOPT_URL, 'https://speech.googleapis.com/v1beta1/speech:syncrecognize?key=MY_API_KEY');
    curl_setopt($ch, CURLOPT_HTTPHEADER, array("Content-Type: application/json"));
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    curl_setopt($ch, CURLOPT_POST, true);
    curl_setopt($ch, CURLOPT_POSTFIELDS, $json_data);
    curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);

    $result = curl_exec($ch);