Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-121458

Canvas Seems Buggy

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P2: Important
    • None
    • 6.6.0
    • Quick: Other
    • None
    • Linux/Wayland, Linux/X11

    Description

      HI , 

        Im trying to use the QtQuick.Canvas 

       

      Canvas{

         id: mCanvas 

          onAvailableChanged:{

              if(available){

                   var context= getContext('2d')

                   context.drawImage(image, 0,0)  //works  here then i want to get the data that has been drawn 

                   var data = context.getImageData(0,0,20,20) // returns   [object object] but when i check or serialize it only returns empty = {} 

       

                   }

          }

      }

       

       

      Canvas{} = works 

      but methods from there seems still buggy 

       

      i tried getImageData, drawImage and putImageData , others are not yet tested 

      drawImage works as expected but when using getImageData returns {} 

      and unable to use putImageData due to CanvasImageData is unknown component , 

       

      as per document CanvasImageData is part of QtQuick 

       

      but Qt did not find it when trying to use it .

      it says unknown component 

       

       

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            jhayar Jhay Tolentino
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes