Hi there!

I had to write a duplicate of the "image viewer" last week. And I
couldn't find the "Image View" source code. For those wondering why I
didn't use the intents, it's just because my images are dynamically
loaded from the web...

Since I did it for my company, I can't publish the source code. But I
can give you some tips.

First of all, you should read this:

http://groups.google.com/group/android-developers/browse_thread/thread/13fafedb71ccc296/0c0bc0830a20ee82

The whole tip is about using an ImageView with a Matrix. The Matrix
enables you to translate / scale / rotate the image, so basically,
zooming is just a question of scale + translate (to zoom to the
center: when you scale, the fix point is the top left corner, so you
need some translates so that the center is the fix point).

Good luck with that.

Regards,
Piwaï


On Jul 15, 2:06 pm, Desu Vinod Kumar <vinny.s...@gmail.com> wrote:
> HI
>
> u have Source code for ImageViewer app if u have that can u plz attach that
> i am not getting it.
>
> On Wed, Jul 15, 2009 at 5:28 PM, Sujay Krishna Suresh <
>
>
>
> sujay.coold...@gmail.com> wrote:
> > It is very simple, i would recommend u to read the documentation & the try
> > exploring ur self...
> > the zoom controls widget actually displays 2 button like images one for
> > zoom in & 1 for zoom out.
> > it is similar to the one used by maps app... or the image viewer app...
>
> > On Wed, Jul 15, 2009 at 5:22 PM, Desu Vinod Kumar 
> > <vinny.s...@gmail.com>wrote:
>
> >> HI
>
> >> i want to use it by touch events not by key events for Zoomcontrol widget
> >> is it possibe ...
> >> can u tell me where will get the tutorials or examples regarding this?
>
> >> On Wed, Jul 15, 2009 at 5:17 PM, Sujay Krishna Suresh <
> >> sujay.coold...@gmail.com> wrote:
>
> >>> desu,
> >>> plz make use of the zoomcontrols widget available... it will make things
> >>> easier for u...
>
> >>> On Wed, Jul 15, 2009 at 5:12 PM, hanged_man <majd...@gmail.com> wrote:
>
> >>>> Hi Desu, i thought you were trying to implement your own image viewer
> >>>> and implementing your own "Zoom in & out" buttons, therefore i
> >>>> recommended to you to use the default "image viewer" as you can see in
> >>>> my previous post but it turned out that what you're looking for is
> >>>> zoom in and out on touching the image/screen and i dont think is going
> >>>> to be useable or useful for the user, what if the user wished to drag
> >>>> around and view different parts of it ? any touch on the screen would
> >>>> cause a zoom in/out and as i said before he wouldn't be able to move
> >>>> the screen and view different parts of the image.
>
> >>>> On Jul 15, 10:48 am, Desu Vinod Kumar <vinny.s...@gmail.com> wrote:
> >>>> > HI
>
> >>>> > U told that will send the code in a short hours
>
> >>>> > i didn't get the code for zooming .....
>
> >>>> > On Tue, Jul 14, 2009 at 5:09 PM, hanged_man <majd...@gmail.com>
> >>>> wrote:
>
> >>>> > > you can use the default image viewer using intents (you dont have to
> >>>> > > implement your own), i don't remember exactly how it is done but ill
> >>>> > > send you the code in a few hours.
>
> >>>> > > On Jul 14, 8:37 am, Desu Vinod Kumar <vinny.s...@gmail.com> wrote:
> >>>> > > > Hi
>
> >>>> > > > One More thing I need to Specify ....
>
> >>>> > > > I need to zoom in and Zoom out with Touch ... not with key events
> >>>> ....
>
> >>>> > > > On Tue, Jul 14, 2009 at 10:50 AM, android.vinny <
> >>>> vinny.s...@gmail.com
> >>>> > > >wrote:
>
> >>>> > > > > Hi
>
> >>>> > > > > Is Zooming is possible to do in android for Image view .
> >>>> > > > > I have a images in full screen view, i need to zoom in and zoom
> >>>> out
> >>>> > > > > for that images present in image view .....
> >>>> > > > > Can any body give me suggestions regarding this........
>
> >>>> > > > > Thanks in advance.........
>
> >>>> > > > --
> >>>> > > > Regards
> >>>> > > > -------------------
> >>>> > > > Desu Vinod Kumar
> >>>> > > > vinny.s...@gmail.com
> >>>> > > > 09916009493
>
> >>>> > --
> >>>> > Regards
> >>>> > -------------------
> >>>> > Desu Vinod Kumar
> >>>> > vinny.s...@gmail.com
> >>>> > 09176147148
>
> >>> --
> >>> Regards,
> >>> Sujay
> >>> Milton 
> >>> Berle<http://www.brainyquote.com/quotes/authors/m/milton_berle.html> - 
> >>> "If opportunity doesn't knock, build a door."
>
> >> --
> >> Regards
> >> -------------------
> >> Desu Vinod Kumar
> >> vinny.s...@gmail.com
>
> >> 09176147148
>
> > --
> > Regards,
> > Sujay
> > Spike 
> > Milligan<http://www.brainyquote.com/quotes/authors/s/spike_milligan.html> - 
> > "All I ask is the chance to prove that money can't make me happy."
>
> --
> Regards
> -------------------
> Desu Vinod Kumar
> vinny.s...@gmail.com
> 09176147148
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to