| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
| |
OpenVG paint engine tries to use vgWritePixels shortcut
whenever possible to optimize rendering performance. The
check 'canVgWritePixels' failed to map formats correctly
and resulted to incorrect return value.
Task-number: QTBUG-18682
Reviewed-by: Jason Barron
|
|
|
|
|
|
|
|
|
| |
The special case of creating a pixmap from RSgImage via a native
handle provider needs extra attention when hibernating: In this case
the hibernating happens as usual, however doing a readback would
produce unwanted results and must be avoided.
Reviewed-by: Jani Hautakangas
|
|
|
|
|
|
|
|
|
|
|
|
| |
The vgWritePixel-based "fallback" in drawImage can only be used when
the transformation is simple and no opacity is set. The tiled drawing
introduced here will serve as an additional fallback for the more
complex cases and will allow drawing large (12 Mpix or more) pixmaps
and images with transformation and semi-transparency even when the
complete image data would not fit into the GPU memory.
Task-number: QTBUG-18251
Reviewed-by: Jani Hautakangas
|
|
|
|
|
|
|
|
|
| |
QVGPaintEngine did not have proper checks for null QImage in the
drawImage functions so it went on trying to create a VGImage of
size 0x0 which is bound to fail always. This resulted in confusing
warnings about not being able to reclaim space for 0x0 images.
Reviewed-by: Jani Hautakangas
|
|
|
|
|
|
|
|
|
| |
Forcing VG (and GL) pixmapdata to support toNativeType() with type
VolatileImage is unnecessary. It is cleaner to try doing a
fromNativeType() with bitmap+mask and fall back if that results in
a null pixmapdata.
Reviewed-by: Jani Hautakangas
|
|
|
|
| |
Reviewed-by: Jani Hautakangas
|
|
|
|
|
|
|
|
|
| |
OpenVG paint engine didn't reset it's
mask fallback state correctly when engine
was resetted.
Task-number: QTBUG-17966
Reviewed-by: Jason Barron
|
|
|
|
|
|
|
|
|
|
|
| |
Inverting the pixels for bitmaps of mode EGray2 is done in-place,
which is wrong if the bitmap handle was duplicated. Instead, we
need to make a copy. This also means that we cannot treat EGray2
a conversion-less format in openvg, but such images are likely
to be used as masks only, so optimizing just for mere drawing
in case of this format is not really necessary.
Reviewed-by: Jani Hautakangas
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
From now on the image data coming from CFbsBitmap will not be forced
to RGB32 or ARGB32_Premultiplied in openvg. This allows copy-less
creation and drawing of pixmaps not just from bitmaps with display mode
EColor16MAP and EColor16MU, but also a few other modes, like EColor64K.
Painting into such pixmaps or drawing them via the raster engine is
potentially slower in such cases, which is now reflected in the
fromSymbianCFbsBitmap documentation.
Note that this patch has no effect on extended bitmaps (e.g. skin
graphics), those must always be rasterized first regardless of the
display mode.
Task-number: QTBUG-18027
Reviewed-by: Jani Hautakangas
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
QNativeImageHandleProvider is a thin interface consisting of get()
and release() functions. Pixmaps constructed with such a provider
will call these functions to acquire and release a native handle,
e.g. a CFbsBitmap or RSgImage pointer in case of Symbian. The behavior
is largely similar to constructing pixmaps via fromSymbianCFbsBitmap
or fromSymbianRSgImage, with the exception of pixmap hibernation:
release() (and subsequently get()) is guaranteed to be called also
in case of hibernation, allowing more fine-grained tracking of
the usage and lifetime of image data.
Task-number: QT-4632
Reviewed-by: Jani Hautakangas
|
|
|
|
| |
Reviewed-by: TRUSTME
|
|
|
|
|
|
|
|
|
|
|
| |
Enable readback of pixel data for pixmaps that are constructed directly
from a VGImage. These do not have any backing data in main memory
(i.e. 'source' is null), however certain operations, like toImage(),
fill(), or painting into the pixmap do not work without it. With this
patch the data is read back via vgGetImageSubData when needed.
Task-number: QT-4669
Reviewed-by: Jani Hautakangas
|
|
|
|
| |
Reviewed-by: TRUSTME
|
|
|
|
|
| |
Task-number: QTBUG-17849
Reviewed-by: Samuel Rødal
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Similarly to QS60PixmapData, that is used on raster, QVGPixmapData
is also backed by a CFbsBitmap from now on (at least when it makes
sense to do so). This allows copy-less bitmap handle duplication in
from- and toSymbianCFbsBitmap() in case of certain image formats,
reduces local heap usage and improves performance with the s60 style
due to a reduced number of pixel data copies.
Task-number: QT-2505
Reviewed-by: Jason Barron
Reviewed-by: Jani Hautakangas
|
|
|
|
|
|
| |
Changed a system include to local one.
Reviewed-by: Jason Barron
|
|
|
|
|
|
|
|
|
|
| |
OpenVG implementation for Broadcom chip has limited scissor rect
count to 32. Because of that Qt OpenVG paint engine fails to clip
correctly if clip rect count exceeds 32. This patch makes Qt
OpenVG paint engine to use mask instead of scissors in such cases.
Task-number: QTBUG-16932
Reviewed-by: Jason Barron
|
|
|
|
|
|
|
|
| |
The retrieved VGImage handle was accidentally assigned to a local
variable instead of the member with the same name so it always
ended up creating an empty pixmap.
Reviewed-by: Jani Hautakangas
|
|
|
|
|
|
|
|
|
| |
Shape should not be filled using pen if pen brush
type is NoBrush. OpenVG paint engine didn't check
NoBrush case when applying pen.
Task-number: QTBUG-15870
Reviewed-by: Gunnar
|
|
|
|
|
|
|
|
|
|
|
|
| |
QImage::converToFormat(format) won't detach QImage if
format stays the same. Because of this, internal QImage
buffer of QVGPixmapData was not deep copied. Drawing
to QPixmap target modified the original QImage that was
used to create QPixmap and in some cases crashed because
paint engine referred to wrong target.
Task-number: QT-4407
Reviewed-by: Jason Barron
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Q_DECL_IMPORT is still __declspec(dllimport), which is unsuitable for
static code.
Commit edbc656b changed Q_DECL_IMPORT_IMPORT to Q_CORE_EXPORT when
declaring QtCore functions in svg.
Now we change Q_DECL_IMPORT to Q_GUI_EXPORT when declaring QtGui
functions into opengl and openvg.
Also removed the redundant keyword "extern" from the function declarations.
Merge-request: 2540
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: mariusSO
|
|
|
|
|
|
|
|
| |
Solution is to round adjustment offsets to integer values to prevent
blurry text.
Task-number: QTBUG-16240
Reviewed-by: Alessandro Portale
|
|
|
|
| |
Reviewed-by: Trust Me
|
|
|
|
|
|
|
|
|
|
| |
QWidget uses QPainter::drawTiledPixmap to draw textured
background brush but OpenVG paint engine fails to
render pixmaps correctly because of incorrect offset
calculation.
Task-number: QTBUG-15737
Reviewed-by: Gunnar Sletta
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/qt-s60-public: (27 commits)
Use parent class function to generate Makefile headers in Symbian
Fix spaces
Fix QPixmap::fromImage() in the OpenVG pixmap backend.
Native color dialog on symbian
Fix non-stroked filled paths in OpenVG paint engine.
Fix symbian-mmp.conf include path
Fix a build break when namespace is defined
Fixed namespace issues related to epocroot.cpp
Corrected ASCII comparison and removed extra braces
Add symbian scope for qfiledialog_symbian.cpp
Resolve EPOCROOT in qt.conf using same logic as in .pro
Make epocroot resolving compatible with more build environments
Fix for QtOpenGL RVCT4 compilation error
Removed extra cpp and done changes based on comments
Correct flags for Symbian file dialogs
Fix for WServ 64 crash on Symbian.
Use include(original mkspec) instead of copying of mkspec to default
Fixed code style of d92cbfc5, reported by git push.
Switched qdesktopservices to use SchemeHandler for Symbian^3 and later.
Removed unnecessary Q_OS_SYMBIAN flags from qdesktopservices_s60.cpp.
...
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
If QPixmap::fromImage() was called with a QImage that has an alpha
channel and with the 'Qt::NoOpaqueDetection' image conversion flag set,
then we would always create an opaque (RGB32) pixmap. This is
incorrect.
The fix is to check if the source QImage has an alpha channel and if
so, use sourceFormat(), otherwise use RGB32.
Task-number: QT-4278
Reviewed-by: Jani Hautakangas
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The QPainter::fillRect() functions are optimizations to avoid state
changes in the paint engines. Since these functions should be
completely independant of state, ideally they should only call
functions that are also stateless.
QVGPaintEngine::fillRect() has two different code paths for this.
The vgClearRect() path of this function is stateless however in the
case of non-opaque or complex fills, this code path cannot be used and
instead we use the normal path fill function which is not entirely
stateless because ensureTransform() will apply the aliased coordinate
transform if the current state includes a stroked pen.
To avoid this happening for a pure fill (no stroke) we temporary set
the pen state to be Qt::NoPen such that the state used by
ensureTransform() is correct.
Task-number: QTBUG-14717
Reviewed-by: Jani Hautakangas
|
|/
|
|
|
|
|
|
|
|
| |
The origin of text needs to be rounded, just like the translation in
the transform because text drawn at subpixel positions is unsupported
on some devices. Since the font is integer-based, the advance-array
does not need to be rounded.
Task-number: QTBUG-15263
Reviewed-by: Jason Barron
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
Doc: Fixing typo
Fix QTBUG-14640:oci performance problem with qlonglong
32bit => 16bit conversion has 4byte-aligned output.
Fix gcc bug in qReallocAligned
Prevented threading related crash in OpenGL module.
Fix possible crash in QStaticText and QDeclarativeTextLayout
Fix QTBUG-14132 oracle (xe) stored procedures with bind variables get errors
|
| |\
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
32bit => 16bit conversion has 4byte-aligned output.
Fix gcc bug in qReallocAligned
Prevented threading related crash in OpenGL module.
Fix possible crash in QStaticText and QDeclarativeTextLayout
Fix QTBUG-14132 oracle (xe) stored procedures with bind variables get errors
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The QStaticTextItem held an uncounted reference to QFontEngine. The
pointer would dangle in some cases where there was no font object
referencing the engine and the cache was cleaned out (e.g. when a
new application font is added.) Properly count the reference, and also
add reference counting to userData to make it harder to shoot yourself
in the foot, since the QStaticTextItem class is now being used in
different places,
Task-number: QTBUG-14446
Reviewed-by: Martin Jones
|
|/ /
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When the state is restored and the 'dirty' flag indicates that the clip
state has changed, the paint engine needs to set 'scissorDirty' flag to
true so that updateScissor() applies the restored clip region to the
scissor rects.
Task-number: QTBUG-14907
Reviewed-by: Jani Hautakangas
|
| |
| |
| |
| |
| |
| |
| | |
Functions were accidentally thought to be in private scope.
Renaming broke BC.
Reviewed-by: Jason Barron
|
|/
|
|
|
|
|
|
|
|
| |
Use vgWritePixels, if possible, in case where VGImage
for QPixmap can't be allocated due to low GPU memory
situation. This patch also renames some VG paint engine
internal functions to clarify their purpose.
Task-number: QT-3589
Reviewed-by: Jason Barron
|
|
|
|
|
|
|
|
|
|
| |
Symbian bitmap formats may have different scanline length
when compared to QImage formats. We need to define scanline
length for intermediate QImage when converting from CFbsBitmap
to QPixmap.
Task-number: QTBUG-14218
Reviewed-by: Jason Barron
|
|
|
|
|
|
| |
ShivaVG doesn't have VGFont support for example.
Reviewed-by: Jason Barron
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In the cases where an error occured while converting a QPixmap to a
VGImage this function would return without deleting the RSgImage
pointer that it created. Fix is to use a QScopedPointer instead. Also
don't use q_check_ptr() since this isn't a CBase derived class.
In case you are wondering why I didn't use a custom deleter here so
that Close() was also called, we need to make sure that Close() is
called on the RSgImage instance before calling Close() on the driver.
Reviewed-by: mread
|
|
|
|
|
|
|
|
| |
Calling eglGetError() is expensive so we should avoid doing it unless
we know there actually is an error. The function returns EGL_FALSE upon
error so we can test for that instead of using eglGetError().
Reviewed-by: Jani Hautakangas
|
|
|
|
|
|
|
|
|
|
|
| |
I avoided adding this flag for ages since I wasn't convinced that it
was needed on all Symbian OpenVG hardware, but not having it has caused
more problems since people report problems when it is not enabled.
Simple solution is just to add it.
Task-number: QTBUG-11311
Reviewed-by: Jani Hautakangas
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
pixel."
This reverts commit 2acdc634ee895af4a9738c0f6c2496e388afba38.
Originally this fixed QT-3791 but it caused lots of problems in
other sites. So reverting this will fix QT-4001 but reopens
QT-3791. QT-4001 blocks Qt 4.7.1 but QT-3791 doesn't.
Task-number: QT-4001
Reviewed-by: Jason Barron
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Stroking a path can sometimes result in inconsistent rendering
especially when combined with a clip. For example, if the logical edge
of a clip rect coincides with the logical edge of a path then it can
happen that the edge is not painted correctly because the stroke lies
outside the bounds of the clip rect. To workaround this problem, we add
the 'aliasedCoordinateDelta' such that the rounding will err on the
side of caution. This improves the correctness when using the raster
engine as a reference.
Task-number: QTBUG-13165
Reviewed-by: Samuel
|
|\
| |
| |
| |
| |
| |
| |
| |
| | |
4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
QGraphicsWidget update issues with ItemHasNoContents + effect
Fixed missing background for regular Qt applications with MeeGo system.
Fix top-left corner of rounded rects in QPaintEngineEx
|
| |
| |
| |
| | |
Reviewed-by: Rhys Weatherley
|
|/
|
|
|
|
|
|
|
|
|
| |
Calling the various Khronos getError() functions here is inefficient
since it involves a round trip to the GPU and gains nothing since the
null handle can be used to test for error conditions at no cost. Also
no need to open the RSgDriver because we don't actually need to call
any functions on RSgImage, just convert it.
Reviewed-by: Alessandro Portale
Reviewed-by: Jani Hautakangas
|
|
|
|
|
|
|
|
|
|
| |
This happens because of differences in OpenVG and Qt pixel center point
handling. Currently there is no easy generic way to adjust Qt pixels to
match OpenVG. This patch adjusts pixels for simple affine transformations
by rounding them.
Task-number: QT-3791
Reviewed-by: Jason Barron
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The reclaimSpace() function of the VG image pool was crashing when
attempting to free up space for a large image. It was calling
moveToHeadOfLRU() which adds the image to the pool. If the pixmap is
large enough so that it pushes all the others out, then it will be the
only pixmap left in the pool when this function returns. This is
problematic because this pixmap is not permanent so it could be
deleted. If that happens, then subsequent calls to this function will
crash because the LRU pixmap has been deleted.
The fix is to check if the pixmap was in the pool to begin with and
if not, then be sure to remove it before returning from this function.
Task-number: QT-3652
Reviewed-by: Jani Hautakangas
|
|
|
|
|
|
|
| |
QImage 'convertInPlace' uses less memory than 'convertToFormat' version.
Task-number: QT-3710
Reviewed-by: Jason Barron
|
|\
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
src/gui/kernel/qt_s60_p.h
src/opengl/qglextensions.cpp
src/opengl/qglshaderprogram.cpp
tests/auto/mediaobject/tst_mediaobject.cpp
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Commit b0bbabe728fedb8531fc2837403856bd5ed44e1b fixed text blurriness
in the OpenVG paint engine by forcing the coordinates of the text
items to integer coordinates (for unrotated, unscaled text).
That was not yet enough. In addition to the coordinates, also the
d->pathTransform in QVGPaintEngine can have a non-integer translation.
This patch makes sure that the text item coordinate combined with the
translation result in final integer coordinates.
Since it is not possible to set an absolute translation of a
QTransform (only relative is possible), first dx() is added to p.x(),
then after rounding, it is again substracted. Sam for y, but with
opposite prefix, since the y-axis in Qt and in transformation
matrices are in opposite directions.
The ceil stunt (which I cerated by trial and error) was replaced
by floor(x + aliasedCoordinateDelta), which *exactly* what other
paint engines do.
Task-number: QTBUG-12330
Reviewed-by: Jason Barron
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Proxy widgets use the shared painter functionality and this implies
that the paint engine's begin function does not get called for each new
widget that gets painted. This causes a problem because the system clip
gets modified by QPainter, but the paint engine does not realize that
this happened and fails to use the new clip. The result is that you can
end up painting outside the intended clip area.
The fix is to reimplement the virtual systemStateChanged() function in
QVGPaintEnginePrivate and make it call updateScissor() to re-evaluate
the clipping flags and update the current clip accordingly.
A similar fix was done to the OpenGL paint engine way back in 307c2954.
Task-number: QTBUG-12486
Reviewed-by: Rhys Weatherley
|