Results 1 to 6 of 6

Thread: Filling QPixmap from an unsigned short array? QPixmap size limitations?

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Dec 2006
    Posts
    160
    Thanks
    33
    Thanked 1 Time in 1 Post
    Qt products
    Qt3 Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Filling QPixmap from an unsigned short array? QPixmap size limitations?

    Hello,

    My questions are fast and simple ^^

    1a) Is there any way to fill a QPixmap from 3 unsigned shorts arrays (Each pixel has 16 bits per channel)? Of course i'm not talking of iterating on each pixel with a QPainter, doing a setPen with my 3 channels colors, and then a drawPoint on the QPixmap, since it's way too slow...

    1b) Each of my channel can have a value between 0 and 65535 (16 bits). So i'm talking about a very "fast conversion copy", changing from 16 bits in original to 8 in the QPixmap.

    1c) If the answer is clearly no, does the same question but with shorts instead of unsigned shorts have another answer? ^^

    Telling me to "change to 8 bits per channel because the human eye only perceive N colors" is not an answer for me, since it's not related to human eye but to medical images processment... 16 bits per channel i have no choice ^^

    2) Also, i have read somewhere that a QPixmap is limited in size to 2000x2000 pixels... Is it true? If yes, is there a workaround for this, knowing i'm using the QPixmap in a QGraphicsView linked to a QGraphicsScene?

    Thanks for your answers.
    Pierre.
    Last edited by hickscorp; 8th April 2007 at 23:48.

Similar Threads

  1. failing to achieve desired size of a BitField structure
    By nass in forum General Programming
    Replies: 8
    Last Post: 13th February 2007, 13:29
  2. unable to save QCStrings properly in a buffer
    By nass in forum Qt Programming
    Replies: 13
    Last Post: 15th November 2006, 20:49
  3. Tiff in unsigned short
    By spawnwj in forum Qt Programming
    Replies: 14
    Last Post: 26th July 2006, 07:41
  4. How to create QPixmap from unsigned character array?
    By rashidbutt in forum Qt Programming
    Replies: 4
    Last Post: 16th May 2006, 18:25

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.