×

Discussion Board

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

    drawPixel bugs in SDK's for Series_30 (3510i) and 7210

    For fast screen access and low memory usage I had hoped to be able to use DirectGraphics.drawPixels(byte[],...TYPE_BYTE_1_GRAY).

    For my purpose it would have been so much nicer than the standard Java MIDP solution, where I am forced to cache whole Image objects that use e.g. 16 bits per pixel instead of 1.

    The documentation says the following about TYPE_BYTE_1_GRAY (read carefully):

    "The scanlength and offset parameters for drawPixels and getPixels are given in the number of pixels, not as indices to the pixels array.
    All implementations must support this pixel format."

    In the 3410 SDK it works fine, but the Series 30 SDK uses indiecs to the pixel array instead of number of pixels in the offset argument, quite contrary to the documentation. To make it work with the Series 30 SDK I have to divide offset by 8.

    The 7210 SDK does not support TYPE_BYTE_1_GRAY at all, also contrary to the documentation. Instead, it throws IllegalArgumentException for the exact same statements that work with the other SDKs -- and I have made 100% sure that all the other arguments are legal. If I try TYPE_USHORT_444_RGB, which is the native format, it works (but gives funny colors).

    My question is this: Shall I assume that the actual phones work as the SDKs (with the bugs) and spend lots of time trying to work around these problems, or will the phones work according to the documentation?

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

    RE: drawPixel bugs in SDK's for Series_30 (3510i) and 7210

    Hello,
    I can tell you that the 7210 SDK does not support TYPE_BYTE_1_GRAY.
    I see what you mean about "all implementation must support this".
    Therefore, I wonder why it's not working in the 7210. I am requesting some clarification of the documentation from its authors.

    The USHORT 444 is supported and allegedly, the USHORT 4444 format is supported as well. I know this does not help much, but it's a start.
    As to your question if the real phone works vs the SDK...the SDK is made with the phone code. So it should work identical to the phone. This is contrary to a "concept" emulator such as the series 60 MIDP concept SDK.

    One last comment. I can't answer your questions regarding the 3410 and series 60 since they are not developed/tested in this group. They are developed in another country..crazy as it sounds.

    Mike Lupo
    Forum Nokia Developer Tools

Posting Permissions

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