[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-bindings
Subject: Re: [Kde-bindings] Qyoto and QImage constructor (missing method)
From: Arno Rehn <arno () arnorehn ! de>
Date: 2010-07-11 14:55:52
Message-ID: 201007111655.53391.arno () arnorehn ! de
[Download RAW message or body]
On Saturday 10 July 2010 23:39:02 Lorenz Cuno Klopfenstein wrote:
> Hello everybody,
> I've been working with Qyoto for a bit now, using the package that
> ships with Ubuntu 10.04. I've hit a problem when trying to construct a
> QImage instance using a raw data pointer (that I get from GStreamer).
> The code that generates the image is as follows:
>
> byte[] incomingBuffer; //copied in from Gst
> var p = new Pointer<byte>(incomingBuffer);
> var img = new QImage(p, 320, 240, QImage.Format.Format_RGB32);
>
> I'm pretty sure the raw data and the parameters are correct. However,
> the application outputs the following, before crashing:
>
> LEAVE Invoke() ** Missing method ** QImage.QImage(uchar*, int,
> int, QImage::Format)
> Cannot handle 'const QImage&' as argument to QPainter::drawImage
>
> So, I'm assuming the constructor is not called and then, when
> attempting to draw the partially constructed image, the app fails in
> Qt's native code.
This should be fixed now in trunk and the KDE 4.5 branch. Thanks for reporting!
> PS: another weird thing is that the QWidget.WinId() method is missing
> in my Qyoto Dll. I have been able to work around the issue by using
> the following extension method:
>
> public static uint WinId(this QWidget widget){
> var invocation = new SmokeInvocation(typeof(QWidget), widget);
> return (uint)invocation.Invoke("winId", "winId() const",
> typeof(uint)); }
No, this method was left out intentionally, because using it is probably not
cross-platform. If you want to use it, the extenstion-method approach is
probably best.
--
Arno Rehn
arno@arnorehn.de
_______________________________________________
Kde-bindings mailing list
Kde-bindings@kde.org
https://mail.kde.org/mailman/listinfo/kde-bindings
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic