TMUNA - Photo viewer for the Device

derez

Expert
Licensed User
Longtime User
TMUNA is using the new JPEG library by Agraham, so the limitation of size of the picture is removed because the program loads only a thumbnail, not the whole picture.
The operation is simple, the buttons functions from left to right:
- load single picture
- open a directory of pictures, without showing their thumbnails (its faster...)
- open a directory, with thumbnails (this may take a while)
- reset - re-draws the whole picture on the screen
- zoom out - works only after you zoomed in...
- zoom in
- Previous picture (only when a directory is opened and there is a list)
- next picture (only when a directory is opened and there is a list)
- show list (only when a directory is opened and there is a list)
- about

Joystick can be used To Do the previous-Next operations.

The last directory visited is stored for the next time.

The first zoom in step is from the whole picture displayed to the narrow dimension displayed fully on the screen. The step may be large or small - according to the size of the margin.
The following steps are of 1.25 each.

After rotation of 90 degrees, there is a need to increase the size * 1.12, ask Agraham why...(I don't know).

The program is intended for use in the device (not recomended to rotate the desktop screen). I found that there is different behaviour of jpeg.LoadAreaThumbnail on the desktop and on the device - on the desktop it allows to select area outside of the image, on the device it takes only area which is on the image. This is the reason for the complex sub form1_mouseup.

Please note that few libraries are not integrated into the compiled application, so remember to put them with the application. The images directory is required only for the compilation phase.

Many thanks to Erel, Agraham, Filippo and Ariel for the tools used here and for the continuous support !!!

I expect comments and suggestions, please !
David Erez.

Edit: Tmuna1.sbp added , syncronizes the list selected item and changing photo with the arrows.
Also I forgot to write that tapping the mouse moves the point of tapping to the center, or as much as possible without having blank margins.

Edit: version 1.1 , sliding the finger or stylus horizontally or vertically on the screen will change to next or previous picture, like the green arrows or the hardkeys.

edit: Version 1.3 - correction of list items update to show the last selected.
- arrows deleted, since their task is done by stylus movement.
- Addition of imageEdit library with three functions - brightness, contrast and saturation, operated with "E" button on the toolbar.

Edit: Version 1.4 - includes sorting of the photo array by the first letter and if equal - by the last. Also a bug correction.
Edit: Version 1.41 - a slight correction - the "Edit" controls are reset to default when a new photo is displayed.
 

Attachments

  • tmuna1.jpg
    tmuna1.jpg
    50.1 KB · Views: 383
  • tmuna2.jpg
    tmuna2.jpg
    45 KB · Views: 363
  • tmuna3.jpg
    tmuna3.jpg
    38.5 KB · Views: 345
  • Tmuna1.41.zip
    44.2 KB · Views: 371
Last edited:

wm.chatman

Well-Known Member
Licensed User
Longtime User
:) Hello Mr. Derez

I sure will give this a try. Thank you very much for posting the open source.
And you are using the blist.dll library thats a very nice component.

We will let you know how it works. I do find this very usefull.

Best regards, and a Merry Xmas and happy new Year to you!

William
 

wm.chatman

Well-Known Member
Licensed User
Longtime User
at first try at the App on the Desktop, I get two little error msgs. Whats up ?
This happens when I try to open a Jpeg Image.
Compiling for Device then also gives another error. fgcontrols are installed, on the desktop.

What do you think Mr. Derez?
 
Last edited:

klaus

Expert
Licensed User
Longtime User
Hi William,

The program works fine for me on the desktop and also the compiling.
I'm afraid that you don't have all the required libraries in the default library folder of B4PPC or at least the latest versions.
You should make shure to load the latest versions and try again.

Good luck and best regards.
 

wm.chatman

Well-Known Member
Licensed User
Longtime User
:) Hi Klaus

Nice to hear from you Klaus.

yes, you are right! I did not have the newest library Version 1.086 from the fgControls.
Now it does at least work on the desktop, but compiling to device I still get this little error msg.

Congratulations Klaus to your earned contributors Medal. You really disserved that for all the contributions and the help you give others. Respect Sir!

I wish you and your Fam. a very nice Merry Xmas, and a Happy New Year!
Und natuerlich gesundheit.

Best regards

William
 
Last edited:

derez

Expert
Licensed User
Longtime User
William

Please check again that you have the latest and all dll's, check by the attached compilation message.

Also for the device you have to put JPEGator.jpeg.dll in the device , read about it in the jpeg library help.

and btw - it is Chanuka for us jews, not Xmas, but thanks anyway :)
 

agraham

Expert
Licensed User
Longtime User
After rotation of 90 degrees, there is a need to increase the size * 1.12, ask Agraham why...(I don't know).
I don't know why either :confused:. BitmapEx.RotateRight doesn't change the image size, you can see this by checking the BitmapEx Width and Height before and after rotation. I think this is a side-effect of something else.

I found that there is different behaviour of jpeg.LoadAreaThumbnail on the desktop and on the device - on the desktop it allows to select area outside of the image, on the device it takes only area which is on the image. This is the reason for the complex sub form1_mouseup.
I don't think this is to do with LoadAreaThumbnail as that just returns an ordinary bitmap. I think you may have found an Image control or Form control difference between the desktop and device.
 

wm.chatman

Well-Known Member
Licensed User
Longtime User
:) Dir derez

You wrote: Also for the device you have to put JPEGator.jpeg.dll in the device.
Where do I find the JPEGator.jpeg.dll ? That one, I do not have. Never mind, I got it. What do I need to download?
Will also check again that I have the latest and all the dll's needed, up to date.
Thanks much derez.

As for the xmas matter, then a happy Chanuka to you and the Fam.

Best regards
William
 
Last edited:

agraham

Expert
Licensed User
Longtime User

wm.chatman

Well-Known Member
Licensed User
Longtime User
Hi Agraham and Klaus

OK. I Downloaded Jpeg1.1. Thank you for the Info.

Best regards

William
 
Last edited:

derez

Expert
Licensed User
Longtime User
Tmuna1 updated at the first post, syncronizes the list and the photo change by arrows.
 

wm.chatman

Well-Known Member
Licensed User
Longtime User
:) Hi derez

This is very cool. I got it working for the device, using your compiled App for the device. I myself am still unable to compile on the IDE, for device.

I think all the dlls are now up to date, or it would not work on device.

Anymore suggestions.

also error msg. see attached file please (desktop IDE)

Hi Klaus

Best regards

William
 
Last edited:

derez

Expert
Licensed User
Longtime User
I guess it is a missing jpeg library file on the desktop, or not the last version of that file.
 

wm.chatman

Well-Known Member
Licensed User
Longtime User
:) Hi derez

Something had been missing in the Libraries Folder. :( JPEGator.jpeg.dll !
After adding, no problem with the compile option on desktop.

Thanks for posting this code and your Help and Patience.

Best regards

William
 
Last edited:

wm.chatman

Well-Known Member
Licensed User
Longtime User
:) Hi

this is very nice code derez!

but I have a slight problem...

When loading App In IDE all Images except one have different behavior, rest shows a Rotate Angle at 90 degress (10 Images). On the bListControl all Images have correct behavior.
please tell me why?

Best regards

William
 

derez

Expert
Licensed User
Longtime User
The idea is to show the picture with the maximum size - so the application checks if the picture is portrait or landscape, then put it on the screen accordingly. From this moment you can zoom it and move it but not rotate it.

I could include rotation but did not think it is required, and there is no more room on the toolbar.

As I wrote - it is an application for the device, and the device can be easily rotated by hand...

About the jpegator - see post #6 above !
 
Last edited:

derez

Expert
Licensed User
Longtime User
version 1.1 is replacing ver. 1 in the first post :

sliding the finger or stylus horizontally or vertically on the screen will change to next or previous picture, like the green arrows or the hardkeys.
 
Top