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

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 GetItemThumbnail

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

View 
UserName:
Password:
Format  Bold Italicized Underline  Align Left Centered Align Right  Horizontal Rule  Insert Hyperlink   Browse for an image to attach to your post Browse for a zip to attach to your post Insert Code  Insert Quote Insert List
   
Message 

 

Emoji
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Black Eye [B)]
Frown [:(] Shocked [:0] Angry [:(!] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
abif Posted - Apr 05 2012 : 18:10:10
Using the MIO.SelectAcquireSource, at "Get Pictures from..." dialog:

How can I get the thumbnails without using a TreeNode? I mean, after I click the thumbnail(s), and then click on the "Get Pictures button"?

For example:
ImageEnView1.IO.WiaParams.GetItemThumbnail( TIEWiaItem(Node.Data), ImageEnView2.IEBitmap );
ImageEnView2.Update;

Is there a way to fill an ImageEnMView1 with all photos off the camera?

Thank you!


3   L A T E S T    R E P L I E S    (Newest First)
xequte Posted - Apr 06 2012 : 17:05:01
Hi

With the DCIM source it will simply assign all images found in the DCIM source to the TImageEnMView.



Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
abif Posted - Apr 06 2012 : 10:16:58
Yes it helped a lot Fabrizio, many thanks!

And if ImageEnMView1.MIO.AcquireParams.SelectedSource.Api = ieaDCIM, there is a way to fill the ImageEnMView1 likewise?
fab Posted - Apr 06 2012 : 00:19:18
Hello,
to fill a TImageEnMView with WIA content you have to loop among all children of WIAParams.Device (that is the root). Example:

var
  i, iidx: integer;
begin
  // prompt user to select a device
  ImageEnMView1.MIO.SelectAcquireSource([ieaWIA]);

  // loop among children of Device (the root item)
  for i:=0 to ImageEnMView1.MIO.WIAParams.Device.Children.Count-1 do
    // process only images
    if witImage in TIEWiaItem(ImageEnMView1.MIO.WIAParams.Device.Children[i]).ItemType then
      with ImageEnMView1.MIO.WIAParams, Device do
      begin
        // add new empty image
        iidx := ImageEnMView1.AppendImage(1, 1);  
        // get thumbnail and store in TImageEnMView bitmap
        GetItemThumbnail(Children[i], ImageEnMView1.GetTIEBitmap(iidx));  
        // close GetTIEBitmap()
        ImageEnMView1.ReleaseBitmap(iidx);  
        // just to associate TImageEnMView item with WIA item
        ImageEnMView1.ImageUserPointer[iidx] := Children[i];  
      end;
end;


Now you can load the full image into a TImageEnView when user select a thumbnail (handling OnImageSelect of TImageEnMView), retrieving the item stored in ImageUserPointer[] property:

procedure TForm1.ImageEnMView1ImageSelect(Sender: TObject; idx: Integer);
begin
  ImageEnView1.IO.WIAParams.ProcessingBitmap := ImageEnView1.IEBitmap;
  ImageEnView1.IO.WIAParams.Transfer( ImageEnMView1.ImageUserPointer[idx] , false);
  ImageEnView1.Update;
end;


Hope this helps.