Crete SWT image from byte array

Discussion in 'Java' started by kfranic@gmail.com, Apr 22, 2006.

  1. Guest

    Hi all,
    I'm starting with SWT (I like it so far) but I have most stupid
    question that I can't find simple answer to...

    If I want to create AWT Image from byte array I use:
    byte[] buff =...;
    Image img = Toolkit.getDefaultToolkit().createImage(buff);

    How do I do same thing with org.eclipse.swt.graphics.Image?

    I have PNG image within one jar file from which I want to create SWT
    image object.

    I see that there are complex conversions available and this is not the
    approach I'd like to take...

    Regards,
    FrenKy
     
    , Apr 22, 2006
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?RGVhc3Vu?=

    Conversion issue: Image>Byte array>Image

    =?Utf-8?B?RGVhc3Vu?=, Jul 14, 2005, in forum: ASP .Net
    Replies:
    2
    Views:
    914
    =?Utf-8?B?RGVhc3Vu?=
    Jul 14, 2005
  2. Bharat Bhushan

    Appending byte[] to another byte[] array

    Bharat Bhushan, Aug 5, 2003, in forum: Java
    Replies:
    15
    Views:
    40,325
    Roedy Green
    Aug 5, 2003
  3. Kirby
    Replies:
    3
    Views:
    659
    Kirby
    Oct 8, 2004
  4. Replies:
    20
    Views:
    9,855
    licebmi
    Sep 7, 2009
  5. Ramon F Herrera

    Where can I download SWT? (SWT homepage)

    Ramon F Herrera, Dec 5, 2007, in forum: Java
    Replies:
    11
    Views:
    4,080
    Ramon F Herrera
    Dec 6, 2007
Loading...

Share This Page