diff options
| author | Felix Domke <felix.domke@multimedia-labs.de> | 2009-07-16 23:41:44 +0200 |
|---|---|---|
| committer | Felix Domke <felix.domke@multimedia-labs.de> | 2009-07-16 23:41:44 +0200 |
| commit | ff69eecfab66bbfa534d8a766c001c79a13ac90e (patch) | |
| tree | d2782469f569d7518ab09123f6d85cd6bcb37719 /lib/gui | |
| parent | 1d7fa5b269b7baf14d1718787acbaee70eda3391 (diff) | |
| download | enigma2-ff69eecfab66bbfa534d8a766c001c79a13ac90e.tar.gz enigma2-ff69eecfab66bbfa534d8a766c001c79a13ac90e.zip | |
properly scale change regions
Diffstat (limited to 'lib/gui')
| -rw-r--r-- | lib/gui/esubtitle.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/gui/esubtitle.cpp b/lib/gui/esubtitle.cpp index f3d0e35f..5cf4cfa2 100644 --- a/lib/gui/esubtitle.cpp +++ b/lib/gui/esubtitle.cpp @@ -115,8 +115,12 @@ void eSubtitleWidget::clearPage() void eSubtitleWidget::setPixmap(ePtr<gPixmap> &pixmap, gRegion changed, eRect pixmap_dest) { m_pixmap = pixmap; - m_pixmap_dest = pixmap_dest; + m_pixmap_dest = pixmap_dest; /* this is in a virtual 720x576 cage */ + /* incoming "changed" regions are relative to the physical pixmap area, so they have to be scaled to the virtual pixmap area, then to the screen */ + changed.scale(m_pixmap_dest.width(), 720, m_pixmap_dest.height(), 576); + changed.moveBy(ePoint(m_pixmap_dest.x(), m_pixmap_dest.y())); + changed.scale(size().width(), pixmap->size().width(), size().height(), pixmap->size().height()); invalidate(changed); |
