Recherche avancée

Médias (91)

Autres articles (112)

  • 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 ;

  • Ecrire une actualité

    21 juin 2013, par

    Présentez les changements dans votre MédiaSPIP ou les actualités de vos projets sur votre MédiaSPIP grâce à la rubrique actualités.
    Dans le thème par défaut spipeo de MédiaSPIP, les actualités sont affichées en bas de la page principale sous les éditoriaux.
    Vous pouvez personnaliser le formulaire de création d’une actualité.
    Formulaire de création d’une actualité Dans le cas d’un document de type actualité, les champs proposés par défaut sont : Date de publication ( personnaliser la date de publication ) (...)

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

Sur d’autres sites (14414)

  • Rotation on Video frame image makes video quality low and becomes green ffmpeg opencv

    21 novembre 2013, par bindal

    I am working on one application in which i have to record video on touch which includes pause recording so , i am using FFmpegFrameRecorder for that

    But when i am recording video with rear camera then in onpreviewframe
    i am getting yuvIplImage in portrait mode that is correct but when i
    am recording with front camera in portrait mode then in onPreviewframe
    i am getting image upside down , so my half, so from that result my
    half video is showing in correct portrait mode and remaining half
    video id showing upside down, so i am applying rotation on yuvIplImage
    when recording from front camera

    Here is my onPreviewFrame Method

    @Override
               public void onPreviewFrame(byte[] data, Camera camera) {

                   long frameTimeStamp = 0L;
                   if (mAudioTimestamp == 0L && firstTime > 0L)
                       frameTimeStamp = 1000L * (System.currentTimeMillis() - firstTime);
                   else if (mLastAudioTimestamp == mAudioTimestamp)
                       frameTimeStamp = mAudioTimestamp + frameTime;
                   else {
                       long l2 = (System.nanoTime() - mAudioTimeRecorded) / 1000L;
                       frameTimeStamp = l2 + mAudioTimestamp;
                       mLastAudioTimestamp = mAudioTimestamp;
                   }
                   synchronized (mVideoRecordLock) {
                       if (recording && rec && lastSavedframe != null
                               && lastSavedframe.getFrameBytesData() != null
                               && yuvIplImage != null) {
                           mVideoTimestamp += frameTime;
                           if (lastSavedframe.getTimeStamp() > mVideoTimestamp)
                               mVideoTimestamp = lastSavedframe.getTimeStamp();
                           try {
                               yuvIplImage.getByteBuffer().put(
                                       lastSavedframe.getFrameBytesData());
                               videoRecorder.setTimestamp(lastSavedframe
                                       .getTimeStamp());

                               // if (defaultCameraId == 1) {
                               // CvSize size = new CvSize(yuvIplImage.height(),
                               // yuvIplImage.width());
                               // IplImage yuvIplImage2 = opencv_core.cvCreateImage(
                               // size, yuvIplImage.depth(),
                               // yuvIplImage.nChannels());
                               //
                               // videoRecorder.record(yuvIplImage2);
                               // } else {

                               // }



                               if (defaultCameraId == 1) {
                                   yuvIplImage = rotate(yuvIplImage, 270);

                                   videoRecorder.record(yuvIplImage);
                               }else
                               {
                                   videoRecorder.record(yuvIplImage);
                               }
                               // else

                               // opencv_core.cvTranspose(yuvIplImage, yuvIplImage);
                           } catch (com.googlecode.javacv.FrameRecorder.Exception e) {
                               e.printStackTrace();
                           }
                       }
                       lastSavedframe = new SavedFrames(data, frameTimeStamp);
                   }
               }
           }

    Here is rotation function

    public static IplImage rotate(IplImage image, double angle) {
       IplImage copy = opencv_core.cvCloneImage(image);

       IplImage rotatedImage = opencv_core.cvCreateImage(
               opencv_core.cvGetSize(copy), copy.depth(), copy.nChannels());
       CvMat mapMatrix = opencv_core.cvCreateMat(2, 3, opencv_core.CV_32FC1);

       // Define Mid Point
       CvPoint2D32f centerPoint = new CvPoint2D32f();
       centerPoint.x(copy.width() / 2);
       centerPoint.y(copy.height() / 2);

       // Get Rotational Matrix
       opencv_imgproc.cv2DRotationMatrix(centerPoint, angle, 1.0, mapMatrix);
       // opencv_core.cvReleaseImage(copy);

       // Rotate the Image
       opencv_imgproc.cvWarpAffine(copy, rotatedImage, mapMatrix,
               opencv_imgproc.CV_INTER_CUBIC
                       + opencv_imgproc.CV_WARP_FILL_OUTLIERS,
               opencv_core.cvScalarAll(170));
       opencv_core.cvReleaseImage(copy);
       opencv_core.cvReleaseMat(mapMatrix);
       return rotatedImage;
    }

    But Final output of video makes half of the video green

    Thanks in advance

  • FFMPEG : burn SRT files to a transparent video file ?

    19 septembre 2017, par Taapo

    I need to create several versions of srt/ssa subtitles for another editor. To minimize the problems that can rise (encoding, etc) I want to provide a separate AVI file that can be overlayed onto another file.

    So I would like to use FFMPEG to burn an "empty" (transparent) video file which has the length of the subtitle file, and with the subtitles burnt in. How would this be done in FFMPEG ?

    Before someone says this is a bad idea (which someone already did), there are use cases where this technique would be helpful. I’m fully aware that this would create big files, but most real-life editors don’t care about size - but about solutions. Judging from other posts (on other forums) there seem to be a need for others as well. And since a professional subtitler like Lemony Subtitler is offering the option, I suppose this is not really a bad idea.

  • http: Add the trailing endlines if they are missing

    23 juillet 2015, par Luca Barbato
    http: Add the trailing endlines if they are missing
    

    Makes slightly easier the life of those want to use the option
    from the command line

    • [DH] libavformat/http.c