Recherche avancée

Médias (91)

Autres articles (96)

  • MediaSPIP 0.1 Beta version

    25 avril 2011, par

    MediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
    The zip file provided here only contains the sources of MediaSPIP in its standalone version.
    To get a working installation, you must manually install all-software dependencies on the server.
    If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...)

  • Participer à sa traduction

    10 avril 2011

    Vous pouvez nous aider à améliorer les locutions utilisées dans le logiciel ou à traduire celui-ci dans n’importe qu’elle nouvelle langue permettant sa diffusion à de nouvelles communautés linguistiques.
    Pour ce faire, on utilise l’interface de traduction de SPIP où l’ensemble des modules de langue de MediaSPIP sont à disposition. ll vous suffit de vous inscrire sur la liste de discussion des traducteurs pour demander plus d’informations.
    Actuellement MediaSPIP n’est disponible qu’en français et (...)

  • ANNEXE : Les plugins utilisés spécifiquement pour la ferme

    5 mars 2010, par

    Le site central/maître de la ferme a besoin d’utiliser plusieurs plugins supplémentaires vis à vis des canaux pour son bon fonctionnement. le plugin Gestion de la mutualisation ; le plugin inscription3 pour gérer les inscriptions et les demandes de création d’instance de mutualisation dès l’inscription des utilisateurs ; le plugin verifier qui fournit une API de vérification des champs (utilisé par inscription3) ; le plugin champs extras v2 nécessité par inscription3 (...)

Sur d’autres sites (12281)

  • Image edited and saved in C# can not be read by ffmpeg

    13 juillet 2017, par mmijic

    I have template image (template.jpg) on which I draw some text (13.07.2017.) and than I save it to another location (temp/intro.jpg).

    Than I want to convert that and some other images into video with ffmpeg.

    If I run command

    ffmpeg.exe -f concat -safe 0 -i input.txt -c:v libx264 -vf "fps=25,format=yuv420p" out.mp4

    Those images gets concentrated into one video file. Problem is that this image edited through C# is black in final video.

    If I for example open that C# created image in Adobe Fireworks and just save it (CTRL+S) without changing anything, and re run ffmpeg command everything is fine.

    This is code which I use to add text to template image

    //INTRO IMAGE CREATION
    Bitmap image = new Bitmap(1280, 720);
    image.SetResolution(image.HorizontalResolution, image.VerticalResolution);
    Graphics g = Graphics.FromImage(image);
    g.SmoothingMode = System.Drawing.Drawing2D.SmoothingMode.AntiAlias;
    g.InterpolationMode = System.Drawing.Drawing2D.InterpolationMode.HighQualityBicubic;
    g.PixelOffsetMode = System.Drawing.Drawing2D.PixelOffsetMode.HighQuality;
    g.TextRenderingHint = TextRenderingHint.AntiAliasGridFit;
    StringFormat format = new StringFormat()
    {
       Alignment = StringAlignment.Near,
       LineAlignment = StringAlignment.Near
    };

    //template
    Bitmap back = new Bitmap(Application.StartupPath + @"\Templates\template.jpg");
    g.DrawImage(back, 0, 0, image.Width, image.Height);

    //date
    string Date = dateIntro.Value.ToString("dd.MM.yyyy.");
    var brush = new SolidBrush(Color.FromArgb(255, 206, 33, 39));
    Font font = new Font("Ubuntu", 97, FontStyle.Bold, GraphicsUnit.Pixel);
    float x = 617;
    float y = 530;

    g.DrawString(Date, font, brush, x, y, format);
    g.Flush();
    image.Save(Application.StartupPath + @"\temp\intro.jpg", ImageFormat.Jpeg);
    image.Dispose();

    Image created this way can be opened and viewed in any program except converted to video with ffmpeg.

    Is there anything I’m missing while adding text and saving image in C# ?

  • WriteVideoFrame() with Videocodec.Raw change pixel value

    26 mai 2017, par Alex Gimondi

    I’m using Accord.Video.ffmpeg to record a video in c#. It is actually a depth video with pixels indicating the depth magnitude. From depth array I create a bitmap and the save the bitmap with WriteVideoFrame method.
    Afterward, I open the video in Matlab reading frame by frame. The problem is that I have differences between the bitmap in c# and the frame in Matlab ?! The difference is more or less of 10 (in a range of 255 it’s a big deal)(testing at the moment if it’s constant).
    Since from the bitmap to videoframe I do not perform any operation I think that the problem is in the video encoder. Is is possible even though the format is Raw ?!
    Hints ?
    Alex

    UPDATE

    If I run this code in a new project everything is fine

    unsafe private void Button_Click_1(object sender, RoutedEventArgs e)
       {
           writerdepth.Open("testvideo.avi", 512, 424, 15, VideoCodec.Raw);
           for (int i = 0; i code>

    going back to my code when I try to read the image instead of RGB = [100 100 100] I have [96 94 99].
    My starting code is saving depth image from kinect v2, the function is called when a new valid frame arrives.
    I have no idea of the reason for this difference...

  • matplotlib ArtistAnimation returns a blank video

    28 mars 2017, par Mpaull

    I’m trying to produce an animation of a networkx graph changing over time. I’m using the networkx_draw utilities to create matplotlib figures of the graph, and matplotlib’s ArtistAnimation module to create an animation from the artists networkx produces. I’ve made a minimum reproduction of what I’m doing here :

    import numpy as np
    import networkx as nx
    import matplotlib.animation as animation
    import matplotlib.pyplot as plt

    # Instantiate the graph model
    G = nx.Graph()
    G.add_edge(1, 2)

    # Keep track of highest node ID
    G.maxNode = 2

    fig = plt.figure()
    nx.draw(G)
    ims = []

    for timeStep in xrange(10):

       G.add_edge(G.maxNode,G.maxNode+1)
       G.maxNode += 1

       pos = nx.drawing.spring_layout(G)
       nodes = nx.drawing.draw_networkx_nodes(G, pos)
       lines = nx.drawing.draw_networkx_edges(G, pos)

       ims.append((nodes,lines,))
       plt.pause(.2)
       plt.cla()

    im_ani = animation.ArtistAnimation(fig, ims, interval=200,            repeat_delay=3000,blit=True)
    im_ani.save('im.mp4', metadata={'artist':'Guido'})

    The process works fine while displaying the figures live, it produces exactly the animation I want. And it even produces a looping animation in a figure at the end of the script, again what I want, which would suggest that the animation process worked. However when I open the "im.mp4" file saved to disk, it is a blank white image which runs for the expected period of time, never showing any of the graph images which were showed live.

    I’m using networkx version 1.11, and matplotlib version 2.0. I’m using ffmpeg for the animation, and am running on a Mac, OSX 10.12.3.

    What am I doing incorrectly ?