[fpc-pascal] Implementing AggPas with PtcGraph

Stefan V. Pantazi svpantazi at gmail.com
Sat Jun 3 22:22:30 CEST 2017

The easiest workaround I could figure was to add a parameter to the 
Agg2D object constructor. That should, in theory, allow the use of any 
pixel format available in AggPas.

The ptcpas/ptcgraph units I used are the ones that came with fpc 3.0.1, 
there was no need to download anything. They worked fine, except for one 
48 bytes memory leak reported by heaptrc and that I left unfixed.


On 06/03/2017 03:37 PM, Graeme Geldenhuys wrote:
> On 2017-06-03 17:45, Stefan V. Pantazi wrote:
>> Also, for the example
>> to work, the agg object constructor must be modified as well, I included
>> all the info in the example header.
> I noted the remarks on the image buffer format being hard-coded for the
> Agg_2D unit. I'll make a plan for improving that, using some Factory
> (design) Pattern to register the pixel buffer format of interest.
>> I think the example program
>> (aggpas_ptcgraph_output.pas) fits well together with the other demos in
>> fpGUI and PtcPas/ptcgraph packages, so adding it to the packages would
>> help, regardless whether graph.PutImage documentation is updated.
> Thanks. I'll download the ptcgraph unit and give it a test. I'll all the
> demo to fpGUI's AggPas demos too. It will be a good addition.
> Regards,
>   Graeme

More information about the fpc-pascal mailing list