summaryrefslogtreecommitdiffstats
path: root/examples/opengl
diff options
context:
space:
mode:
authorPaul Olav Tvete <paul.tvete@nokia.com>2011-05-24 15:22:06 +0200
committerPaul Olav Tvete <paul.tvete@nokia.com>2011-05-24 15:22:06 +0200
commit43b9a99983e19302d47c938c1cf936c80b8cb337 (patch)
tree7a3703a418438f8fdd2b743cf91d4d4279683a91 /examples/opengl
parent82895982ec31b2c889393e7f386c25d668df6c5e (diff)
parentf9f395c28b8ce66c0605607ea76ad1099d45a6c9 (diff)
Merge remote branch 'staging/master' into refactor
Conflicts: examples/animation/animatedtiles/animatedtiles.pro examples/animation/appchooser/appchooser.pro examples/animation/easing/easing.pro examples/animation/easing/window.h examples/animation/moveblocks/moveblocks.pro examples/animation/states/states.pro examples/animation/stickman/stickman.pro examples/dbus/dbus-chat/dbus-chat.pro examples/dbus/dbus.pro examples/dbus/remotecontrolledcar/car/car.pro examples/dbus/remotecontrolledcar/controller/controller.pro examples/dbus/remotecontrolledcar/remotecontrolledcar.pro examples/desktop/desktop.pro examples/desktop/screenshot/screenshot.pro examples/dialogs/classwizard/classwizard.pro examples/dialogs/configdialog/configdialog.pro examples/dialogs/dialogs.pro examples/dialogs/extension/extension.pro examples/dialogs/findfiles/findfiles.pro examples/dialogs/licensewizard/licensewizard.pro examples/dialogs/sipdialog/sipdialog.pro examples/dialogs/standarddialogs/standarddialogs.pro examples/dialogs/tabdialog/tabdialog.pro examples/dialogs/trivialwizard/trivialwizard.pro examples/draganddrop/draggableicons/draggableicons.pro examples/draganddrop/draggabletext/draggabletext.pro examples/draganddrop/dropsite/dropsite.pro examples/draganddrop/fridgemagnets/fridgemagnets.pro examples/draganddrop/puzzle/puzzle.pro examples/effects/blurpicker/blurpicker.pro examples/effects/fademessage/fademessage.pro examples/effects/lighting/lighting.pro examples/examples.pro examples/gestures/imagegestures/imagegestures.pro examples/graphicsview/anchorlayout/anchorlayout.pro examples/graphicsview/basicgraphicslayouts/basicgraphicslayouts.pro examples/graphicsview/collidingmice/collidingmice.pro examples/graphicsview/diagramscene/diagramscene.pro examples/graphicsview/dragdroprobot/dragdroprobot.pro examples/graphicsview/elasticnodes/elasticnodes.pro examples/graphicsview/flowlayout/flowlayout.pro examples/graphicsview/graphicsview.pro examples/graphicsview/simpleanchorlayout/simpleanchorlayout.pro examples/graphicsview/weatheranchorlayout/weatheranchorlayout.pro examples/ipc/ipc.pro examples/ipc/sharedmemory/sharedmemory.pro examples/itemviews/addressbook/addressbook.pro examples/itemviews/basicsortfiltermodel/basicsortfiltermodel.pro examples/itemviews/chart/chart.pro examples/itemviews/coloreditorfactory/coloreditorfactory.pro examples/itemviews/combowidgetmapper/combowidgetmapper.pro examples/itemviews/customsortfiltermodel/customsortfiltermodel.pro examples/itemviews/dirview/dirview.pro examples/itemviews/editabletreemodel/editabletreemodel.pro examples/itemviews/fetchmore/fetchmore.pro examples/itemviews/frozencolumn/frozencolumn.pro examples/itemviews/itemviews.pro examples/itemviews/pixelator/pixelator.pro examples/itemviews/puzzle/puzzle.pro examples/itemviews/simpletreemodel/simpletreemodel.pro examples/itemviews/simplewidgetmapper/simplewidgetmapper.pro examples/itemviews/spinboxdelegate/spinboxdelegate.pro examples/itemviews/stardelegate/stardelegate.pro examples/ja_JP/linguist/hellotr/hellotr.pro examples/layouts/basiclayouts/basiclayouts.pro examples/layouts/borderlayout/borderlayout.pro examples/layouts/dynamiclayouts/dynamiclayouts.pro examples/layouts/flowlayout/flowlayout.pro examples/layouts/layouts.pro examples/linguist/arrowpad/arrowpad.pro examples/linguist/hellotr/hellotr.pro examples/linguist/linguist.pro examples/linguist/trollprint/trollprint.pro examples/mainwindows/application/application.pro examples/mainwindows/dockwidgets/dockwidgets.pro examples/mainwindows/mainwindows.pro examples/mainwindows/mdi/mdi.pro examples/mainwindows/menus/menus.pro examples/mainwindows/recentfiles/recentfiles.pro examples/mainwindows/sdi/sdi.pro examples/network/network.pro examples/opengl/opengl.pro examples/openvg/openvg.pro examples/painting/basicdrawing/basicdrawing.pro examples/painting/concentriccircles/concentriccircles.pro examples/painting/fontsampler/fontsampler.pro examples/painting/imagecomposition/imagecomposition.pro examples/painting/painterpaths/painterpaths.pro examples/painting/painting.pro examples/painting/transformations/transformations.pro examples/qtconcurrent/imagescaling/imagescaling.pro examples/qtconcurrent/map/map.pro examples/qtconcurrent/progressdialog/progressdialog.pro examples/qtconcurrent/qtconcurrent.pro examples/qtconcurrent/runfunction/runfunction.pro examples/qtconcurrent/wordcount/wordcount.pro examples/qtestlib/qtestlib.pro examples/qtestlib/tutorial1/tutorial1.pro examples/qtestlib/tutorial2/tutorial2.pro examples/qtestlib/tutorial3/tutorial3.pro examples/qtestlib/tutorial4/tutorial4.pro examples/qtestlib/tutorial5/tutorial5.pro examples/qws/dbscreen/dbscreen.pro examples/qws/framebuffer/framebuffer.pro examples/qws/mousecalibration/mousecalibration.pro examples/qws/simpledecoration/simpledecoration.pro examples/qws/svgalib/svgalib.pro examples/richtext/calendar/calendar.pro examples/richtext/orderform/orderform.pro examples/richtext/richtext.pro examples/richtext/syntaxhighlighter/syntaxhighlighter.pro examples/sql/sql.pro examples/statemachine/eventtransitions/eventtransitions.pro examples/statemachine/rogue/rogue.pro examples/statemachine/trafficlight/trafficlight.pro examples/statemachine/twowaybutton/twowaybutton.pro examples/threads/mandelbrot/mandelbrot.pro examples/threads/queuedcustomtype/queuedcustomtype.pro examples/threads/threads.pro examples/tools/codecs/codecs.pro examples/tools/completer/completer.pro examples/tools/contiguouscache/contiguouscache.pro examples/tools/customcompleter/customcompleter.pro examples/tools/customtype/customtype.pro examples/tools/customtypesending/customtypesending.pro examples/tools/echoplugin/echoplugin.pro examples/tools/echoplugin/echowindow/echowindow.pro examples/tools/echoplugin/plugin/plugin.pro examples/tools/i18n/i18n.pro examples/tools/inputpanel/inputpanel.pro examples/tools/plugandpaint/plugandpaint.pro examples/tools/plugandpaintplugins/basictools/basictools.pro examples/tools/plugandpaintplugins/extrafilters/extrafilters.pro examples/tools/plugandpaintplugins/plugandpaintplugins.pro examples/tools/regexp/regexp.pro examples/tools/settingseditor/settingseditor.pro examples/tools/styleplugin/plugin/plugin.pro examples/tools/styleplugin/styleplugin.pro examples/tools/styleplugin/stylewindow/stylewindow.pro examples/tools/tools.pro examples/tools/treemodelcompleter/treemodelcompleter.pro examples/tools/undoframework/undoframework.pro examples/touch/dials/dials.pro examples/touch/fingerpaint/fingerpaint.pro examples/touch/knobs/knobs.pro examples/touch/pinchzoom/pinchzoom.pro examples/tutorials/addressbook-fr/addressbook-fr.pro examples/tutorials/addressbook-fr/part1/part1.pro examples/tutorials/addressbook-fr/part2/part2.pro examples/tutorials/addressbook-fr/part3/part3.pro examples/tutorials/addressbook-fr/part4/part4.pro examples/tutorials/addressbook-fr/part5/part5.pro examples/tutorials/addressbook-fr/part6/part6.pro examples/tutorials/addressbook-fr/part7/part7.pro examples/tutorials/addressbook/addressbook.pro examples/tutorials/addressbook/part1/part1.pro examples/tutorials/addressbook/part2/part2.pro examples/tutorials/addressbook/part3/part3.pro examples/tutorials/addressbook/part4/part4.pro examples/tutorials/addressbook/part5/part5.pro examples/tutorials/addressbook/part6/part6.pro examples/tutorials/addressbook/part7/part7.pro examples/tutorials/modelview/1_readonly/1_readonly.pro examples/tutorials/modelview/2_formatting/2_formatting.pro examples/tutorials/modelview/3_changingmodel/3_changingmodel.pro examples/tutorials/modelview/4_headers/4_headers.pro examples/tutorials/modelview/5_edit/5_edit.pro examples/tutorials/modelview/6_treeview/6_treeview.pro examples/tutorials/modelview/7_selections/7_selections.pro examples/tutorials/modelview/modelview.pro examples/tutorials/widgets/childwidget/childwidget.pro examples/tutorials/widgets/nestedlayouts/nestedlayouts.pro examples/tutorials/widgets/toplevel/toplevel.pro examples/tutorials/widgets/windowlayout/windowlayout.pro examples/uitools/multipleinheritance/multipleinheritance.pro examples/uitools/textfinder/textfinder.pro examples/uitools/uitools.pro examples/widgets/analogclock/analogclock.pro examples/widgets/calculator/calculator.pro examples/widgets/calendarwidget/calendarwidget.pro examples/widgets/charactermap/charactermap.pro examples/widgets/codeeditor/codeeditor.pro examples/widgets/digitalclock/digitalclock.pro examples/widgets/groupbox/groupbox.pro examples/widgets/icons/icons.pro examples/widgets/imageviewer/imageviewer.pro examples/widgets/lineedits/lineedits.pro examples/widgets/movie/movie.pro examples/widgets/scribble/scribble.pro examples/widgets/shapedclock/shapedclock.pro examples/widgets/sliders/sliders.pro examples/widgets/softkeys/softkeys.pro examples/widgets/spinboxes/spinboxes.pro examples/widgets/styles/styles.pro examples/widgets/stylesheet/stylesheet.pro examples/widgets/tablet/tablet.pro examples/widgets/tetrix/tetrix.pro examples/widgets/tooltips/tooltips.pro examples/widgets/validators/validators.pro examples/widgets/widgets.pro examples/widgets/windowflags/windowflags.pro examples/xml/xml.pro mkspecs/qws/freebsd-generic-g++/qplatformdefs.h mkspecs/qws/linux-arm-g++/qplatformdefs.h mkspecs/qws/linux-arm-gnueabi-g++/qplatformdefs.h mkspecs/qws/linux-armv6-g++/qplatformdefs.h mkspecs/qws/linux-avr32-g++/qplatformdefs.h mkspecs/qws/linux-cellon-g++/qplatformdefs.h mkspecs/qws/linux-dm7000-g++/qplatformdefs.h mkspecs/qws/linux-dm800-g++/qplatformdefs.h mkspecs/qws/linux-generic-g++-32/qplatformdefs.h mkspecs/qws/linux-generic-g++/qplatformdefs.h mkspecs/qws/linux-ipaq-g++/qplatformdefs.h mkspecs/qws/linux-lsb-g++/qplatformdefs.h mkspecs/qws/linux-mips-g++/qplatformdefs.h mkspecs/qws/linux-nacl-g++/qplatformdefs.h mkspecs/qws/linux-powerpc-g++/qplatformdefs.h mkspecs/qws/linux-sh-g++/qplatformdefs.h mkspecs/qws/linux-sh4al-g++/qplatformdefs.h mkspecs/qws/linux-sharp-g++/qplatformdefs.h mkspecs/qws/linux-x86-g++/qplatformdefs.h mkspecs/qws/linux-x86_64-g++/qplatformdefs.h mkspecs/qws/linux-zylonite-g++/qplatformdefs.h mkspecs/qws/macx-generic-g++/qplatformdefs.h mkspecs/qws/macx-iphonedevice-g++/qplatformdefs.h mkspecs/qws/macx-iphonesimulator-g++/qplatformdefs.h mkspecs/qws/macx-nacl-g++/qplatformdefs.h mkspecs/qws/solaris-generic-g++/qplatformdefs.h src/gui/dialogs/qprintdialog_qws.cpp src/gui/egl/qegl_qws.cpp src/gui/embedded/qcopchannel_qws.cpp src/gui/embedded/qcopchannel_qws.h src/gui/embedded/qdecoration_qws.cpp src/gui/embedded/qdecoration_qws.h src/gui/embedded/qdecorationdefault_qws.cpp src/gui/embedded/qdecorationdefault_qws.h src/gui/embedded/qdecorationfactory_qws.cpp src/gui/embedded/qdecorationfactory_qws.h src/gui/embedded/qdecorationplugin_qws.cpp src/gui/embedded/qdecorationplugin_qws.h src/gui/embedded/qdecorationstyled_qws.cpp src/gui/embedded/qdecorationstyled_qws.h src/gui/embedded/qdecorationwindows_qws.cpp src/gui/embedded/qdecorationwindows_qws.h src/gui/embedded/qdirectpainter_qws.cpp src/gui/embedded/qdirectpainter_qws.h src/gui/embedded/qkbd_defaultmap_qws_p.h src/gui/embedded/qkbd_qws.cpp src/gui/embedded/qkbd_qws.h src/gui/embedded/qkbd_qws_p.h src/gui/embedded/qkbddriverfactory_qws.cpp src/gui/embedded/qkbddriverfactory_qws.h src/gui/embedded/qkbddriverplugin_qws.cpp src/gui/embedded/qkbddriverplugin_qws.h src/gui/embedded/qkbdintegrity_qws.cpp src/gui/embedded/qkbdintegrity_qws.h src/gui/embedded/qkbdlinuxinput_qws.cpp src/gui/embedded/qkbdlinuxinput_qws.h src/gui/embedded/qkbdqnx_qws.cpp src/gui/embedded/qkbdqnx_qws.h src/gui/embedded/qkbdtty_qws.cpp src/gui/embedded/qkbdtty_qws.h src/gui/embedded/qkbdum_qws.cpp src/gui/embedded/qkbdum_qws.h src/gui/embedded/qkbdvfb_qws.cpp src/gui/embedded/qkbdvfb_qws.h src/gui/embedded/qlock.cpp src/gui/embedded/qlock_p.h src/gui/embedded/qmouse_qws.cpp src/gui/embedded/qmouse_qws.h src/gui/embedded/qmousedriverfactory_qws.cpp src/gui/embedded/qmousedriverfactory_qws.h src/gui/embedded/qmousedriverplugin_qws.cpp src/gui/embedded/qmousedriverplugin_qws.h src/gui/embedded/qmouseintegrity_qws.cpp src/gui/embedded/qmouseintegrity_qws.h src/gui/embedded/qmouselinuxinput_qws.cpp src/gui/embedded/qmouselinuxinput_qws.h src/gui/embedded/qmouselinuxtp_qws.cpp src/gui/embedded/qmouselinuxtp_qws.h src/gui/embedded/qmousepc_qws.cpp src/gui/embedded/qmousepc_qws.h src/gui/embedded/qmouseqnx_qws.cpp src/gui/embedded/qmouseqnx_qws.h src/gui/embedded/qmousetslib_qws.cpp src/gui/embedded/qmousetslib_qws.h src/gui/embedded/qmousevfb_qws.cpp src/gui/embedded/qmousevfb_qws.h src/gui/embedded/qscreen_qws.cpp src/gui/embedded/qscreen_qws.h src/gui/embedded/qscreendriverfactory_qws.cpp src/gui/embedded/qscreendriverfactory_qws.h src/gui/embedded/qscreendriverplugin_qws.cpp src/gui/embedded/qscreendriverplugin_qws.h src/gui/embedded/qscreenintegrityfb_qws.cpp src/gui/embedded/qscreenintegrityfb_qws.h src/gui/embedded/qscreenlinuxfb_qws.cpp src/gui/embedded/qscreenlinuxfb_qws.h src/gui/embedded/qscreenmulti_qws.cpp src/gui/embedded/qscreenmulti_qws_p.h src/gui/embedded/qscreenproxy_qws.cpp src/gui/embedded/qscreenproxy_qws.h src/gui/embedded/qscreenqnx_qws.cpp src/gui/embedded/qscreenqnx_qws.h src/gui/embedded/qscreentransformed_qws.cpp src/gui/embedded/qscreentransformed_qws.h src/gui/embedded/qscreenvfb_qws.cpp src/gui/embedded/qscreenvfb_qws.h src/gui/embedded/qsoundqss_qws.cpp src/gui/embedded/qsoundqss_qws.h src/gui/embedded/qtransportauth_qws.cpp src/gui/embedded/qtransportauth_qws.h src/gui/embedded/qtransportauth_qws_p.h src/gui/embedded/qtransportauthdefs_qws.h src/gui/embedded/qunixsocket.cpp src/gui/embedded/qunixsocket_p.h src/gui/embedded/qunixsocketserver.cpp src/gui/embedded/qunixsocketserver_p.h src/gui/embedded/qvfbhdr.h src/gui/embedded/qwindowsystem_p.h src/gui/embedded/qwindowsystem_qws.cpp src/gui/embedded/qwindowsystem_qws.h src/gui/embedded/qwscommand_qws.cpp src/gui/embedded/qwscommand_qws_p.h src/gui/embedded/qwscursor_qws.cpp src/gui/embedded/qwsdisplay_qws.h src/gui/embedded/qwsdisplay_qws_p.h src/gui/embedded/qwsembedwidget.cpp src/gui/embedded/qwsevent_qws.cpp src/gui/embedded/qwsevent_qws.h src/gui/embedded/qwslock.cpp src/gui/embedded/qwslock_p.h src/gui/embedded/qwsmanager_p.h src/gui/embedded/qwsmanager_qws.cpp src/gui/embedded/qwsmanager_qws.h src/gui/embedded/qwsproperty_qws.cpp src/gui/embedded/qwsproperty_qws.h src/gui/embedded/qwsprotocolitem_qws.h src/gui/embedded/qwssharedmemory.cpp src/gui/embedded/qwssharedmemory_p.h src/gui/embedded/qwssignalhandler.cpp src/gui/embedded/qwssignalhandler_p.h src/gui/embedded/qwssocket_qws.cpp src/gui/embedded/qwssocket_qws.h src/gui/embedded/qwsutils_qws.h src/gui/image/qpixmap_qws.cpp src/gui/inputmethod/qwsinputcontext_p.h src/gui/inputmethod/qwsinputcontext_qws.cpp src/gui/kernel/qapplication_qpa.cpp src/gui/kernel/qapplication_qws.cpp src/gui/kernel/qclipboard_qws.cpp src/gui/kernel/qcursor_qws.cpp src/gui/kernel/qdesktopwidget_qws.cpp src/gui/kernel/qeventdispatcher_glib_qws.cpp src/gui/kernel/qeventdispatcher_glib_qws_p.h src/gui/kernel/qeventdispatcher_qws.cpp src/gui/kernel/qeventdispatcher_qws_p.h src/gui/kernel/qplatformintegration_qpa.cpp src/gui/kernel/qplatformwindowformat_qpa.cpp src/gui/kernel/qplatformwindowformat_qpa.h src/gui/kernel/qsessionmanager_qws.cpp src/gui/kernel/qsound_qws.cpp src/gui/kernel/qwidget_qws.cpp src/gui/painting/qcolormap_qws.cpp src/gui/painting/qgraphicssystem.cpp src/gui/painting/qgraphicssystem_mac.cpp src/gui/painting/qgraphicssystem_mac_p.h src/gui/painting/qgraphicssystem_p.h src/gui/painting/qgraphicssystem_qws.cpp src/gui/painting/qgraphicssystem_qws_p.h src/gui/painting/qgraphicssystem_raster.cpp src/gui/painting/qgraphicssystem_raster_p.h src/gui/painting/qgraphicssystem_runtime.cpp src/gui/painting/qgraphicssystem_runtime_p.h src/gui/painting/qgraphicssystemfactory.cpp src/gui/painting/qgraphicssystemfactory_p.h src/gui/painting/qgraphicssystemplugin.cpp src/gui/painting/qgraphicssystemplugin_p.h src/gui/painting/qpaintdevice_x11.cpp src/gui/painting/qprintengine_ps.cpp src/gui/painting/qprintengine_ps_p.h src/gui/painting/qprintengine_qws.cpp src/gui/painting/qprintengine_qws_p.h src/gui/painting/qregion_qws.cpp src/gui/painting/qunifiedtoolbarsurface_mac.cpp src/gui/painting/qunifiedtoolbarsurface_mac_p.h src/gui/painting/qwindowsurface_mac.cpp src/gui/painting/qwindowsurface_qws.cpp src/gui/painting/qwindowsurface_qws_p.h src/gui/painting/qwindowsurface_raster.cpp src/gui/painting/qwindowsurface_raster_p.h src/gui/painting/qwindowsurface_s60.cpp src/gui/painting/qwindowsurface_s60_p.h src/gui/painting/qwindowsurface_x11.cpp src/gui/painting/qwindowsurface_x11_p.h src/gui/painting/qwmatrix.h src/gui/text/qabstractfontengine_qws.cpp src/gui/text/qabstractfontengine_qws.h src/gui/text/qfont_qws.cpp src/gui/text/qfontdatabase_qws.cpp src/gui/text/qfontengine_qws.cpp src/opengl/qgl_qpa.cpp src/opengl/qgl_qws.cpp src/opengl/qglscreen_qws.cpp src/opengl/qglscreen_qws.h src/opengl/qglwindowsurface_qws.cpp src/opengl/qgraphicssystem_gl.cpp src/opengl/qgraphicssystem_gl_p.h src/openvg/qpaintengine_vg.cpp src/openvg/qpaintengine_vg_p.h src/openvg/qpixmapdata_vg.cpp src/openvg/qpixmapdata_vg_p.h src/openvg/qpixmapfilter_vg.cpp src/openvg/qpixmapfilter_vg_p.h src/openvg/qvg.h src/openvg/qvg_p.h src/openvg/qvg_symbian.cpp src/openvg/qvgcompositionhelper_p.h src/openvg/qvgfontglyphcache_p.h src/openvg/qvgimagepool.cpp src/openvg/qvgimagepool_p.h src/openvg/qwindowsurface_vg.cpp src/openvg/qwindowsurface_vg_p.h src/openvg/qwindowsurface_vgegl.cpp src/openvg/qwindowsurface_vgegl_p.h src/plugins/decorations/default/main.cpp src/plugins/decorations/styled/main.cpp src/plugins/decorations/windows/main.cpp src/plugins/gfxdrivers/ahi/qscreenahi_qws.cpp src/plugins/gfxdrivers/ahi/qscreenahi_qws.h src/plugins/gfxdrivers/ahi/qscreenahiplugin.cpp src/plugins/gfxdrivers/directfb/qdirectfbkeyboard.cpp src/plugins/gfxdrivers/directfb/qdirectfbkeyboard.h src/plugins/gfxdrivers/directfb/qdirectfbmouse.cpp src/plugins/gfxdrivers/directfb/qdirectfbmouse.h src/plugins/gfxdrivers/directfb/qdirectfbpaintdevice.cpp src/plugins/gfxdrivers/directfb/qdirectfbpaintdevice.h src/plugins/gfxdrivers/directfb/qdirectfbpaintengine.cpp src/plugins/gfxdrivers/directfb/qdirectfbpaintengine.h src/plugins/gfxdrivers/directfb/qdirectfbpixmap.cpp src/plugins/gfxdrivers/directfb/qdirectfbpixmap.h src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp src/plugins/gfxdrivers/directfb/qdirectfbscreen.h src/plugins/gfxdrivers/directfb/qdirectfbscreenplugin.cpp src/plugins/gfxdrivers/directfb/qdirectfbwindowsurface.cpp src/plugins/gfxdrivers/directfb/qdirectfbwindowsurface.h src/plugins/gfxdrivers/eglnullws/eglnullwsscreen.cpp src/plugins/gfxdrivers/eglnullws/eglnullwsscreen.h src/plugins/gfxdrivers/eglnullws/eglnullwsscreenplugin.cpp src/plugins/gfxdrivers/eglnullws/eglnullwsscreenplugin.h src/plugins/gfxdrivers/eglnullws/eglnullwswindowsurface.cpp src/plugins/gfxdrivers/eglnullws/eglnullwswindowsurface.h src/plugins/gfxdrivers/linuxfb/main.cpp src/plugins/gfxdrivers/powervr/QWSWSEGL/pvrqwsdrawable.c src/plugins/gfxdrivers/powervr/QWSWSEGL/pvrqwsdrawable.h src/plugins/gfxdrivers/powervr/QWSWSEGL/pvrqwsdrawable_p.h src/plugins/gfxdrivers/powervr/QWSWSEGL/pvrqwswsegl.c src/plugins/gfxdrivers/powervr/pvreglscreen/pvreglscreen.cpp src/plugins/gfxdrivers/powervr/pvreglscreen/pvreglscreen.h src/plugins/gfxdrivers/powervr/pvreglscreen/pvreglscreenplugin.cpp src/plugins/gfxdrivers/powervr/pvreglscreen/pvreglwindowsurface.cpp src/plugins/gfxdrivers/powervr/pvreglscreen/pvreglwindowsurface.h src/plugins/gfxdrivers/qvfb/main.cpp src/plugins/gfxdrivers/transformed/main.cpp src/plugins/gfxdrivers/vnc/main.cpp src/plugins/gfxdrivers/vnc/qscreenvnc_p.h src/plugins/gfxdrivers/vnc/qscreenvnc_qws.cpp src/plugins/gfxdrivers/vnc/qscreenvnc_qws.h src/plugins/graphicssystems/meego/dithering.cpp src/plugins/graphicssystems/meego/qmeegoextensions.cpp src/plugins/graphicssystems/meego/qmeegoextensions.h src/plugins/graphicssystems/meego/qmeegographicssystem.cpp src/plugins/graphicssystems/meego/qmeegographicssystem.h src/plugins/graphicssystems/meego/qmeegographicssystemplugin.cpp src/plugins/graphicssystems/meego/qmeegographicssystemplugin.h src/plugins/graphicssystems/meego/qmeegolivepixmapdata.cpp src/plugins/graphicssystems/meego/qmeegolivepixmapdata.h src/plugins/graphicssystems/meego/qmeegopixmapdata.cpp src/plugins/graphicssystems/meego/qmeegopixmapdata.h src/plugins/graphicssystems/meego/qmeegorasterpixmapdata.cpp src/plugins/graphicssystems/opengl/main.cpp src/plugins/graphicssystems/openvg/qgraphicssystem_vg.cpp src/plugins/graphicssystems/openvg/qgraphicssystem_vg_p.h src/plugins/graphicssystems/shivavg/main.cpp src/plugins/graphicssystems/shivavg/shivavggraphicssystem.cpp src/plugins/graphicssystems/shivavg/shivavggraphicssystem.h src/plugins/graphicssystems/shivavg/shivavgwindowsurface.cpp src/plugins/graphicssystems/shivavg/shivavgwindowsurface.h src/plugins/graphicssystems/trace/main.cpp src/plugins/graphicssystems/trace/qgraphicssystem_trace.cpp src/plugins/graphicssystems/trace/qgraphicssystem_trace_p.h src/plugins/kbddrivers/linuxinput/main.cpp src/plugins/mousedrivers/linuxtp/main.cpp src/plugins/mousedrivers/pc/main.cpp src/plugins/mousedrivers/tslib/main.cpp src/widgets/kernel/qwidget_qpa.cpp
Diffstat (limited to 'examples/opengl')
-rw-r--r--examples/opengl/2dpainting/2dpainting.desktop11
-rw-r--r--examples/opengl/2dpainting/2dpainting.pro4
-rw-r--r--examples/opengl/cube/cube.desktop11
-rw-r--r--examples/opengl/cube/cube.pngbin0 -> 30341 bytes
-rw-r--r--examples/opengl/cube/cube.pro40
-rw-r--r--examples/opengl/cube/fshader.glsl18
-rw-r--r--examples/opengl/cube/geometryengine.cpp130
-rw-r--r--examples/opengl/cube/geometryengine.h24
-rw-r--r--examples/opengl/cube/main.cpp22
-rw-r--r--examples/opengl/cube/mainwidget.cpp192
-rw-r--r--examples/opengl/cube/mainwidget.h53
-rw-r--r--examples/opengl/cube/shaders.qrc6
-rw-r--r--examples/opengl/cube/textures.qrc5
-rw-r--r--examples/opengl/cube/vshader.glsl24
-rw-r--r--examples/opengl/framebufferobject/framebufferobject.desktop11
-rw-r--r--examples/opengl/framebufferobject2/framebufferobject2.desktop11
-rw-r--r--examples/opengl/framebufferobject2/framebufferobject2.pro5
-rw-r--r--examples/opengl/grabber/grabber.desktop11
-rw-r--r--examples/opengl/grabber/grabber.pro5
-rw-r--r--examples/opengl/hellogl/hellogl.desktop11
-rw-r--r--examples/opengl/hellogl/hellogl.pro5
-rw-r--r--examples/opengl/hellogl_es/hellogl_es.desktop11
-rw-r--r--examples/opengl/hellogl_es/hellogl_es.pro8
-rw-r--r--examples/opengl/hellogl_es2/hellogl_es2.desktop11
-rw-r--r--examples/opengl/hellogl_es2/hellogl_es2.pro13
-rw-r--r--examples/opengl/opengl.pro2
-rw-r--r--examples/opengl/overpainting/overpainting.desktop11
-rw-r--r--examples/opengl/overpainting/overpainting.pro6
-rw-r--r--examples/opengl/pbuffers/pbuffers.desktop11
-rw-r--r--examples/opengl/pbuffers/pbuffers.pro6
-rw-r--r--examples/opengl/pbuffers2/pbuffers2.desktop11
-rw-r--r--examples/opengl/pbuffers2/pbuffers2.pro6
-rw-r--r--examples/opengl/samplebuffers/samplebuffers.desktop11
-rw-r--r--examples/opengl/samplebuffers/samplebuffers.pro5
-rw-r--r--examples/opengl/textures/textures.desktop11
-rw-r--r--examples/opengl/textures/textures.pro4
36 files changed, 723 insertions, 3 deletions
diff --git a/examples/opengl/2dpainting/2dpainting.desktop b/examples/opengl/2dpainting/2dpainting.desktop
new file mode 100644
index 0000000000..0b3570df34
--- /dev/null
+++ b/examples/opengl/2dpainting/2dpainting.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Name=2D Painting
+Exec=/opt/usr/bin/2dpainting
+Icon=2dpainting
+X-Window-Icon=
+X-HildonDesk-ShowInToolbar=true
+X-Osso-Type=application/x-executable
diff --git a/examples/opengl/2dpainting/2dpainting.pro b/examples/opengl/2dpainting/2dpainting.pro
index 7014ce6949..5d361bc1bf 100644
--- a/examples/opengl/2dpainting/2dpainting.pro
+++ b/examples/opengl/2dpainting/2dpainting.pro
@@ -17,3 +17,7 @@ sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/opengl/2dpainting
INSTALLS += target sources
symbian: CONFIG += qt_example
+maemo5: CONFIG += qt_example
+
+symbian: warning(This example might not fully work on Symbian platform)
+simulator: warning(This example might not fully work on Simulator platform)
diff --git a/examples/opengl/cube/cube.desktop b/examples/opengl/cube/cube.desktop
new file mode 100644
index 0000000000..627e5f2691
--- /dev/null
+++ b/examples/opengl/cube/cube.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Name=Cube OpenGL ES 2.0
+Exec=/opt/usr/bin/cube
+Icon=cube
+X-Window-Icon=
+X-HildonDesk-ShowInToolbar=true
+X-Osso-Type=application/x-executable
diff --git a/examples/opengl/cube/cube.png b/examples/opengl/cube/cube.png
new file mode 100644
index 0000000000..42c8c51b3a
--- /dev/null
+++ b/examples/opengl/cube/cube.png
Binary files differ
diff --git a/examples/opengl/cube/cube.pro b/examples/opengl/cube/cube.pro
new file mode 100644
index 0000000000..64f6973c00
--- /dev/null
+++ b/examples/opengl/cube/cube.pro
@@ -0,0 +1,40 @@
+#-------------------------------------------------
+#
+# Project created by QtCreator 2010-06-23T12:55:35
+#
+#-------------------------------------------------
+
+QT += core gui
+
+TARGET = cube
+TEMPLATE = app
+
+SOURCES += main.cpp
+
+contains(QT_CONFIG, opengl) {
+ message(Building with OpenGL support.)
+ QT += opengl
+
+ SOURCES += mainwidget.cpp \
+ geometryengine.cpp
+
+ HEADERS += \
+ mainwidget.h \
+ geometryengine.h
+
+ RESOURCES += \
+ shaders.qrc \
+ textures.qrc
+
+ OTHER_FILES += \
+ vshader.glsl \
+ fshader.glsl
+} else {
+ message(OpenGL support is not available.)
+}
+
+symbian: include($$QT_SOURCE_TREE/examples/symbianpkgrules.pri)
+maemo5: include($$QT_SOURCE_TREE/examples/maemo5pkgrules.pri)
+
+symbian: warning(This example might not fully work on Symbian platform)
+simulator: warning(This example might not fully work on Simulator platform)
diff --git a/examples/opengl/cube/fshader.glsl b/examples/opengl/cube/fshader.glsl
new file mode 100644
index 0000000000..18068cf0e6
--- /dev/null
+++ b/examples/opengl/cube/fshader.glsl
@@ -0,0 +1,18 @@
+#ifdef GL_ES
+// Set default precision to medium
+precision mediump int;
+precision mediump float;
+#endif
+
+uniform sampler2D texture;
+
+varying vec2 v_texcoord;
+
+//! [0]
+void main()
+{
+ // Set fragment color from texture
+ gl_FragColor = texture2D(texture, v_texcoord);
+}
+//! [0]
+
diff --git a/examples/opengl/cube/geometryengine.cpp b/examples/opengl/cube/geometryengine.cpp
new file mode 100644
index 0000000000..2f6f65948d
--- /dev/null
+++ b/examples/opengl/cube/geometryengine.cpp
@@ -0,0 +1,130 @@
+#include "geometryengine.h"
+
+#include <QVector2D>
+#include <QVector3D>
+
+struct VertexData
+{
+ QVector3D position;
+ QVector2D texCoord;
+};
+
+GeometryEngine::GeometryEngine() : vboIds(new GLuint[2])
+{
+}
+
+GeometryEngine::~GeometryEngine()
+{
+ glDeleteBuffers(2, vboIds);
+ delete[] vboIds;
+}
+
+void GeometryEngine::init()
+{
+//! [0]
+ // Generate 2 VBOs
+ glGenBuffers(2, vboIds);
+
+//! [0]
+
+ // Initializes cube geometry and transfers it to VBOs
+ initCubeGeometry();
+}
+
+void GeometryEngine::initCubeGeometry()
+{
+ // For cube we would need only 8 vertices but we have to
+ // duplicate vertex for each face because texture coordinate
+ // is different.
+ VertexData vertices[] = {
+ // Vertex data for face 0
+ {QVector3D(-1.0, -1.0, 1.0), QVector2D(0.0, 0.0)}, // v0
+ {QVector3D( 1.0, -1.0, 1.0), QVector2D(0.33, 0.0)}, // v1
+ {QVector3D(-1.0, 1.0, 1.0), QVector2D(0.0, 0.5)}, // v2
+ {QVector3D( 1.0, 1.0, 1.0), QVector2D(0.33, 0.5)}, // v3
+
+ // Vertex data for face 1
+ {QVector3D( 1.0, -1.0, 1.0), QVector2D( 0.0, 0.5)}, // v4
+ {QVector3D( 1.0, -1.0, -1.0), QVector2D(0.33, 0.5)}, // v5
+ {QVector3D( 1.0, 1.0, 1.0), QVector2D(0.0, 1.0)}, // v6
+ {QVector3D( 1.0, 1.0, -1.0), QVector2D(0.33, 1.0)}, // v7
+
+ // Vertex data for face 2
+ {QVector3D( 1.0, -1.0, -1.0), QVector2D(0.66, 0.5)}, // v8
+ {QVector3D(-1.0, -1.0, -1.0), QVector2D(1.0, 0.5)}, // v9
+ {QVector3D( 1.0, 1.0, -1.0), QVector2D(0.66, 1.0)}, // v10
+ {QVector3D(-1.0, 1.0, -1.0), QVector2D(1.0, 1.0)}, // v11
+
+ // Vertex data for face 3
+ {QVector3D(-1.0, -1.0, -1.0), QVector2D(0.66, 0.0)}, // v12
+ {QVector3D(-1.0, -1.0, 1.0), QVector2D(1.0, 0.0)}, // v13
+ {QVector3D(-1.0, 1.0, -1.0), QVector2D(0.66, 0.5)}, // v14
+ {QVector3D(-1.0, 1.0, 1.0), QVector2D(1.0, 0.5)}, // v15
+
+ // Vertex data for face 4
+ {QVector3D(-1.0, -1.0, -1.0), QVector2D(0.33, 0.0)}, // v16
+ {QVector3D( 1.0, -1.0, -1.0), QVector2D(0.66, 0.0)}, // v17
+ {QVector3D(-1.0, -1.0, 1.0), QVector2D(0.33, 0.5)}, // v18
+ {QVector3D( 1.0, -1.0, 1.0), QVector2D(0.66, 0.5)}, // v19
+
+ // Vertex data for face 5
+ {QVector3D(-1.0, 1.0, 1.0), QVector2D(0.33, 0.5)}, // v20
+ {QVector3D( 1.0, 1.0, 1.0), QVector2D(0.66, 0.5)}, // v21
+ {QVector3D(-1.0, 1.0, -1.0), QVector2D(0.33, 1.0)}, // v22
+ {QVector3D( 1.0, 1.0, -1.0), QVector2D(0.66, 1.0)} // v23
+ };
+
+ // Indices for drawing cube faces using triangle strips.
+ // Triangle strips can be connected by duplicating indices
+ // between the strips. If connecting strips have opposite
+ // vertex order then last index of the first strip and first
+ // index of the second strip needs to be duplicated. If
+ // connecting strips have same vertex order then only last
+ // index of the first strip needs to be duplicated.
+ GLushort indices[] = {
+ 0, 1, 2, 3, 3, // Face 0 - triangle strip ( v0, v1, v2, v3)
+ 4, 4, 5, 6, 7, 7, // Face 1 - triangle strip ( v4, v5, v6, v7)
+ 8, 8, 9, 10, 11, 11, // Face 2 - triangle strip ( v8, v9, v10, v11)
+ 12, 12, 13, 14, 15, 15, // Face 3 - triangle strip (v12, v13, v14, v15)
+ 16, 16, 17, 18, 19, 19, // Face 4 - triangle strip (v16, v17, v18, v19)
+ 20, 20, 21, 22, 23 // Face 5 - triangle strip (v20, v21, v22, v23)
+ };
+
+//! [1]
+ // Transfer vertex data to VBO 0
+ glBindBuffer(GL_ARRAY_BUFFER, vboIds[0]);
+ glBufferData(GL_ARRAY_BUFFER, 24 * sizeof(VertexData), vertices, GL_STATIC_DRAW);
+
+ // Transfer index data to VBO 1
+ glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, vboIds[1]);
+ glBufferData(GL_ELEMENT_ARRAY_BUFFER, 34 * sizeof(GLushort), indices, GL_STATIC_DRAW);
+//! [1]
+}
+
+//! [2]
+void GeometryEngine::drawCubeGeometry(QGLShaderProgram *program)
+{
+ // Tell OpenGL which VBOs to use
+ glBindBuffer(GL_ARRAY_BUFFER, vboIds[0]);
+ glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, vboIds[1]);
+
+ // Offset for position
+ int offset = 0;
+
+ // Tell OpenGL programmable pipeline how to locate vertex position data
+ int vertexLocation = program->attributeLocation("a_position");
+ program->enableAttributeArray(vertexLocation);
+ glVertexAttribPointer(vertexLocation, 3, GL_FLOAT, GL_FALSE, sizeof(VertexData), (const void *)offset);
+
+ // Offset for texture coordinate
+ offset += sizeof(QVector3D);
+
+ // Tell OpenGL programmable pipeline how to locate vertex texture coordinate data
+ int texcoordLocation = program->attributeLocation("a_texcoord");
+ program->enableAttributeArray(texcoordLocation);
+ glVertexAttribPointer(texcoordLocation, 2, GL_FLOAT, GL_FALSE, sizeof(VertexData), (const void *)offset);
+
+ // Draw cube geometry using indices from VBO 1
+ glDrawElements(GL_TRIANGLE_STRIP, 34, GL_UNSIGNED_SHORT, 0);
+}
+//! [2]
diff --git a/examples/opengl/cube/geometryengine.h b/examples/opengl/cube/geometryengine.h
new file mode 100644
index 0000000000..d0fba694a2
--- /dev/null
+++ b/examples/opengl/cube/geometryengine.h
@@ -0,0 +1,24 @@
+#ifndef GEOMETRYENGINE_H
+#define GEOMETRYENGINE_H
+
+#include <QtOpenGL/QGLFunctions>
+#include <QtOpenGL/QGLShaderProgram>
+
+class GeometryEngine : protected QGLFunctions
+{
+public:
+ GeometryEngine();
+ virtual ~GeometryEngine();
+
+ void init();
+
+ void drawCubeGeometry(QGLShaderProgram *program);
+
+private:
+ void initCubeGeometry();
+
+ GLuint *vboIds;
+
+};
+
+#endif // GEOMETRYENGINE_H
diff --git a/examples/opengl/cube/main.cpp b/examples/opengl/cube/main.cpp
new file mode 100644
index 0000000000..faac8a0bd8
--- /dev/null
+++ b/examples/opengl/cube/main.cpp
@@ -0,0 +1,22 @@
+#include <QtGui/QApplication>
+#include <QLabel>
+
+#ifndef QT_NO_OPENGL
+#include "mainwidget.h"
+#endif
+
+int main(int argc, char *argv[])
+{
+ QApplication a(argc, argv);
+ a.setApplicationName("cube");
+ a.setApplicationVersion("0.1");
+#ifndef QT_NO_OPENGL
+ MainWidget w;
+ w.resize(640, 480);
+ w.show();
+#else
+ QLabel * notifyLabel = new QLabel("OpenGL Support required");
+ notifyLabel->show();
+#endif
+ return a.exec();
+}
diff --git a/examples/opengl/cube/mainwidget.cpp b/examples/opengl/cube/mainwidget.cpp
new file mode 100644
index 0000000000..bead5f79ed
--- /dev/null
+++ b/examples/opengl/cube/mainwidget.cpp
@@ -0,0 +1,192 @@
+#include "mainwidget.h"
+
+#include "geometryengine.h"
+
+#include <QtOpenGL/QGLShaderProgram>
+
+#include <QBasicTimer>
+#include <QMouseEvent>
+
+#include <math.h>
+
+#include <QDebug>
+
+MainWidget::MainWidget(QWidget *parent) :
+ QGLWidget(parent),
+ timer(new QBasicTimer),
+ program(new QGLShaderProgram),
+ geometries(new GeometryEngine)
+{
+}
+
+MainWidget::~MainWidget()
+{
+ delete timer; timer = 0;
+ delete program; program = 0;
+ delete geometries; geometries = 0;
+
+ deleteTexture(texture);
+}
+
+//! [0]
+void MainWidget::mousePressEvent(QMouseEvent *e)
+{
+ // Saving mouse press position
+ mousePressPosition = QVector2D(e->posF());
+}
+
+void MainWidget::mouseReleaseEvent(QMouseEvent *e)
+{
+ // Mouse release position - mouse press position
+ QVector2D diff = QVector2D(e->posF()) - mousePressPosition;
+
+ // Rotation axis is perpendicular to the mouse position difference
+ // vector
+ QVector3D n = QVector3D(diff.y(), diff.x(), 0.0).normalized();
+
+ // Accelerate angular speed relative to the length of the mouse sweep
+ qreal acc = diff.length() / 100.0;
+
+ // Calculate new rotation axis as weighted sum
+ rotationAxis = (rotationAxis * angularSpeed + n * acc).normalized();
+
+ // Increase angular speed
+ angularSpeed += acc;
+}
+//! [0]
+
+//! [1]
+void MainWidget::timerEvent(QTimerEvent *e)
+{
+ Q_UNUSED(e);
+
+ // Decrease angular speed (friction)
+ angularSpeed *= 0.99;
+
+ // Stop rotation when speed goes below threshold
+ if (angularSpeed < 0.01)
+ angularSpeed = 0.0;
+ else {
+ // Update rotation
+ rotation = QQuaternion::fromAxisAndAngle(rotationAxis, angularSpeed) * rotation;
+
+ // Update scene
+ updateGL();
+ }
+}
+//! [1]
+
+void MainWidget::initializeGL()
+{
+ qglClearColor(Qt::black);
+
+ qDebug() << "Initializing shaders...";
+ initShaders();
+
+ qDebug() << "Initializing textures...";
+ initTextures();
+
+//! [2]
+ // Enable depth buffer
+ glEnable(GL_DEPTH_TEST);
+
+ // Enable back face culling
+ glEnable(GL_CULL_FACE);
+//! [2]
+
+ qDebug() << "Initializing geometries...";
+ geometries->init();
+
+ // using QBasicTimer because its faster that QTimer
+ timer->start(12, this);
+}
+
+//! [3]
+void MainWidget::initShaders()
+{
+ // Overriding system locale until shaders are compiled
+ setlocale(LC_NUMERIC, "C");
+
+ // Compiling vertex shader
+ if (!program->addShaderFromSourceFile(QGLShader::Vertex, ":/vshader.glsl"))
+ close();
+
+ // Compiling fragment shader
+ if (!program->addShaderFromSourceFile(QGLShader::Fragment, ":/fshader.glsl"))
+ close();
+
+ // Linking shader pipeline
+ if (!program->link())
+ close();
+
+ // Binding shader pipeline for use
+ if (!program->bind())
+ close();
+
+ // Restore system locale
+ setlocale(LC_ALL, "");
+}
+//! [3]
+
+//! [4]
+void MainWidget::initTextures()
+{
+ // Loading cube.png to texture unit 0
+ glActiveTexture(GL_TEXTURE0);
+ glEnable(GL_TEXTURE_2D);
+ texture = bindTexture(QImage(":/cube.png"));
+
+ // Set nearest filtering mode for texture minification
+ glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);
+
+ // Set bilinear filtering mode for texture magnification
+ glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
+
+ // Wrap texture coordinates by repeating
+ // f.ex. texture coordinate (1.1, 1.2) is same as (0.1, 0.2)
+ glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT);
+ glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT);
+}
+//! [4]
+
+//! [5]
+void MainWidget::resizeGL(int w, int h)
+{
+ // Set OpenGL viewport to cover whole widget
+ glViewport(0, 0, w, h);
+
+ // Calculate aspect ratio
+ qreal aspect = (qreal)w / ((qreal)h?h:1);
+
+ // Set near plane to 3.0, far plane to 7.0, field of view 45 degrees
+ const qreal zNear = 3.0, zFar = 7.0, fov = 45.0;
+
+ // Reset projection
+ projection.setToIdentity();
+
+ // Set perspective projection
+ projection.perspective(fov, aspect, zNear, zFar);
+}
+//! [5]
+
+void MainWidget::paintGL()
+{
+ // Clear color and depth buffer
+ glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+
+//! [6]
+ // Calculate model view transformation
+ QMatrix4x4 matrix;
+ matrix.translate(0.0, 0.0, -5.0);
+ matrix.rotate(rotation);
+
+ // Set modelview-projection matrix
+ program->setUniformValue("mvp_matrix", projection * matrix);
+//! [6]
+
+ // Using texture unit 0 which contains cube.png
+ program->setUniformValue("texture", 0);
+
+ // Draw cube geometry
+ geometries->drawCubeGeometry(program);
+}
diff --git a/examples/opengl/cube/mainwidget.h b/examples/opengl/cube/mainwidget.h
new file mode 100644
index 0000000000..595173b65d
--- /dev/null
+++ b/examples/opengl/cube/mainwidget.h
@@ -0,0 +1,53 @@
+#ifndef MAINWIDGET_H
+#define MAINWIDGET_H
+
+#include <QtOpenGL/QGLWidget>
+
+#include <QMatrix4x4>
+#include <QQuaternion>
+#include <QVector2D>
+
+class QBasicTimer;
+class QGLShaderProgram;
+
+class GeometryEngine;
+
+class MainWidget : public QGLWidget
+{
+ Q_OBJECT
+public:
+ explicit MainWidget(QWidget *parent = 0);
+ virtual ~MainWidget();
+
+signals:
+
+public slots:
+
+protected:
+ void mousePressEvent(QMouseEvent *e);
+ void mouseReleaseEvent(QMouseEvent *e);
+ void timerEvent(QTimerEvent *e);
+
+ void initializeGL();
+ void resizeGL(int w, int h);
+ void paintGL();
+
+ void initShaders();
+ void initTextures();
+
+private:
+ QBasicTimer *timer;
+ QGLShaderProgram *program;
+ GeometryEngine *geometries;
+
+ GLuint texture;
+
+ QMatrix4x4 projection;
+
+ QVector2D mousePressPosition;
+ QVector3D rotationAxis;
+ qreal angularSpeed;
+ QQuaternion rotation;
+};
+
+#endif // MAINWIDGET_H
diff --git a/examples/opengl/cube/shaders.qrc b/examples/opengl/cube/shaders.qrc
new file mode 100644
index 0000000000..bfc4b25111
--- /dev/null
+++ b/examples/opengl/cube/shaders.qrc
@@ -0,0 +1,6 @@
+<RCC>
+ <qresource prefix="/">
+ <file>vshader.glsl</file>
+ <file>fshader.glsl</file>
+ </qresource>
+</RCC>
diff --git a/examples/opengl/cube/textures.qrc b/examples/opengl/cube/textures.qrc
new file mode 100644
index 0000000000..fe53be5e64
--- /dev/null
+++ b/examples/opengl/cube/textures.qrc
@@ -0,0 +1,5 @@
+<RCC>
+ <qresource prefix="/">
+ <file>cube.png</file>
+ </qresource>
+</RCC>
diff --git a/examples/opengl/cube/vshader.glsl b/examples/opengl/cube/vshader.glsl
new file mode 100644
index 0000000000..cfdc061852
--- /dev/null
+++ b/examples/opengl/cube/vshader.glsl
@@ -0,0 +1,24 @@
+#ifdef GL_ES
+// Set default precision to medium
+precision mediump int;
+precision mediump float;
+#endif
+
+uniform mat4 mvp_matrix;
+
+attribute vec4 a_position;
+attribute vec2 a_texcoord;
+
+varying vec2 v_texcoord;
+
+//! [0]
+void main()
+{
+ // Calculate vertex position in screen space
+ gl_Position = mvp_matrix * a_position;
+
+ // Pass texture coordinate to fragment shader
+ // Value will be automatically interpolated to fragments inside polygon faces
+ v_texcoord = a_texcoord;
+}
+//! [0]
diff --git a/examples/opengl/framebufferobject/framebufferobject.desktop b/examples/opengl/framebufferobject/framebufferobject.desktop
new file mode 100644
index 0000000000..5858deaabb
--- /dev/null
+++ b/examples/opengl/framebufferobject/framebufferobject.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Name=Framebuffer Object
+Exec=/opt/usr/bin/framebufferobject
+Icon=framebufferobject
+X-Window-Icon=
+X-HildonDesk-ShowInToolbar=true
+X-Osso-Type=application/x-executable
diff --git a/examples/opengl/framebufferobject2/framebufferobject2.desktop b/examples/opengl/framebufferobject2/framebufferobject2.desktop
new file mode 100644
index 0000000000..6aed108ef6
--- /dev/null
+++ b/examples/opengl/framebufferobject2/framebufferobject2.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Name=Framebuffer Object 2
+Exec=/opt/usr/bin/framebufferobject2
+Icon=framebufferobject2
+X-Window-Icon=
+X-HildonDesk-ShowInToolbar=true
+X-Osso-Type=application/x-executable
diff --git a/examples/opengl/framebufferobject2/framebufferobject2.pro b/examples/opengl/framebufferobject2/framebufferobject2.pro
index 2ae20ca4b0..d3fce133fa 100644
--- a/examples/opengl/framebufferobject2/framebufferobject2.pro
+++ b/examples/opengl/framebufferobject2/framebufferobject2.pro
@@ -11,3 +11,8 @@ sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/opengl/framebufferobject2
INSTALLS += target sources
symbian: CONFIG += qt_example
+maemo5: CONFIG += qt_example
+
+symbian: warning(This example might not fully work on Symbian platform)
+maemo5: warning(This example does not work on Maemo platform)
+simulator: warning(This example might not fully work on Simulator platform)
diff --git a/examples/opengl/grabber/grabber.desktop b/examples/opengl/grabber/grabber.desktop
new file mode 100644
index 0000000000..76f31bea5c
--- /dev/null
+++ b/examples/opengl/grabber/grabber.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Name=Grabber
+Exec=/opt/usr/bin/grabber
+Icon=grabber
+X-Window-Icon=
+X-HildonDesk-ShowInToolbar=true
+X-Osso-Type=application/x-executable
diff --git a/examples/opengl/grabber/grabber.pro b/examples/opengl/grabber/grabber.pro
index 7c46cebf52..6a73201cd2 100644
--- a/examples/opengl/grabber/grabber.pro
+++ b/examples/opengl/grabber/grabber.pro
@@ -12,3 +12,8 @@ sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/opengl/grabber
INSTALLS += target sources
symbian: CONFIG += qt_example
+maemo5: CONFIG += qt_example
+
+symbian: warning(This example might not fully work on Symbian platform)
+maemo5: warning(This example does not work on Maemo platform)
+simulator: warning(This example might not fully work on Simulator platform)
diff --git a/examples/opengl/hellogl/hellogl.desktop b/examples/opengl/hellogl/hellogl.desktop
new file mode 100644
index 0000000000..355e259846
--- /dev/null
+++ b/examples/opengl/hellogl/hellogl.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Name=Hello GL
+Exec=/opt/usr/bin/hellogl
+Icon=hellogl
+X-Window-Icon=
+X-HildonDesk-ShowInToolbar=true
+X-Osso-Type=application/x-executable
diff --git a/examples/opengl/hellogl/hellogl.pro b/examples/opengl/hellogl/hellogl.pro
index 067d330d95..82372c5d98 100644
--- a/examples/opengl/hellogl/hellogl.pro
+++ b/examples/opengl/hellogl/hellogl.pro
@@ -17,3 +17,8 @@ sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/opengl/hellogl
INSTALLS += target sources
symbian: CONFIG += qt_example
+maemo5: CONFIG += qt_example
+
+symbian: warning(This example might not fully work on Symbian platform)
+maemo5: warning(This example does not work on Maemo platform)
+simulator: warning(This example might not fully work on Simulator platform)
diff --git a/examples/opengl/hellogl_es/hellogl_es.desktop b/examples/opengl/hellogl_es/hellogl_es.desktop
new file mode 100644
index 0000000000..11c1dd795c
--- /dev/null
+++ b/examples/opengl/hellogl_es/hellogl_es.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Name=Hello GL ES
+Exec=/opt/usr/bin/hellogl_es
+Icon=hellogl_es
+X-Window-Icon=
+X-HildonDesk-ShowInToolbar=true
+X-Osso-Type=application/x-executable
diff --git a/examples/opengl/hellogl_es/hellogl_es.pro b/examples/opengl/hellogl_es/hellogl_es.pro
index 181a90409a..ef0c1cdc3e 100644
--- a/examples/opengl/hellogl_es/hellogl_es.pro
+++ b/examples/opengl/hellogl_es/hellogl_es.pro
@@ -3,7 +3,6 @@
######################################################################
TEMPLATE = app
-TARGET =
DEPENDPATH += .
INCLUDEPATH += .
@@ -25,3 +24,10 @@ target.path = $$[QT_INSTALL_EXAMPLES]/qtbase/opengl/hellogl_es
sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS hellogl_es.pro
sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/opengl/hellogl_es
INSTALLS += target sources
+
+symbian: include($$QT_SOURCE_TREE/examples/symbianpkgrules.pri)
+maemo5: include($$QT_SOURCE_TREE/examples/maemo5pkgrules.pri)
+
+symbian: warning(This example might not fully work on Symbian platform)
+maemo5: warning(This example does not work on Maemo platform)
+simulator: warning(This example might not fully work on Simulator platform)
diff --git a/examples/opengl/hellogl_es2/hellogl_es2.desktop b/examples/opengl/hellogl_es2/hellogl_es2.desktop
new file mode 100644
index 0000000000..2fe0adfc72
--- /dev/null
+++ b/examples/opengl/hellogl_es2/hellogl_es2.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Name=Hello GL ES 2
+Exec=/opt/usr/bin/hellogl_es2
+Icon=hellogl_es2
+X-Window-Icon=
+X-HildonDesk-ShowInToolbar=true
+X-Osso-Type=application/x-executable
diff --git a/examples/opengl/hellogl_es2/hellogl_es2.pro b/examples/opengl/hellogl_es2/hellogl_es2.pro
index 0f48f66233..ac7d3233b6 100644
--- a/examples/opengl/hellogl_es2/hellogl_es2.pro
+++ b/examples/opengl/hellogl_es2/hellogl_es2.pro
@@ -3,7 +3,6 @@
######################################################################
TEMPLATE = app
-TARGET =
DEPENDPATH += .
INCLUDEPATH += .
@@ -25,3 +24,15 @@ target.path = $$[QT_INSTALL_EXAMPLES]/qtbase/opengl/hellogl_es2
sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS hellogl_es2.pro
sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/opengl/hellogl_es2
INSTALLS += target sources
+
+symbian: include($$QT_SOURCE_TREE/examples/symbianpkgrules.pri)
+
+maemo5 {
+ # Debian package name may not contain numbers or special characters
+ # such as '_', lets change this in Maemo.
+ TARGET = helloglestwo
+ include($$QT_SOURCE_TREE/examples/maemo5pkgrules.pri)
+}
+
+symbian: warning(This example might not fully work on Symbian platform)
+simulator: warning(This example might not fully work on Simulator platform)
diff --git a/examples/opengl/opengl.pro b/examples/opengl/opengl.pro
index ae381054a2..59ba7b8bd5 100644
--- a/examples/opengl/opengl.pro
+++ b/examples/opengl/opengl.pro
@@ -12,6 +12,7 @@ contains(QT_CONFIG, opengles1)|contains(QT_CONFIG, opengles2){
}
} else {
SUBDIRS = 2dpainting \
+ cube \
grabber \
hellogl \
overpainting \
@@ -33,3 +34,4 @@ INSTALLS += target sources
symbian: CONFIG += qt_example
QT += widgets
+maemo5: CONFIG += qt_example
diff --git a/examples/opengl/overpainting/overpainting.desktop b/examples/opengl/overpainting/overpainting.desktop
new file mode 100644
index 0000000000..025300b922
--- /dev/null
+++ b/examples/opengl/overpainting/overpainting.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Name=Overpainting
+Exec=/opt/usr/bin/overpainting
+Icon=overpainting
+X-Window-Icon=
+X-HildonDesk-ShowInToolbar=true
+X-Osso-Type=application/x-executable
diff --git a/examples/opengl/overpainting/overpainting.pro b/examples/opengl/overpainting/overpainting.pro
index 8da2a163c5..1584c3c3d4 100644
--- a/examples/opengl/overpainting/overpainting.pro
+++ b/examples/opengl/overpainting/overpainting.pro
@@ -20,4 +20,10 @@ sources.files = $$SOURCES \
sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/opengl/overpainting
INSTALLS += target \
sources
+
symbian:CONFIG += qt_example
+maemo5: CONFIG += qt_example
+
+symbian: warning(This example might not fully work on Symbian platform)
+maemo5: warning(This example does not work on Maemo platform)
+simulator: warning(This example might not fully work on Simulator platform)
diff --git a/examples/opengl/pbuffers/pbuffers.desktop b/examples/opengl/pbuffers/pbuffers.desktop
new file mode 100644
index 0000000000..e5c5cee8c4
--- /dev/null
+++ b/examples/opengl/pbuffers/pbuffers.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Name=Pixel Buffers
+Exec=/opt/usr/bin/pbuffers
+Icon=pbuffers
+X-Window-Icon=
+X-HildonDesk-ShowInToolbar=true
+X-Osso-Type=application/x-executable
diff --git a/examples/opengl/pbuffers/pbuffers.pro b/examples/opengl/pbuffers/pbuffers.pro
index b1ed04acc7..3264be3cef 100644
--- a/examples/opengl/pbuffers/pbuffers.pro
+++ b/examples/opengl/pbuffers/pbuffers.pro
@@ -16,4 +16,10 @@ sources.files = $$SOURCES \
sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/opengl/pbuffers
INSTALLS += target \
sources
+
symbian:CONFIG += qt_example
+maemo5: CONFIG += qt_example
+
+symbian: warning(This example might not fully work on Symbian platform)
+maemo5: warning(This example does not work on Maemo platform)
+simulator: warning(This example might not fully work on Simulator platform)
diff --git a/examples/opengl/pbuffers2/pbuffers2.desktop b/examples/opengl/pbuffers2/pbuffers2.desktop
new file mode 100644
index 0000000000..eed908c661
--- /dev/null
+++ b/examples/opengl/pbuffers2/pbuffers2.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Name=Pixel Buffers 2
+Exec=/opt/usr/bin/pbuffers2
+Icon=pbuffers2
+X-Window-Icon=
+X-HildonDesk-ShowInToolbar=true
+X-Osso-Type=application/x-executable
diff --git a/examples/opengl/pbuffers2/pbuffers2.pro b/examples/opengl/pbuffers2/pbuffers2.pro
index 2e71887c00..9b30d793b8 100644
--- a/examples/opengl/pbuffers2/pbuffers2.pro
+++ b/examples/opengl/pbuffers2/pbuffers2.pro
@@ -3,7 +3,6 @@
######################################################################
TEMPLATE = app
-TARGET =
DEPENDPATH += .
INCLUDEPATH += .
@@ -21,3 +20,8 @@ sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/opengl/pbuffers2
INSTALLS += target sources
symbian: CONFIG += qt_example
+maemo5: CONFIG += qt_example
+
+symbian: warning(This example might not fully work on Symbian platform)
+maemo5: warning(This example does not work on Maemo platform)
+simulator: warning(This example might not fully work on Simulator platform)
diff --git a/examples/opengl/samplebuffers/samplebuffers.desktop b/examples/opengl/samplebuffers/samplebuffers.desktop
new file mode 100644
index 0000000000..d7bd43d95c
--- /dev/null
+++ b/examples/opengl/samplebuffers/samplebuffers.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Name=Sample Buffers
+Exec=/opt/usr/bin/samplebuffers
+Icon=samplebuffers
+X-Window-Icon=
+X-HildonDesk-ShowInToolbar=true
+X-Osso-Type=application/x-executable
diff --git a/examples/opengl/samplebuffers/samplebuffers.pro b/examples/opengl/samplebuffers/samplebuffers.pro
index 8420d431e4..d8f9ff1cd7 100644
--- a/examples/opengl/samplebuffers/samplebuffers.pro
+++ b/examples/opengl/samplebuffers/samplebuffers.pro
@@ -10,3 +10,8 @@ sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/opengl/samplebuffers
INSTALLS += target sources
symbian: CONFIG += qt_example
+maemo5: CONFIG += qt_example
+
+symbian: warning(This example might not fully work on Symbian platform)
+maemo5: warning(This example does not work on Maemo platform)
+simulator: warning(This example might not fully work on Simulator platform)
diff --git a/examples/opengl/textures/textures.desktop b/examples/opengl/textures/textures.desktop
new file mode 100644
index 0000000000..e8a40cdcd5
--- /dev/null
+++ b/examples/opengl/textures/textures.desktop
@@ -0,0 +1,11 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Name=Textures
+Exec=/opt/usr/bin/textures
+Icon=textures
+X-Window-Icon=
+X-HildonDesk-ShowInToolbar=true
+X-Osso-Type=application/x-executable
diff --git a/examples/opengl/textures/textures.pro b/examples/opengl/textures/textures.pro
index e67539a476..d8941b3890 100644
--- a/examples/opengl/textures/textures.pro
+++ b/examples/opengl/textures/textures.pro
@@ -13,3 +13,7 @@ sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/opengl/textures
INSTALLS += target sources
symbian: CONFIG += qt_example
+maemo5: CONFIG += qt_example
+
+symbian: warning(This example might not fully work on Symbian platform)
+simulator: warning(This example might not fully work on Simulator platform)