Search found 15 matches

by stolarz
Thu Feb 12, 2009 7:27 pm
Forum: GFL SDK
Topic: GFLSDK 2.90 gflCBitmap.h wish
Replies: 1
Views: 1103

GFLSDK 2.90 gflCBitmap.h wish

so there will be at least a public method in gflCBitmap.h that returns m_gflBitmap (a private field) so I can invoke other functions from libgflE that require a GFL_BITMAP*
by stolarz
Thu Dec 25, 2008 8:49 pm
Forum: GFL SDK
Topic: GFLSDK 2.90 gflCBitmap.cpp bug
Replies: 0
Views: 1065

GFLSDK 2.90 gflCBitmap.cpp bug

there is a minor bug in file gflCBitmap.cpp,
method GFLC_BITMAP::create(const GFLC_BITMAP & bitmap),
there is return create(bitmap.getType(), bitmap.getBitsPerComponent(), bitmap.getWidth(), bitmap.getHeight(), bitmap.getBitsPerComponent()) ,
should be return create(bitmap.getType(), bitmap.getWidth ...
by stolarz
Tue May 13, 2008 12:13 pm
Forum: GFL SDK
Topic: Minor Bug, GFL SDK 2.82 for Delphi
Replies: 2
Views: 1701

or:

Code: Select all

function gflAllockBitmap(BType: GFL_BITMAP_TYPE;
  width, height, line_padding: GFL_INT32;
  var color: TGFL_COLOR): PGFL_BITMAP; stdcall;
by stolarz
Tue May 13, 2008 12:11 pm
Forum: GFL SDK
Topic: Minor Bug, GFL SDK 2.82 for Delphi
Replies: 2
Views: 1701

Minor Bug, GFL SDK 2.82 for Delphi

is:

Code: Select all

function gflAllockBitmap(BType: GFL_BITMAP_TYPE;
  width, height, line_padding: GFL_INT32;
  var color: PGFL_COLOR): PGFL_BITMAP; stdcall;
should be:

Code: Select all

function gflAllockBitmap(BType: GFL_BITMAP_TYPE;
  width, height, line_padding: GFL_INT32;
  color: PGFL_COLOR): PGFL_BITMAP; stdcall;
by stolarz
Sun Jun 17, 2007 10:35 am
Forum: GFL SDK
Topic: problems using colormap with gflC
Replies: 2
Views: 1825

post scriptum: is there any way to use color index when putting pixels on bitmap? i mean sth like gflSetColorAt(bmp, 0, 0, 5) where 5 is the 6th color in the palette (0 is origin)
by stolarz
Sun Jun 17, 2007 9:49 am
Forum: GFL SDK
Topic: problems using colormap with gflC
Replies: 2
Views: 1825

problems using colormap with gflC

hi :)
i'm trying to create a 256-color bitmap. when i do it with libgfl functions everything is fine, the code:

GFL_BITMAP *b2 = gflAllockBitmap(GFL_COLORS, wh+2*margin, wh+2*margin, 4, NULL);
GFL_COLORMAP cm2;
cm2.Red[0]=0; cm2.Green[0]=0; cm2.Blue[0]=0;
cm2.Red[1]=255; cm2.Green[1]=255; cm2 ...
by stolarz
Wed Mar 28, 2007 7:36 pm
Forum: GFL SDK
Topic: no Floyd-Steinberg for 256 colours?
Replies: 1
Views: 1860

...

oops, sorry, there is one in gflsdk, i was referring to nconvert...
by stolarz
Wed Mar 28, 2007 7:33 pm
Forum: GFL SDK
Topic: no Floyd-Steinberg for 256 colours?
Replies: 1
Views: 1860

no Floyd-Steinberg for 256 colours?

if i'm not wrong there is no possibility to apply Floyd-Steinberg error dispersion algorithm when changing color depth to 256 colors. and i think it works somehow analogous to the 256 greys version...
by stolarz
Wed Mar 28, 2007 7:30 pm
Forum: GFL SDK
Topic: bug in gflSaveBitmapIntoMemory() (tiff only?)
Replies: 7
Views: 3479

Re: bug in gflSaveBitmapIntoMemory() (tiff only?)

I've tried but have no crash...
Yes, but the sizes in mem and disk differ and it's just a matter of luck if there is a crash or not because of different memory allocating algorithms: your first malloc in a program actually allocates smallest allocable block, like f.e. 0x1000 bytes, so char* a ...
by stolarz
Tue Mar 27, 2007 5:47 pm
Forum: GFL SDK
Topic: bug in gflSaveBitmapIntoMemory() (tiff only?)
Replies: 7
Views: 3479

Re: bug in gflSaveBitmapIntoMemory() (tiff only?)

Could you send me your test program?
emm.... d'you mean the source? or the executable?
here's the source:

#include <stdio>
#include "libgfl.h"

void main() {
printf("hello\n");
GFL_ERROR init = gflLibraryInit();
if (GFL_NO_ERROR != init) {
printf("error: %d\n", init);
return;
}
printf ...
by stolarz
Mon Mar 26, 2007 9:42 am
Forum: GFL SDK
Topic: bug in gflSaveBitmapIntoMemory() (tiff only?)
Replies: 7
Views: 3479

what if...

yeah, and what if length is less than the size of allocated memory? gflRealloc will crop my data :|
by stolarz
Sat Mar 24, 2007 5:48 pm
Forum: GFL SDK
Topic: bug in gflSaveBitmapIntoMemory() (tiff only?)
Replies: 7
Views: 3479

bug in gflSaveBitmapIntoMemory() (tiff only?)


unsigned char* data;
unsigned long length;
gflSaveBitmapIntoMemory(&data, &length, ...

I don't know if it's only for tiff but with tiff and lzw 'length' is bigger than the actual allocated block of memory. therefore
unsigned char * new_block = malloc(length);
for (int i=0; i<length; i++) new ...
by stolarz
Wed Mar 14, 2007 10:53 pm
Forum: GFL SDK
Topic: gfl + jpeg2000 + changing quality
Replies: 4
Views: 2813

lossless

btw, is there any lossless compression in gfl? like lossless jpeg? i see there is GFL_LZW for tiff. any other?
by stolarz
Wed Mar 14, 2007 8:37 pm
Forum: GFL SDK
Topic: gfl + jpeg2000 + changing quality
Replies: 4
Views: 2813

:(

:( you are right... i tested it once again, the results differ. it is 1288438 bytes for quality 95 and 99025 bytes for quality 5. i haven't noticed that fact before cause i was using gflSaveBitmapIntoMemory. But what worries me most is why i thought Quality parameter doesn't change anything - i was ...
by stolarz
Sun Mar 11, 2007 10:09 am
Forum: GFL SDK
Topic: gfl + jpeg2000 + changing quality
Replies: 4
Views: 2813

gfl + jpeg2000 + changing quality

hi people, i'm using the jpeg 2000 plugin with the gfl library and i don't know how to change the quality when compressing to this format. i'm using gflSaveBitmapIntoMemory() and filling GFL_SAVE_PARAMS structure. been trying to modify the Quality member but it seems that it works for regular jpegs ...