Recent

Author Topic: Graphics issues on Raspberry Pi  (Read 9513 times)

wp

  • Hero Member
  • *****
  • Posts: 12457
Graphics issues on Raspberry Pi
« on: May 20, 2016, 11:58:27 am »
In http://bugs.freepascal.org/view.php?id=30158 a user reports about issues with TAChart on a Raspberry Pi. Since I don't have this device I asked him to further investigate. It turns out that the graphics unit seems to have several deficiencies on this device/OS (Raspbian OS). As a test vehicle add a TPaintbox to a form and attach this OnPaint handler:

Code: Pascal  [Select][+][-]
  1. procedure TForm1.PaintBox1Paint(Sender: TObject);
  2. begin
  3.   with Paintbox1.Canvas do begin
  4.     Pen.Style := psSolid;
  5.     Pen.Color := clBlue;
  6.     Pen.Width := 3;
  7.     Line(0, 0, Paintbox1.Width, Paintbox1.Height);
  8.     Pen.Width := 1;
  9.     Line(0, Paintbox1.Height, Paintbox1.Width, 0);
  10.   end;
  11. end;
The user only sees the thin line running from bottom-left to top-right. In other experiments he found that Canvas.Pen.Style can only be psSolid,  psPattern and psInsideFrame.

Is anybody else seeing these issues?

Is anybody else using TAChart on a Raspi? Is it running correctly? The user refers to the demo programs which come with Lazarus (they run fine on Windows and Linux Mint (qt/gtk2)).

Thaddy

  • Hero Member
  • *****
  • Posts: 16151
  • Censorship about opinions does not belong here.
Re: Graphics issues on Raspberry Pi
« Reply #1 on: May 20, 2016, 12:44:38 pm »
I only see this when using SSH or Xserver client. Native Raspberry Pi (I have 2 and 3) with a straight connection to a monitor doesn't have this problem. (AFAIK) I am only using the HDMI interface, though.
If someone uses I2C or similar, plz give us some insight?
« Last Edit: May 20, 2016, 12:46:18 pm by Thaddy »
If I smell bad code it usually is bad code and that includes my own code.

 

TinyPortal © 2005-2018