• Welcome to Vampyre Imaging Library Forum. Please login or sign up.
 
19 May 2024, 00:19:45

Recent posts

Pages 1 ... 5 6 7 8 9 10
71
Thanks for the tip, looks pretty nice.
72
One little suggestion:

Your website available on http://imaginglib.sourceforge.net/ indicates that the project has not been continued since 2012.

I would update the date to 2018, otherwise users would think that the project is dead.
73
Bugs And Other Insects / SaveMultiImageToFile ignores G...
Last post by Christian - 31 March 2018, 22:05:36
When loading an animated multiframe GIF with the function LoadMultiImageToFile and save it with SaveMultiImageToFile, the playback speed of the frames set in the original file is ignored. Instead, it is always set a time of 65/100 second.

I am using the newest version of Vampyre Imaging Library, default branch from sourceforge with FPC Lazarus.

Is there any possibility to save or set the delay?
74
I wish to share this find with galfar and the rest here, it's related to processing 16 bit floating point values:

http://www.fox-toolkit.org/ftp/fasthalffloatconversion.pdf

There is already a pascal implementation of this that i have found:
https://github.com/SAmeis/xplib/blob/master/DeHL/Library/src/Math/DeHL.Math.Half.pas

I hope you find it useful, surely a lookup table based solution with no cpu code branching is a big improvement if you process 16 bit floating point values regularly.
75
Bugs And Other Insects / Problem for 64bit
Last post by Phoenix - 17 February 2018, 14:27:48
Hello,

I found a problem using the latest version of lazarus (1.8.0 64bit FPC 3.0.4) in debug mode. On Windows 10 64bit.

In the imjmorecfg.pas file I saw:

Code (delphi) Select
uInt = Cardinal;

This I think is a problem for 64bit systems

For FPC if I replace with
uInt = NativeUInt
I do not perform more dangerous crashes

Also I think there is a similar problem (I have not tested) for:
imzutil.pas

uInt = cardinal; -> NativeUInt
ptr2int = uInt; -> PtrUInt
(but the message "Nomssi" under "ptr2int" is not very clear)

I noticed that through the lazarus compiler, several "warning" and "hint" messages appear.
For "justified Hints" it is possible to disable them (to avoid having to run many already verified messages).

example
Code (delphi) Select
FillChar(TmpInfo, SizeOf(TmpInfo), 0); show variable message not initialized
it is due to the use of "var" but here it is correct then
Code (delphi) Select
FillChar({%H-}TmpInfo, SizeOf(TmpInfo), 0);
avoid the message (it is filtered by lazarus itself)

Finally, the compilation on the ImagingPcx.pas unit is blocked
Code (delphi) Select
ifMono: TImageFormat = TImageFormat (250); ...
I do not know if it's correct.
I know that the SizeOf () dimension of the "enum" types can change depending on the number of elements.
The compiler writes:
ImagingPcx.pas(91,43) Error: range check error while evaluating constants (250 must be between 0 and 206)

(sorry for my English)

Thanks
76
Help & Questions / Re: Convert png with transpare...
Last post by Phoenix - 7 February 2018, 19:42:52
Hello,
Thanks for the reply  :)!
So it is not possible, replace the "transparent color" during the conversion to make the process faster  :(.
77
Bugs And Other Insects / Possible bug in CreateMultiIma...
Last post by Johannes - 7 February 2018, 02:42:04
I have looked into the code of ImagingOpenGL.pas and found something weird:

function CreateMultiImageFromGLTexture(const Texture: GLuint;
  var Images: TDynImageDataArray; MipLevels: LongInt; OverrideFormat: TImageFormat): Boolean;
var
  I, Width, Height, ExistingLevels: LongInt;
begin
  FreeImagesInArray(Images);
  SetLength(Images, 0);
  Result := False;
  if Byte(glIsTexture(Texture)) = GL_TRUE then
  begin
    // Check if desired mipmap level count is valid
    glBindTexture(GL_TEXTURE_2D, Texture);
    if MipLevels <= 0 then
      MipLevels := GetNumMipMapLevels(Width, Height);  //<- Here it tries to access uninitialized memory (Line 849)
    SetLength(Images, MipLevels);


A possible fix would be:
         
    if MipLevels <= 0 then
      begin
        glGetTexLevelParameteriv(GL_TEXTURE_2D, 0, GL_TEXTURE_WIDTH, @Width);
        glGetTexLevelParameteriv(GL_TEXTURE_2D, 0, GL_TEXTURE_HEIGHT, @Height);
        MipLevels := GetNumMipMapLevels(Width, Height);
      end;

78
Bugs And Other Insects / Re: Error: Can't open object f...
Last post by Mac User - 6 February 2018, 14:04:34
If you just add only the library file (lpk) to a blank Lazarus project as it is (without changing any library or unit paths), you get the following error:

ImagingTiff.pas(42,3) Fatal: Cannot find ImagingTiffLib used by ImagingTiff.

I think there is just missing a dependency within the package. But I cannot find where and how to fix it...
79
Suggestions, Feature Requests, Contributions / Re: libtiff 3.9.4 extension fo...
Last post by Mac User - 6 February 2018, 13:38:01
Very good to hear that you are working on a solution.

Yes, I think so, too. Then it is much better to use the solution like Windows than relying on an external library.
80
Help & Questions / Re: Convert png with transpare...
Last post by Galfar - 6 February 2018, 03:10:03
If I understand it correctly, you need to create one image and fill it with your desired background color. Then load your PNG to another image and draw it over the first image with alpha blending. Finally, save the result to a bitmap. 
Pages 1 ... 5 6 7 8 9 10
SMF spam blocked by CleanTalk