if i use command ./test -qws blit_setup(): Screen depth 32 not supported! aborted can someone to solve this problem ? thanks
blit_setup() ????
/**************************************************************************** ** ** Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). ** Contact: http://www.qt-project.org/legal ** ** This file is part of the QtGui module of the Qt Toolkit. ** ** $QT_BEGIN_LICENSE:LGPL$ ** Commercial License Usage ** Licensees holding valid commercial Qt licenses may use this file in ** accordance with the commercial license agreement provided with the ** Software or, alternatively, in accordance with the terms contained in ** a written agreement between you and Digia. For licensing terms and ** conditions see http://qt.digia.com/licensing. For further information ** use the contact form at http://qt.digia.com/contact-us. ** ** GNU Lesser General Public License Usage ** Alternatively, this file may be used under the terms of the GNU Lesser ** General Public License version 2.1 as published by the Free Software ** Foundation and appearing in the file LICENSE.LGPL included in the ** packaging of this file. Please review the following information to ** ensure the GNU Lesser General Public License version 2.1 requirements ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. ** ** In addition, as a special exception, Digia gives you certain additional ** rights. These rights are described in the Digia Qt LGPL Exception ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. ** ** GNU General Public License Usage ** Alternatively, this file may be used under the terms of the GNU ** General Public License version 3.0 as published by the Free Software ** Foundation and appearing in the file LICENSE.GPL included in the ** packaging of this file. Please review the following information to ** ensure the GNU General Public License version 3.0 requirements will be ** met: http://www.gnu.org/copyleft/gpl.html. ** ** ** $QT_END_LICENSE$ ** ****************************************************************************/ #include "qscreenlinuxfb_qws.h" #ifndef QT_NO_QWS_LINUXFB //#include "qmemorymanager_qws.h" #include "qwsdisplay_qws.h" #include "qpixmap.h" #include <private/qwssignalhandler_p.h> #include <private/qcore_unix_p.h> // overrides QT_OPEN #include <unistd.h> #include <stdlib.h> #include <sys/ioctl.h> #include <sys/types.h> #include <sys/stat.h> #include <sys/mman.h> #include <sys/kd.h> #include <fcntl.h> #include <errno.h> #include <stdio.h> #include <limits.h> #include <signal.h> #include "qwindowsystem_qws.h" #if !defined(Q_OS_DARWIN) && !defined(Q_OS_FREEBSD) #include <linux/fb.h> #ifdef __i386__ #include <asm/mtrr.h> #endif #endif QT_BEGIN_NAMESPACE extern int qws_client_id; //#define DEBUG_CACHE class QLinuxFbScreenPrivate : public QObject { public: QLinuxFbScreenPrivate(); ~QLinuxFbScreenPrivate(); void openTty(); void closeTty(); int fd; int startupw; int startuph; int startupd; bool blank; QLinuxFbScreen::DriverTypes driverType; bool doGraphicsMode; #ifdef QT_QWS_DEPTH_GENERIC bool doGenericColors; #endif int ttyfd; long oldKdMode; QString ttyDevice; QString displaySpec; }; QLinuxFbScreenPrivate::QLinuxFbScreenPrivate() : fd(-1), blank(true), doGraphicsMode(true), #ifdef QT_QWS_DEPTH_GENERIC doGenericColors(false), #endif ttyfd(-1), oldKdMode(KD_TEXT) { #ifndef QT_NO_QWS_SIGNALHANDLER QWSSignalHandler::instance()->addObject(this); #endif } QLinuxFbScreenPrivate::~QLinuxFbScreenPrivate() { closeTty(); } void QLinuxFbScreenPrivate::openTty() { const char *const devs[] = {"/dev/tty0", "/dev/tty", "/dev/console", 0}; if (ttyDevice.isEmpty()) { for (const char * const *dev = devs; *dev; ++dev) { ttyfd = QT_OPEN(*dev, O_RDWR); if (ttyfd != -1) break; } } else { ttyfd = QT_OPEN(ttyDevice.toAscii().constData(), O_RDWR); } if (ttyfd == -1) return; if (doGraphicsMode) { ioctl(ttyfd, KDGETMODE, &oldKdMode); if (oldKdMode != KD_GRAPHICS) { int ret = ioctl(ttyfd, KDSETMODE, KD_GRAPHICS); if (ret == -1) doGraphicsMode = false; } } // No blankin' screen, no blinkin' cursor!, no cursor! const char termctl[] = "\033[9;0]\033[?33l\033[?25l\033[?1c"; QT_WRITE(ttyfd, termctl, sizeof(termctl)); } void QLinuxFbScreenPrivate::closeTty() { if (ttyfd == -1) return; if (doGraphicsMode) ioctl(ttyfd, KDSETMODE, oldKdMode); // Blankin' screen, blinkin' cursor! const char termctl[] = "\033[9;15]\033[?33h\033[?25h\033[?0c"; QT_WRITE(ttyfd, termctl, sizeof(termctl)); QT_CLOSE(ttyfd); ttyfd = -1; } /*! \enum QLinuxFbScreen::DriverTypes This enum describes the driver type. \value GenericDriver Generic Linux framebuffer driver \value EInk8Track e-Ink framebuffer driver using the 8Track chipset */ /*! \fn QLinuxFbScreen::fixupScreenInfo(fb_fix_screeninfo &finfo, fb_var_screeninfo &vinfo) Adjust the values returned by the framebuffer driver, to work around driver bugs or nonstandard behavior in certain drivers. \a finfo and \a vinfo specify the fixed and variable screen info returned by the driver. */ void QLinuxFbScreen::fixupScreenInfo(fb_fix_screeninfo &finfo, fb_var_screeninfo &vinfo) { // 8Track e-ink devices (as found in Sony PRS-505) lie // about their bit depth -- they claim they're 1 bit per // pixel while the only supported mode is 8 bit per pixel // grayscale. // Caused by this, they also miscalculate their line length. if(!strcmp(finfo.id, "8TRACKFB") && vinfo.bits_per_pixel == 1) { vinfo.bits_per_pixel = 8; finfo.line_length = vinfo.xres; } } /*! \internal \class QLinuxFbScreen \ingroup qws \brief The QLinuxFbScreen class implements a screen driver for the Linux framebuffer. Note that this class is only available in \l{Qt for Embedded Linux}. Custom screen drivers can be added by subclassing the QScreenDriverPlugin class, using the QScreenDriverFactory class to dynamically load the driver into the application, but there should only be one screen object per application. The QLinuxFbScreen class provides the cache() function allocating off-screen graphics memory, and the complementary uncache() function releasing the allocated memory. The latter function will first sync the graphics card to ensure the memory isn't still being used by a command in the graphics card FIFO queue. The deleteEntry() function deletes the given memory block without such synchronization. Given the screen instance and client id, the memory can also be released using the clearCache() function, but this should only be necessary if a client exits abnormally. In addition, when in paletted graphics modes, the set() function provides the possibility of setting a specified color index to a given RGB value. The QLinuxFbScreen class also acts as a factory for the unaccelerated screen cursor and the unaccelerated raster-based implementation of QPaintEngine (\c QRasterPaintEngine); accelerated drivers for Linux should derive from this class. \sa QScreen, QScreenDriverPlugin, {Running Applications} */ /*! \fn bool QLinuxFbScreen::useOffscreen() \internal */ // Unaccelerated screen/driver setup. Can be overridden by accelerated // drivers /*! \fn QLinuxFbScreen::QLinuxFbScreen(int displayId) Constructs a QLinuxFbScreen object. The \a displayId argument identifies the Qt for Embedded Linux server to connect to. */ QLinuxFbScreen::QLinuxFbScreen(int display_id) : QScreen(display_id, LinuxFBClass), d_ptr(new QLinuxFbScreenPrivate) { canaccel=false; clearCacheFunc = &clearCache; #ifdef QT_QWS_CLIENTBLIT setSupportsBlitInClients(true); #endif } /*! Destroys this QLinuxFbScreen object. */ QLinuxFbScreen::~QLinuxFbScreen() { #ifdef QT_NO_QWS_SIGNALHANDLER delete d_ptr; #endif } /*! \reimp This is called by \l{Qt for Embedded Linux} clients to map in the framebuffer. It should be reimplemented by accelerated drivers to map in graphics card registers; those drivers should then call this function in order to set up offscreen memory management. The device is specified in \a displaySpec; e.g. "/dev/fb". \sa disconnect() */ bool QLinuxFbScreen::connect(const QString &displaySpec) { d_ptr->displaySpec = displaySpec; const QStringList args = displaySpec.split(QLatin1Char(':')); if (args.contains(QLatin1String("nographicsmodeswitch"))) d_ptr->doGraphicsMode = false; #ifdef QT_QWS_DEPTH_GENERIC if (args.contains(QLatin1String("genericcolors"))) d_ptr->doGenericColors = true; #endif QRegExp ttyRegExp(QLatin1String("tty=(.*)")); if (args.indexOf(ttyRegExp) != -1) d_ptr->ttyDevice = ttyRegExp.cap(1); #if Q_BYTE_ORDER == Q_BIG_ENDIAN #ifndef QT_QWS_FRAMEBUFFER_LITTLE_ENDIAN if (args.contains(QLatin1String("littleendian"))) #endif QScreen::setFrameBufferLittleEndian(true); #endif QString dev = QLatin1String("/dev/fb0"); foreach(QString d, args) { if (d.startsWith(QLatin1Char('/'))) { dev = d; break; } } if (access(dev.toLati...stripped-down
> what must i change in qscreenlinuxfb_qws.cpp No idea. I would try to figure out why you get your first error message. What device are you trying run this on? Maybe look into framebuffer details and/or touchscreen/touchscreen driver details to find out which screen depths are supported. Have you got a ts.conf in /etc ? What does it say?
i using friendlyarm tiny4412 ok i try to find framebuffer and touchscreen driver details to find out screen depth supported ts.conf module_raw friendlyarm-ts-input module pthres pmin=30 module variance delta=30 module dejitter delta=10000 module linier ~ ~ ~ ~
... module linear http://manpages.ubuntu.com/manpages/utopic/man5/ts.conf.5.html Doesn't seem to help Can you look through the source code for blit_setup() and see what triggers this warning message. Maybe, that will tell you where it is looking for this information. Command: fbset Ah ... NOTE: fbset cannot be used to change display resolution or colour depth. Depending on the framebuffer device different kernel command line may be needed to do this. Please refer to your display driver manual for details. From: OSELAS.BSP-Pengutronix-Mini2440-Quickstart.pdf Looks like it might be in kernelconfig, had a quick look and couldn't find it.
I don't know the kernel for the tiny4412. Most framebuffer drivers for such devices are fixed to one colour depth. To get a different colour depth you need to change the kernel driver to let it program the LCD controller differently. For the Mini2440 I made these kind of changes to its LCD controller driver.
davef i reconfigured my qt and i run ./test -qws blit_setup(): Screen depth 32 not supported! aborted not show agaain but now transformed: drifer not found aborted now i try to solving this problem if you know to solving this problem please post thanks
Explain how you fixed the original problem, then others might learn from your efforts. I think you mean transformed: driver not found Dropping your error message into Google gives lots of hits and this one looks quite relevant http://www.qtforum.org/article/36051/how-run-a-qt-program-on-qtopia-arm-...
./test -qws blit_setup(): Screen depth 32 not supported! aborted SOLVED reconfigure qt4.8.6 using ./configure -depth all davef ok i'll try to solve this problem thanks a lot if i solve problem "transformed: driver not found" i'll post how to solving the problem thanks