#27 Where is the One-Pixel-Size-Point?


Hi PlPlot Programmers,

I really like your PLPLot, but I cant find the function to do draw a point with the size of maximal one pixel of the Display.

PlPoin with code=1 draws only 4 Pixels with one pixel-hole.

I want to draw a Logistic map, isn't this possible with PLPlot?

Thanks for Your efforts
Stefan Menzel


  • Stefan Menzel

    Stefan Menzel - 2008-05-22

    Logged In: YES
    Originator: YES

    Like in PGPlot with code -1 :

    PGPT -- draw several graph markers

    void cpgpt(int n, const float *xpts, const float *ypts, int symbol);

    REAL XPTS(*), YPTS(*)

    Primitive routine to draw Graph Markers (polymarker). The markers
    are drawn using the current values of attributes color-index,
    line-width, and character-height (character-font applies if the symbol
    number is >31). If the point to be marked lies outside the window,
    no marker is drawn. The "pen position" is changed to
    (XPTS(N),YPTS(N)) in world coordinates (if N > 0).

    N (input) : number of points to mark.
    XPTS (input) : world x-coordinates of the points.
    YPTS (input) : world y-coordinates of the points.
    SYMBOL (input) : code number of the symbol to be drawn at each
    -1, -2 : a single dot (diameter = current
    line width).
    -3..-31 : a regular polygon with ABS(SYMBOL)
    edges (style set by current fill style).
    0..31 : standard marker symbols.
    32..127 : ASCII characters (in current font).
    e.g. to use letter F as a marker, let
    SYMBOL = ICHAR('F').
    > 127 : a Hershey symbol number.

    Note: the dimension of arrays X and Y must be greater than or equal
    to N. If N is 1, X and Y may be scalars (constants or variables). If
    N is less than 1, nothing is drawn.

  • Werner Smekal

    Werner Smekal - 2008-05-22

    Logged In: YES
    Originator: NO

    Hi Stefan,

    how this the symbol with the code #1 is drawn to the screen or to a file depends on the driver used and which font this driver uses. If you look at the example 6 http://plplot.sourceforge.net/examples/demo06.php I think that this is a point. This is the pngcairo device I think. Depending on what you need (screen plots, png plots) you could try the different devices (xwin, xcairo, wxwidgets) and also try to turn freetype library on and off with the -drvopt text=0|1 option. Alternativ you could try to draw a line from (x,y) to (x,y) I think you will get a point then for most drivers.


  • Stefan Menzel

    Stefan Menzel - 2008-05-26

    Logged In: YES
    Originator: YES

    Hi Werner,

    thanks for fast reply, which helped locating the problem:

    I use WinXP (please continue reading... :-)), VC-2008EE and the WinGCC-Driver.
    I tried png (GD-Driver) and code=-1 and voila there's my One-Pixel-Point.
    I installed freetype and tried WinGCC with "-drvopt text" option but also no success, it draws nothing for code=-1.
    I tried hard to install wxwidget but this is impossible with the latest software versions (I will submit a bug, in the bug section).
    So I think the WinGCC-Driver has a bug.
    As additional information, I have problems with correct visualisation in examples No. 23,24, even with activated Freetype and not using WinGCC-Driver.


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks