[Interest] qml or qwidget

2018-02-21 Thread Sylvain Pointeau
hello, I use heavily opengl (3.2 minimum) for now using cocoa, but I would like switching to Qt to plan for windows. Would you recommend qtquick/qml or qwidget ? best regards, Sylvain ___ Interest mailing list Interest@qt-project.org http://lists.qt-pro

Re: [Interest] Serializing QSensorReading derived classes

2018-02-21 Thread Jérôme Godbout
You only need to known which object you (un)serialized, I had a coworker who made a Xml where the Object value was base64 encoded byte stream for the object value. This is fairly simple to have the following xml tag base64 encoded string from QDataStream goes here or even JSON format could do

[Interest] Qt Remote Objects vs WebSockets?

2018-02-21 Thread Jason H
So the new Qt Remote Objects (5.10, previewed in 5.9) looks cool, but there's not much on it. Can there be a blog post about it? I have many questions: 0. How supported is this? I've not seen anything on it. 1. What's the protocol? (firewall concerns) RPC/WebSocket/Bespoke binary/Google Protobuf

Re: [Interest] Serializing QSensorReading derived classes

2018-02-21 Thread Jason H
Yeah, tha's about what I was guessing. So QObject-derived classes (which the readings are) are not copy constructable.  I thought long and hard about it, and I'm having to implement a ReadingFactory class, which will serialize any reading using non-QObject-derived class[es], then set*() for each p

Re: [Interest] Serializing QSensorReading derived classes

2018-02-21 Thread Jérôme Godbout
you might want to add definition for you own data type: QDataStream &operator<<(QDataStream &out, const MyCustomType &var); QDataStream &operator>>(QDataStream &in, MyCustomType &var); This should be enough to make this work. You probably will have to serialize the mode as int and the x/y/z as q

Re: [Interest] Serializing QSensorReading derived classes

2018-02-21 Thread Jérôme Godbout
The serialization assume you known what type you are reading. If you have a dynamic structure, you will need to add some info about the next data coming (type or something). DataStream convert the object minimal data to byte and no information about what those byte represent. You might have the