![]() |
|
|||||||
| Home | Register | FAQ | Members List | Search | Today's Posts | Mark Forums Read |
| Additional Libraries Users contributed libraries. This sub-forum is only available to licensed users. |
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
I like your attitude to problems.
I thought that if the user is in a hurry - he can display the map shrinked in the going direction and thus arrive earlier... ![]()
__________________
David Erez Ramat Hasharon, Israel |
|
|||
|
Dimitris
I succeeded also in getting the size of the map by adding it to an ImageList, like you said ![]() Thanks again. your next challenge is to make the rotation for an arbitrary angle... ![]()
__________________
David Erez Ramat Hasharon, Israel Last edited by derez : 12-26-2007 at 06:01 PM. |
|
||||
|
Hi,
The third version of dzImage is here. Corrected the problem pointed by Klaus (thank you) regarding Capture2 and ControlCapture when Width < 100 Added some new methods. ImageToByteArray(Image): Returns an array of bytes which contains the whole Image. ByteArrayToImage(byte()): Converts the valid (must be) byte() to an Image. GetPixel(X, Y): Returns a Dim Type(Alpha, Red, Green, Blue) with the attributes of the internal stored image's piointed pixel. SetPixel(X, Y, Alpha, Red, Green, Blue): Set the pixel in postion X,Y of the internal stored image to Alpha, Red, Green, Blue. And a modification. RotateImage(Image, angle) can now accept any angle (be careful of the image size, because angles different from 90, 180, 270 makes this method acting slowly) In the attached sip is included a sample showing the new additions. EDIT: Next Year I'll try to make GetPixel and SetPixel much faster (RotateImage too as it is based on them)Last edited by dzt : 12-27-2007 at 11:19 PM. |
|
|||
|
Thanks for the effort, but I found it unusable for my program because it is doing the rotation but it takes a lot of time (as expected).
The problem is that I understand the difficulties but I also have an application that does it in real time and I don't know how the creator of that application did it ![]()
__________________
David Erez Ramat Hasharon, Israel |
|
|||
|
Also due to different distance between pixels in x and y, when rotated the result image is distoted in angles. see the example , where I took just part of the whole form and rotated it.
__________________
David Erez Ramat Hasharon, Israel |
|
||||
|
Hi,
Attached is the forth version of dzImage. Added: FastGetPixel, FastSetPixel, FastRotateImage For how to use them see the included in the zip sample. Next Update (if there will be) at 2008 for shure. Quote:
Quote:
|
|
||||
|
Hi David,
As far as I am aware, commercial GPS maps are vector graphics that can be stretched virtually indefinitely. Rotation angles on bitmaps other than quarters need adjustment, especially for text. A true challenge, indeed. Haisai Dimitris, Congrats! Your latest 'magic' adds further, indispensable value to Basic4ppc. I have already constructed a viewer application for sky photos including a magnifying glass on selected coordinates. Of course, it also flips and flops, rotates, zooms in and out. Reminds me on those days with VB3.0 and BitBlt. Works lovely and I have encountered just three minor findings (errors inherent to human programmer can not be excluded): 1. Rotation Angle 0 blacks out the screen or image control. 2. While running fine in the IDE, the exe sometimes prompts "Invalid Pixel Format" error upon InvertImage. 3. Also upon Invert, the desktop shows correct, while the device does not invert (perhaps I am seeing things the wrong way round). I have a master image in an Image Control (mode = cNormalImage) and draw a manipulated image on a form using DrawImage or to another Image Control. All can be worked around fairly easily. Since 2007 is fading into history, let's preserve this issue for 2008 ![]() Thanks so much for this wonderful year-end present! Cheers Robert |
|
||||
|
Quote:
![]() You can load an Icon using LoadPicture of various controls (Image, Form etc.) To save an Icon you need deep knowledge of the ico format. Take a look at this thread Icon Editor - COMPETITION TIME dzImage.ImageToByteArray might can help. The first 54 bytes are BITMAPINFOHEADER (40 bytes) and BITMAPFILEHEADER (14 bytes. Next bytes represents the actual image. Take a look here http://www.fortunecity.com/skyscrape.../bmpffrmt.html and here http://www.cs.uvm.edu/~erickson/educ...b_bmp/BMP.html |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Door library (Beta) - Special library | Erel | Official Updates | 48 | 07-18-2008 02:33 PM |
| Merging Outlook library and Phone library | Erel | Official Updates | 2 | 07-14-2008 03:38 PM |