Recherche avancée

Médias (21)

Mot : - Tags -/Nine Inch Nails

Autres articles (41)

  • XMP PHP

    13 mai 2011, par

    Dixit Wikipedia, XMP signifie :
    Extensible Metadata Platform ou XMP est un format de métadonnées basé sur XML utilisé dans les applications PDF, de photographie et de graphisme. Il a été lancé par Adobe Systems en avril 2001 en étant intégré à la version 5.0 d’Adobe Acrobat.
    Étant basé sur XML, il gère un ensemble de tags dynamiques pour l’utilisation dans le cadre du Web sémantique.
    XMP permet d’enregistrer sous forme d’un document XML des informations relatives à un fichier : titre, auteur, historique (...)

  • Participer à sa documentation

    10 avril 2011

    La documentation est un des travaux les plus importants et les plus contraignants lors de la réalisation d’un outil technique.
    Tout apport extérieur à ce sujet est primordial : la critique de l’existant ; la participation à la rédaction d’articles orientés : utilisateur (administrateur de MediaSPIP ou simplement producteur de contenu) ; développeur ; la création de screencasts d’explication ; la traduction de la documentation dans une nouvelle langue ;
    Pour ce faire, vous pouvez vous inscrire sur (...)

  • Encodage et transformation en formats lisibles sur Internet

    10 avril 2011

    MediaSPIP transforme et ré-encode les documents mis en ligne afin de les rendre lisibles sur Internet et automatiquement utilisables sans intervention du créateur de contenu.
    Les vidéos sont automatiquement encodées dans les formats supportés par HTML5 : MP4, Ogv et WebM. La version "MP4" est également utilisée pour le lecteur flash de secours nécessaire aux anciens navigateurs.
    Les documents audios sont également ré-encodés dans les deux formats utilisables par HTML5 :MP3 et Ogg. La version "MP3" (...)

Sur d’autres sites (6693)

  • recording yuv data which is converted from a bitmap and images are changed constantly on this bitmap

    3 février 2016, par UserAx

    I am trying to record images which are changed at a set time interval. These are displayed on an imageview. (something like a movie maker)

    For this I am :

    1. Drawing these images on a bitmap, this method is repeated over a 50ms interval

      private void BitmapUpdate() {
            timer = new Timer();
      timer.scheduleAtFixedRate(new TimerTask() {
         public void run() {
             try {
                 new Task1().execute();
             } catch (Exception e) {
                 // TODO: handle exception
             }
         }
      }, 0, 50);
      }

      class Task1 extends AsyncTask {

      @Override
      protected void onPreExecute() {
         super.onPreExecute();
         clearBitmap();

      }

      @Override
      protected String doInBackground(Void... arg0) {

         onImageDisplayed();
         return null;
      }

      @Override
      protected void onPostExecute(String result) {
         super.onPostExecute(result);

      }
      }

      public void clearBitmap(){
      if (imageview != null){
      //All the 3 methods below give same error - can't call getpixels() on recycled bitmap
      imageview.setDrawingCacheEnabled(false);
      //OR
      imageview.destroyDrawingCache();
      //OR
      bitmap.recycle();

      }
        }



      public void onImageDisplayed(){

      if (imageview != null) {
         imageview.setDrawingCacheEnabled(true);
         imageview.buildDrawingCache();
         bitmap = imageview.getDrawingCache();
         System.out.println(bitmap.getByteCount() + " is bitmap size ");
         }
        }
    2. Using the bitmap data to convert it to yuv data
      By using getNV21 method :

    Convert bitmap array to YUV (YCbCr NV21)

    1. Finally this yuv data is passed FFmpeg recorder, through a method similar to onPreviewFrame, except that the data is from getNV21 method. This method is started by a button click.

    What I have achieved :

    1. If i dont use clearBitmap() ; i get only the first image recorded in the video, even on changing to next image only first image is present throughout the video.

    2. So After research on stack overflow many developers suggested clearing the previous imageCache for the next Image. But in my case if i use any of these methods, anywhere,

      imageview.setDrawingCacheEnabled(false);
      //OR
      imageview.destroyDrawingCache();
      //OR
      bitmap.recycle();

    I get the error ; mostly because the getNV21 method is running non stop, and always is expecting pixels flow from the Bitmap.

    1. If i try running the methods one after another, by stopping getpixels for a moment by a boolean, i only get a black screen.

    Kindly help...!

    THANKS.

  • Anomalie #2044 : (Ergonomie) Renforcer les "indicateurs d’emplacement" pour les pages de l’espace ...

    15 février 2021, par RastaPopoulos ♥

    Je suis immensément d’accord, et c’est un sujet super importante (la "spacialisation", de "où je suis") pour une refonte complète de l’admin.

    Dans Drupal, c’est comme dans nos objets publics : il y a une hiérarchie principale explicite, quand on ajoute des pages à l’admin. Quasi page d’admin à un parent (ou racine), ce qui permet donc de générer un chemin hiérarchique complet de où on se trouve. Et de mettre en actives les entrées de menus des parents. Perso je trouve ça très bien que toute page de l’admin ait toujours un chemin principal obligatoire (après qu’il y ait des raccourcis pour y accéder de plusieurs manières c’est en plus).

  • RTSP to HLS conversion with error on some devices

    2 septembre 2024, par Wallace Ketler

    I'm trying to convert, on a node server, RTSP IP camera devices to HLS to run livestreams on the web. The following code works well for some RTSP devices, but for others I encounter problems.

    


       function startLive(rtspUrl, outputDir, id_local, id_camera) {
        return new Promise((resolve, reject) => {
            const processKey = `${id_local}_${id_camera}`;
            if (ffmpegProcesses[processKey]) {
                return reject(new Error('Conversão já está em andamento para esta câmera'));
            }
        
            const process = ffmpeg(rtspUrl)
                .inputOptions([
                    '-rtsp_transport', 'tcp',
                    '-fflags', 'nobuffer',
                    '-max_delay', '1000000',
                    '-analyzeduration', '1000000',
                    '-probesize', '1000000',
                    '-flush_packets', '1',
                    '-avioflags', 'direct'
                ])
                .outputOptions([
                    '-c:v', 'libx264',
                    '-preset', 'ultrafast',
                    '-tune', 'zerolatency',
                    '-c:a', 'aac',
                    '-hls_time', '10',
                    '-hls_flags', 'delete_segments',
                    '-hls_list_size', '5',
                    '-hls_wrap', '5',
                    '-strict', '-2'
                ])
                .output(path.join(outputDir, 'stream.m3u8'))
                .on('start', (commandLine) => {
                    console.log('Spawned FFmpeg with command: ' + commandLine);
                })
                .on('stderr', (stderrLine) => {
                    console.log('FFmpeg stderr: ' + stderrLine);
                })
                .on('end', () => {
                    console.log('Conversão concluída');
                    delete ffmpegProcesses[processKey]; 
                    resolve();
                })
                .on('error', (err, stdout, stderr) => {
                    console.error('Erro na conversão', err);
                    console.error('FFmpeg stdout:', stdout);
                    console.error('FFmpeg stderr:', stderr);
                    delete ffmpegProcesses[processKey]; 
                    reject(err);
                })
                .run();
    
            ffmpegProcesses[processKey] = process; 
        });
    }


    


    When the conversion succeeds, it continues indefinitely with the logs :

    


    FFmpeg stderr: frame=   61 fps= 48 q=13.0 size=N/A time=00:00:02.03 bitrate=N/A dup=60 drop=0 speed= 1.6x    
FFmpeg stderr: frame=   75 fps= 42 q=17.0 size=N/A time=00:00:02.52 bitrate=N/A dup=62 drop=0 speed=1.41x    
FFmpeg stderr: frame=   91 fps= 39 q=16.0 size=N/A time=00:00:03.04 bitrate=N/A dup=65 drop=0 speed=1.31x    
FFmpeg stderr: frame=  108 fps= 38 q=15.0 size=N/A time=00:00:03.60 bitrate=N/A dup=68 drop=0 speed=1.27x    
FFmpeg stderr: frame=  121 fps= 36 q=24.0 size=N/A time=00:00:04.03 bitrate=N/A dup=70 drop=0 speed=1.21x    
FFmpeg stderr: frame=  138 fps= 36 q=16.0 size=N/A time=00:00:04.60 bitrate=N/A dup=73 drop=0 speed= 1.2x    
FFmpeg stderr: frame=  152 fps= 35 q=17.0 size=N/A time=00:00:05.08 bitrate=N/A dup=75 drop=0 speed=1.17x    
FFmpeg stderr: frame=  168 fps= 35 q=16.0 size=N/A time=00:00:05.60 bitrate=N/A dup=78 drop=0 speed=1.15x    
FFmpeg stderr: frame=  183 fps= 34 q=21.0 size=N/A time=00:00:06.11 bitrate=N/A dup=80 drop=0 speed=1.13x    
FFmpeg stderr: frame=  198 fps= 34 q=16.0 size=N/A time=00:00:06.60 bitrate=N/A dup=83 drop=0 speed=1.12x    
FFmpeg stderr: frame=  215 fps= 33 q=16.0 size=N/A time=00:00:07.16 bitrate=N/A dup=86 drop=0 speed=1.11x    
FFmpeg stderr: frame=  230 fps= 33 q=16.0 size=N/A time=00:00:07.66 bitrate=N/A dup=88 drop=0 speed= 1.1x    
FFmpeg stderr: frame=  246 fps= 33 q=19.0 size=N/A time=00:00:08.20 bitrate=N/A dup=91 drop=0 speed= 1.1x    


    


    And with the segments saved in the folder configured as output. But for certain devices, after creating the stream.m3u8 file and saving the first segment, the conversion is considered finished and falls into .on('end') . The error log is as follows :

    


    FFmpeg stderr: frame=    0 fps=0.0 q=0.0 size=N/A time=00:00:01.12 bitrate=N/A speed=2.08x    
FFmpeg stderr: [hls @ 0x55e00dfc4380] Opening 'my_path/stream0.ts' for writing
FFmpeg stderr: [hls @ 0x55e00dfc4380] Opening 'my_path/stream.m3u8.tmp' for writing
FFmpeg stderr: frame=    0 fps=0.0 q=0.0 Lsize=N/A time=00:00:01.37 bitrate=N/A speed= 2.5x    
FFmpeg stderr: video:0kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
FFmpeg stderr: [aac @ 0x55e00dfff840] Qavg: 65536.000
FFmpeg stderr: 
Conversão concluída


    


    The muxing overhead: unknown only appears when the error occurs and the conversion is complete.

    


    I've already tried changing the video and audio encoders, as well as the various input and output parameters of the conversion. I also tried updating ffmpeg (it's already on the latest version, using fluent-ffmpeg, "fluent-ffmpeg": "^2.1.3",)

    


    I would like to understand why this happens on some devices and how to fix it. Thanks.