ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 assign from ImageEnView not working - gray image after assign
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

Fabgon

Brazil
2 Posts

Posted - Aug 17 2021 :  12:37:49  Show Profile  Reply
Hi ,

this is my first post. I'm trying to load content from timage to ImageEnview v8.6 (yes a old version i know ) but cannot work.

The code bellow is used to load a file to timage ( only for test )


   JPG := TJPegImage.Create;
    try
      JPG.CompressionQuality := 100;
      JPG.Loadfromfile(extractfilepath(Application.exename)+'f.jpg');
      image1.Picture.Assign( JPG );

    finally
      FreeAndNil(JPG);
    end;


What i have tried , :



   // Test 1
   try  
     ...
     ImageEnView1.IEBitmap.Assign( jpg);
    finally
      FreeAndNil(JPG);
    end;

   // Test 2
   try
    bmp:=TBitmap.Create;
    bmp.Assign(imgPlotAna.Picture.Bitmap);
    ImageEnView1.IEBitmap.Assign(bmp);
    bmp.Free;
 
    // Test 3  - Using assign directly from TJPeG
    ImageEnView1.Assign(JPG);  

    // Test 4  - Assign from timage.bitmap to ImageEnview.bitmap
    ImageEnView1.Bitmap.Assign(image1.Picture.Bitmap);



The ImageEnView cannot load the image in all tests. What i'm doing wrong?

xequte

38222 Posts

Posted - Aug 18 2021 :  05:47:11  Show Profile  Reply
Hi

Either of the following should work:

ImageEnView1.IEBitmap.Assign( image1.Picture );
ImageEnView1.Update();

ImageEnView1.Assign( image1 );


Nigel
Xequte Software
www.imageen.com
Go to Top of Page

Fabgon

Brazil
2 Posts

Posted - Aug 19 2021 :  14:44:38  Show Profile  Reply
Thank you Nigel !

Works like a charm.

Fabricius
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: