On Fri, Oct 16, 2015 at 3:19 AM, Ryan Joseph wrote:
> Are any of these FPImage classes documented or should I just try to dig
> around the FPC sources to
> find these things? There are dozens of classes available at
> http://wiki.freepascal.org/fcl-image but I
> don’t know what any of them do.
> On Oct 15, 2015, at 4:38 PM, Mattias Gaertner
> wrote:
>
> Actually it works like TFPMemoryImage and descends from
> TFPCustomImage. The only difference is that it uses 4*8=32bit per pixel
> instead of 4*16bit.
Are any of these FPImage classes documented or should I just try to dig around
t
On Thu, 15 Oct 2015 15:30:41 +0700
Ryan Joseph wrote:
>
> > On Oct 14, 2015, at 1:49 PM, Michael Van Canneyt
> > wrote:
> >
> > Type
> > TMyImage = Class(TFPCompactImgRGBA8Bit)
> > Public
> > property Data : PFPCompactImgRGBA8BitValue read FData;
> > end;
> >
> >
> > Should do it. Or if y
> On Oct 14, 2015, at 1:49 PM, Michael Van Canneyt
> wrote:
>
> Type
> TMyImage = Class(TFPCompactImgRGBA8Bit)
> Public
> property Data : PFPCompactImgRGBA8BitValue read FData;
> end;
>
>
> Should do it. Or if you don't need Alpha:
>
> TMyImage = Class(TFPCompactImgRGB8Bit)
> Public
> pro
> On Oct 14, 2015, at 4:59 PM, Graeme Geldenhuys
> wrote:
>
> I assume it should work. I guess there is only one way to found out. ;-)
Yes it did work which is nice.
I didn’t do any speed tests yet but from what I read this unit is faster than
FPImage and it's easier to implement also, being
Hello Ryan,
On 2015-10-14 at 08:54, Ryan Joseph wrote:
> According to Reimar’s code the raw image data is sufficient for
> glTexImage2D so I wonder if the data pointer returned from BeRoPNG
> would work also?
I assume it should work. I guess there is only one way to found out. ;-)
Regards,
Hello Michael,
On 2015-10-14 at 08:49, Michael Van Canneyt wrote:
> You could throw in a property to get a direct pointer to a scanline.
> I should maybe add that to the base classes...
+1
fpGUI's Image class has both ImageData and ScanLine[] properties, and
they are very useful for fast access
On Wed, 14 Oct 2015, Michael Van Canneyt wrote:
On Wed, 14 Oct 2015, Ryan Joseph wrote:
On Oct 12, 2015, at 2:25 PM, Michael Van Canneyt
wrote:
TFPCustomImage is an abstract image class, it provides no storage for the
data. It can have several descendants such as TFPMemoryImage and
On Wed, 14 Oct 2015, Ryan Joseph wrote:
On Oct 12, 2015, at 2:25 PM, Michael Van Canneyt wrote:
TFPCustomImage is an abstract image class, it provides no storage for the data.
It can have several descendants such as TFPMemoryImage and
TFPCompactImgRGBA8Bit.
If you just want the raw data,
On Wed, 14 Oct 2015, Ryan Joseph wrote:
On Oct 12, 2015, at 8:39 PM, Reimar Grabowski wrote:
http://sourceforge.net/p/asmoday/code/HEAD/tree/trunk/asmtypes.pas#l203
Not an example but a straightforward texture class implementation based on
TFPCustomImage. Should work as is for bmp, jpg,
> On Oct 12, 2015, at 8:39 PM, Reimar Grabowski wrote:
>
> http://sourceforge.net/p/asmoday/code/HEAD/tree/trunk/asmtypes.pas#l203
>
> Not an example but a straightforward texture class implementation based on
> TFPCustomImage. Should work as is for bmp, jpg, png, tga, xpm, if not drop me
> a
> On Oct 12, 2015, at 2:25 PM, Michael Van Canneyt
> wrote:
>
> TFPCustomImage is an abstract image class, it provides no storage for the
> data. It can have several descendants such as TFPMemoryImage and
> TFPCompactImgRGBA8Bit.
> If you just want the raw data, create a TFPMemoryImage and ac
> On Oct 12, 2015, at 5:52 PM, Graeme Geldenhuys
> wrote:
>
> http://members.upc.nl/h.speksnijder4/software/fpGUI/pngloader.html
Thanks for the links. BeRoPNG seems to load a PNG and the author states it’s
fast and has no external dependancies. Fantastic.
According to Reimar’s code the raw
On Sun, 11 Oct 2015 16:36:56 +0700
Ryan Joseph wrote:
> is there any more complete examples I could look at?
http://sourceforge.net/p/asmoday/code/HEAD/tree/trunk/asmtypes.pas#l203
Not an example but a straightforward texture class implementation based on
TFPCustomImage. Should work as is for
On 2015-10-12 08:26, Anthony Walter wrote:
> The OS imaging libs are orders of magnitudes faster than TFPImage,
> especially when it comes to loading 100s of textures during the start
> of a demo or game.
Indeed, FPImage is not very fast... This was also extensively proven and
compared against man
On 2015-10-12 01:21, Ryan Joseph wrote:
> But can I then access the pixel data so I can hand it to glTexImage2D and
> make the texture?
Yes, look at line 61. Simply use the Colors[] array property.
The code I suggested was not meant as a complete implementation for you,
but as an example of how
On Mon, 12 Oct 2015, Anthony Walter wrote:
Michael,
I've written a whole lot of OpenGL demos (demoscene) using both C and
Pascal. I can tell you there is a huge difference between the Delphi image
decompression performance and the performance of the image libs ones
provided by the OS (WIC and
Michael,
I've written a whole lot of OpenGL demos (demoscene) using both C and
Pascal. I can tell you there is a huge difference between the Delphi image
decompression performance and the performance of the image libs ones
provided by the OS (WIC and Quartz especially). The OS imaging libs are
ord
On Sun, 11 Oct 2015, Ryan Joseph wrote:
On Oct 11, 2015, at 1:53 PM, Michael Van Canneyt wrote:
You can use the fpimage and fpreadpng units. Check the packages/fcl-image
sources. There is a small demo program that shows how to do it.
I see you can load an image as TFPCustomImage with TF
Michae
___
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
I would abstract all platform specific code. I define a encapsulating set
of interfaces for any platform specific stuff. Interface types also provide
a nice layer of abstraction.
In such a way I have at least IDocument, IBitmap, IAudio, and IVideo; where
the last three type define methods for load
On Sun, 11 Oct 2015, Anthony Walter wrote:
I tend to use OS core elements or well known open source libraries for a
few reasons.
1) less code compiled and small programs
2) superior performance
3) more features
1. is not true for image code if you're using lazarus. The code will already be
> On Oct 12, 2015, at 10:57 AM, Anthony Walter wrote:
>
> I tend to use OS core elements or well known open source libraries for a few
> reasons.
>
> 1) less code compiled and small programs
> 2) superior performance
> 3) more features
>
> Example: When loading hundreds of textures you bet th
I tend to use OS core elements or well known open source libraries for a
few reasons.
1) less code compiled and small programs
2) superior performance
3) more features
Example: When loading hundreds of textures you bet the Apple Quartz
graphics libs are faster and more reliable. Same goes to WIC
> On Oct 12, 2015, at 9:47 AM, Anthony Walter wrote:
>
> Okay, I looked at my Darwin sources which use minimal wrappers around the
> inbuilt Quartz classes to handle image loading, saving, and pixel data access.
>
I have a good working implementation of loading OpenGL textures on Mac but I
Okay, I looked at my Darwin sources which use minimal wrappers around the
inbuilt Quartz classes to handle image loading, saving, and pixel data
access.
To load any image (png, jpg, bmp, gif, ect) you use a CGImageSourceRef
object.
>From file:
ImageSource :=
CGImageSourceCreateWithURL(UrlRefCrea
> On Oct 12, 2015, at 3:46 AM, Anthony Walter wrote:
>
> You can write an interface to the quartz libs and have them load or save a
> variety of image formats such as bmp, jpg, gif, and png. I've done this with
> OpenGL on OSX with Free Pascal and I look for the code and post it to git
> some
> On Oct 11, 2015, at 10:45 PM, Graeme Geldenhuys
> wrote:
>
> As Michael mentioned, fpimage and fpreadpng can do this. Here is how I
> use it to populate fpGUI's TfpgImage class with image data.
>
> https://github.com/graemeg/fpGUI/blob/develop/src/corelib/fpg_imgfmt_png.pas
But can I then a
You can write an interface to the quartz libs and have them load or save a
variety of image formats such as bmp, jpg, gif, and png. I've done this
with OpenGL on OSX with Free Pascal and I look for the code and post it to
git sometime, maybe even Today.
http://codebot.org/baregame/
___
On 2015-10-11 05:29, Ryan Joseph wrote:
> Does the FPC RTL contain any units for loading PNG files as bitmaps
As Michael mentioned, fpimage and fpreadpng can do this. Here is how I
use it to populate fpGUI's TfpgImage class with image data.
https://github.com/graemeg/fpGUI/blob/develop/src/coreli
> On Oct 11, 2015, at 1:53 PM, Michael Van Canneyt
> wrote:
>
> You can use the fpimage and fpreadpng units. Check the packages/fcl-image
> sources. There is a small demo program that shows how to do it.
I see you can load an image as TFPCustomImage with TFPCustomImageReader then
there is a
On Sun, 11 Oct 2015, Ryan Joseph wrote:
I’m coming from the Mac and I’d like to replace some code that loads .png files
into OpenGL textures using Apple libraries that aren’t cross platform
compatible.
Does the FPC RTL contain any units for loading PNG files as bitmaps that I
could extract
32 matches
Mail list logo