Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Special Interest Groups
  3. QtonPi
  4. QML Image showing solid black rectangle only for bigger image dimensions

QML Image showing solid black rectangle only for bigger image dimensions

Scheduled Pinned Locked Moved QtonPi
2 Posts 1 Posters 1.8k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    ben80
    wrote on last edited by
    #1

    Hi everyone,

    i am using Qt5.3 with raspbian and don't understand a behavior of the QML Image component.

    My Problem:
    I display images for a slideshow in fullscreen (no window).
    Whenever the image dimensions are too big (roughly >2000pixel in one direction), i see a black rectangle instead of the image.
    Is this some kind of limitation with the raspberry pi?
    When i run the same program on my linux desktop it works.

    My Code:
    @ Image{
    id:box1
    width: 800; height: 800
    sourceSize.width: 1920
    sourceSize.height: 1600
    x: 50; y: 50
    source: "pic1.jpg"
    opacity: 1
    fillMode: Image.PreserveAspectFit
    cache: false
    smooth: true
    }@

    When i remove sourceSize or increase the value above 2500 i will get a black rectangle.
    The pic1.jpg is 3456 x 2592 big.

    Why I need that:
    I know, that a sourceSize < 2000 is enough for a screensize of 800. But i plan to show panorama images as well and let them scroll from left to right. So these images will be much bigger than 800 pixel.

    My system:

    • desktop: qt 5.2.1
    • raspberry: qt 5.3.0 (but i am not sure if it's the final or some kind of beta. Is there a way to figure that out?)

    Thanks for all comments,
    Ben

    1 Reply Last reply
    0
    • B Offline
      B Offline
      ben80
      wrote on last edited by
      #2

      Hi, is there nobody who can help with this problem?
      Ben

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved