[Interest] Qt and OpenCL crash course

Jason H scorp1us at yahoo.com
Thu Mar 13 05:12:36 CET 2014


Using Qt 5.2.1 /  GCC 4.8.1

So I've been working through the code rot, and I was handling (#includes and such) it until I got to here:

class QCLVectorBasePrivate
{
public:
    QCLVectorBasePrivate()
        : state(State_Uninitialized)
        , context(0)
        , id(0)
        , hostCopy(0)
    {
        ref = 1;
    }

    QBasicAtomicInt ref;
...
Gives the error:
qclvector.cpp: In constructor ‘QCLVectorBasePrivate::QCLVectorBasePrivate()’:
qclvector.cpp:94:13: error: no match for ‘operator=’ (operand types are ‘QBasicAtomicInt’ and ‘int’)
         ref = 1;
             ^
qclvector.cpp:94:13: note: candidate is:
In file included from /opt/Qt5.2.1/5.2.1/gcc_64/include/QtCore/qatomic.h:47:0,
                 from /opt/Qt5.2.1/5.2.1/gcc_64/include/QtCore/qglobalstatic.h:47,
                 from /opt/Qt5.2.1/5.2.1/gcc_64/include/QtCore/qglobal.h:1034,
                 from qclglobal.h:45,
                 from qclevent.h:45,
                 from qclmemoryobject.h:45,
                 from qclbuffer.h:45,
                 from qclvector.h:45,
                 from qclvector.cpp:42:
/opt/Qt5.2.1/5.2.1/gcc_64/include/QtCore/qbasicatomic.h:131:7: note: QBasicAtomicInteger<int>& QBasicAtomicInteger<int>::operator=(const QBasicAtomicInteger<int>&)
 class QBasicAtomicInteger
       ^
/opt/Qt5.2.1/5.2.1/gcc_64/include/QtCore/qbasicatomic.h:131:7: note:   no known conversion for argument 1 from ‘int’ to ‘const QBasicAtomicInteger<int>&’


________________________________
 From: Paul Miller <stelefx at gmail.com>
To: interest at qt-project.org 
Sent: Wednesday, March 12, 2014 3:38 PM
Subject: Re: [Interest] Qt and OpenCL crash course
 

On 3/12/2014 2:08 PM, Jason H wrote:

> I need to do some elementary graphics operations on QPixmap or QImage. I
> can do these in Qt to some extent already. But for this latest project I
> will be processing 4k resolution images.
> My operations are:
> Translate off origin
> Rotate by an acute angle (around a point sometimes not in the image)
> Pixel value normailzation
>
> To what extent does Qt support these operations in a hardware
> accelerated manner? Or how hard is it for me to use the hardware to
> produce those functions to inter-operate with Qt?

Take a look at QtOpenCL: http://doc.qt.digia.com/opencl-snapshot/

_______________________________________________
Interest mailing list
Interest at qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20140312/d1914682/attachment.html>


More information about the Interest mailing list