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
 Slippymap/TImEnView save to database
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

sandy771

57 Posts

Posted - Mar 19 2013 :  10:17:54  Show Profile  Reply
I am trying to save a map obrtained from a map server via slippymap to a database. My code is below. My problem is that when I examine the data in the db (sqlite) I find a jpeg, not a bitmap. What am I doing wrong?

Thx.

ies = new TIESlippyMap(iesmpMapQuest, "c:\\mapcache");
TImEn2->IEBitmap->VirtualBitmapProvider = ies;
ies->Latitude = lat;
ies->Longitude = lon;
ies->Zoom = 12;
TImEn2->Update();

exif2->Edit();
picstrm = exif2->CreateBlobStream(exif2->FieldByName("map"), bmWrite);
TImEn2->IO->StreamHeaders = false;
TImEn2->IO->SaveToStreamBMP(picstrm);

fab

1310 Posts

Posted - Mar 27 2013 :  04:13:22  Show Profile  Reply
SaveToStreamBMP does save a BMP, so the problem should be elsewhere.
How do you check the field contains a jpeg?
Go to Top of Page

sandy771

57 Posts

Posted - Mar 27 2013 :  04:18:38  Show Profile  Reply
Thanks for the reply Fabrizio

I manged to sort this last week - but I am away from my office and can't remember how :(
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: