×

Discussion Board

Results 1 to 13 of 13

Thread: resize picture

Hybrid View

  1. #1
    Registered User
    Join Date
    Mar 2003
    Posts
    10

    resize picture

    Hi,

    Can I resize a png file at run time?

    For example, I have a png file , 100x100 pixels. After Load,

    I want to change it to 50x50 pixels, but not half-part of the

    picture.

    Anyone know how to do ?

    Thanks.

  2. #2
    Super Contributor
    Join Date
    Mar 2003
    Location
    Israel
    Posts
    2,280

  3. #3
    Registered User
    Join Date
    Mar 2003
    Posts
    10

    Thanks

    shmoove:

    Thanks a lot.

    It is useful for me.

  4. #4
    Registered User
    Join Date
    Jun 2003
    Posts
    12

    is it possible to resize to bigger size?

    for example, from 100x100 resize to 120x120?

  5. #5
    Super Contributor
    Join Date
    Mar 2003
    Location
    Israel
    Posts
    2,280
    Sure, why not.
    The method has one parameter for the original Image(a 100x100 Image in your case), and two ints for the desired width and height(120 in your case).

  6. #6
    Registered User
    Join Date
    Jun 2003
    Posts
    12

    can I use this way to save jar space?

    Greate, it works.
    Then I'm wondering if I can use this way to save jar space, my idea is making image small, for example 10x10, then in the program I can use this resize picture function to enlarge the image to the size I want, for example 30x30. if it's possible, then I can save jar file space. would you please tell me if it's a good idea to do so?thanks a lot.

  7. #7
    Super Contributor
    Join Date
    Mar 2003
    Location
    Israel
    Posts
    2,280
    You can do it but you will have images with lower resolution, so they will not look as good.

  8. #8
    Registered User
    Join Date
    Jun 2003
    Posts
    12

    it means it's not an encouraged way to do so?

    since doing resize picture will lose resolution of the picture?
    then is it possible to resize a picture without losing resolution?
    anyway it's not a problem that i need to resolve in my development, only i'm interested to find out ^o^, thanks a lot.

  9. #9
    Registered User
    Join Date
    Jul 2003
    Posts
    18

    It all comes down to pixels

    When you change your original picture to a smaller size alot of the image data is lost since there are no longer as many pixels to represent the image data, hence the smaller file since.

    It is not generally possible to recover this lost data and therefore when you resize the image to its original size it will never look as good as the original.

    So the anwer would be no, you cannot reduce the size of your .jar file in this way while maintaining the same quality graphics.

  10. #10
    Registered User
    Join Date
    Mar 2003
    Posts
    10

    limit of the program

    Hi, everyone,


    I have test the funciton before. I found the limit of the size is

    176 x 176.

    I have only test it by 7210 simulator.

    Does everyone know how to enlarge it to 500 x 500?

    Thanks.

  11. #11
    Regular Contributor
    Join Date
    Mar 2003
    Location
    Kluang
    Posts
    143
    What about if I have the same 100 px * 100 px and wants to resize to 50 px * 30 px, without distortion of the actual image?

    Cheers,
    YC

  12. #12
    Registered User
    Join Date
    Sep 2006
    Posts
    24

    Re: resize picture

    hi there, the link seen like having error is there other link available! need to resize jpg picture

  13. #13
    Super Contributor
    Join Date
    Dec 2005
    Location
    Europe/Poland/Warsaw
    Posts
    1,697

    Re: resize picture

    hi,
    that's quite old thread where you've looked,
    next time use search feature, its quite common question,
    for example first one from search results I've done againts forum:
    http://discussion.forum.nokia.com/fo...t=image+resize

    regards,
    Peter

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×