[QtonPi] Fwd: 3d example using qt

Pierre Chicoine pierrechicoine606 at gmail.com
Thu Feb 28 05:01:00 CET 2013


Samuel

Thanks to you and Daniel I can continue the Power Plant automation program
conversion to the Raspberry PI and have the confidence that it will
work. The hellowindow program worked beautifully, no widgets, just a single
fullscreen Opengl es2 output. I had to change the pro file to look
something like what I will place at the end of this email. I didn't have to
change the example source other that this to make it work.

So to reiterate my success with 3d OpenGL ES2. I ran Daniel's bakeqtpi.bash
script file by following the instructions at:
http://qt-project.org/wiki/RaspberryPi_Beginners_guide. I used Qt Creator
2.7 beta and followed the setup at this URL. I have to copy
/home/pi/opt/rootfs/usr/lib/arm-linux-gnueabi files into my desktop object
build directory on every project that I test. Couldn't figure out why I
couldn't set the library path to find this directory but no matter. It
works now.

Thanks again

Pierre

Here's the pro file for hellowindow: My desktop home directory is pi also
just like the Raspberry /home/pi directory. To clear any confusion.

target.path = /home/pi/hellowindow


QT += gui-private core-private


HEADERS += hellowindow.h

SOURCES += hellowindow.cpp main.cpp


# install

target.path = $$[QT_INSTALL_EXAMPLES]/opengl/hellowindow

INSTALLS += target


 # INCLUDEPATH += "/home/pi/opt/vc/include"

 # INCLUDEPATH +=
"/home/pi/opt/qt-everywhere-opensource-src-5.0.0/qtbase/src/3rdparty/angle/include"

 INCLUDEPATH +=
"/home/pi/opt/gcc-4.7-linaro-rpi-gnueabihf/arm-linux-gnueabihf/libc/usr/include"

 INCLUDEPATH +=
"/home/pi/opt/gcc-4.7-linaro-rpi-gnueabihf/arm-linux-gnueabihf/libc/usr/include/arm-linux-gnueabi"

 LIBS += -L"/home/pi/opt/gcc-4.7-linaro-rpi-gnueabihf/arm-linux-gnueabihf/libc/usr/lib/arm-linux-gnueabi"

 LIBS += -L"/home/pi/opt/gcc-4.7-linaro-rpi-gnueabihf/arm-linux-gnueabihf/lib"

 LIBS += -L"/home/pi/opt/rootfs/usr/lib/arm-linux-gnueabi"

 #release


 DEPLOYMENTFOLDERS = hellowindow


for(deploymentfolder, DEPLOYMENTFOLDERS) {

    item = item$${deploymentfolder}

    itemsources = $${item}.sources

    $$itemsources = $$eval($${deploymentfolder}.source)

    itempath = $${item}.path

    $$itempath= $$eval($${deploymentfolder}.target)

    export($$itemsources)

    export($$itempath)

    DEPLOYMENT += $$item

}


installPrefix = /root/$${TARGET}


for(deploymentfolder, DEPLOYMENTFOLDERS) {

    item = item$${deploymentfolder}

    itemfiles = $${item}.files

    $$itemfiles = $$eval($${deploymentfolder}.source)

    itempath = $${item}.path

    $$itempath = $${installPrefix}/$$eval($${deploymentfolder}.target)

    export($$itemfiles)

    export($$itempath)

    INSTALLS += $$item

}




On Tue, Feb 26, 2013 at 11:37 PM, Samuel Rødal <samuel.rodal at digia.com>wrote:

> On 02/27/2013 03:41 AM, Pierre Chicoine wrote:
>
>> I've tried the hellogl_es2 from qt5 samples and it flashes one 3d frame
>> and then goes black. The slider doesn't work and the menu is hokey.
>>
>> If anyone has a sample that works with 3d using QT5 on the raspberry, it
>> would save me a lot of wasted time chasing a ghost.
>>
>
> Yes, hellogl_es2 tries to create multiple native windows (both raster and
> OpenGL windows) which is not fully supported by eglfs. That's why I
> suggested hellowindow, which uses a single QWindow, at least if you run it
> with "hellowindow --single".
>
>  On Tue, Feb 26, 2013 at 1:45 AM, Samuel Rødal <samuel.rodal at digia.com
>> <mailto:samuel.rodal at digia.com**>> wrote:
>>
>>     On 02/26/2013 06:26 AM, Pierre Chicoine wrote:
>>      > Does anyone have an example showing the use of 3d on the Raspberry
>> PI
>>      > with normal OpenGL ES2 calls? Preferably QT5.
>>
>>     Try the hellowindow example in qtbase/examples/opengl.
>>
>>     --
>>     Samuel
>>
>>     ______________________________**_________________
>>     QtonPi mailing list
>>     QtonPi at qt-project.org <mailto:QtonPi at qt-project.org>
>>     http://lists.qt-project.org/**mailman/listinfo/qtonpi<http://lists.qt-project.org/mailman/listinfo/qtonpi>
>>
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qtonpi/attachments/20130227/f8996740/attachment.html 


More information about the QtonPi mailing list