×

Discussion Board

Results 1 to 4 of 4
  1. #1
    Registered User
    Join Date
    Mar 2003
    Posts
    1

    Display's aspect ratio

    I have made a simple java MIDlet, to draw an analog clock. The clock appeared circular in the 6310i emulator (PC VGA screen is aspect ratio 1:1) but appeared oval in the actual 6310i device. Is there any "official" way to retrieve aspect ratio, so as not to hard-code it inside my software?

  2. #2
    Regular Contributor
    Join Date
    Mar 2003
    Posts
    71

    RE: Display's aspect ratio

    no, the aspect ratio is not retreivable in j2me. (though either basic midp, or nokias extensions)

    you would do best assuming the ratio is 1:1 - and live with the distorted shape.

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

    RE: Display's aspect ratio

    I tried to do the same thing and of course got the same result. After some measuring with a ruler I found out that my circle was exactly 10.0 mm high and 8.5 mm wide.

    If you want it to be 10.0 mm wide you have to:

    8.5 * x = 10

    10
    x = --
    8.5

    x = 1.17647... (which is the value you shall multiplay x with)

    Maybe I was a little bit too educational now =)

    /Bjarne

  4. #4
    Registered User
    Join Date
    Mar 2003
    Posts
    39

    RE: Display's aspect ratio

    oops. that didn't look too good but i think you understand =)

    ..and of course that value is what you should multiply your arc width with, x was not a very good choice of variable name!

Posting Permissions

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