Eugene Sandulenko
3851c2d9a6
GRAPHICS: Added source transparency parameter to ManagedSurface::transBlit
2019-09-03 17:17:14 +02:00
Eugene Sandulenko
14f8e0574f
GRAPHICS: Fix Managed Surface alpha blending
2019-09-03 17:17:14 +02:00
sluicebox
60fcf993e7
GRAPHICS: Display Mac monochrome cursor inverted pixels
...
Bug #7050
2019-08-21 14:13:26 +03:00
D G Turner
d78459f8bc
GUI: Fix GCC Compiler Warnings in GUI Theme Parser Code
...
This removes the usage of memset to clear complex structures and replaces
them with constructor methods for the structures which will be executed
when these are instantiated.
2019-08-17 05:03:04 +01:00
Cameron Cawley
92a3a3a8a5
GRAPHICS: MACGUI: Allow loading menus from resource forks
2019-08-11 22:27:11 +03:00
Cameron Cawley
9052a16887
GRAPHICS: MACGUI: Use Common::String for addMenuItem and addMenuSubItem
2019-08-10 14:50:33 +01:00
Cameron Cawley
1632fba91e
GRAPHICS: MACGUI: Don't hide the menu bar if kWMModeAutohideMenu is not enabled
2019-08-10 13:08:15 +01:00
Cameron Cawley
fe5dddf901
GRAPHICS: Add a version of CursorManager::replaceCursor that accepts a Graphics::Cursor
2019-08-09 23:58:32 +03:00
Thanasis Antoniou
4630895ccc
COMMON: Explain new params for wordWrapText()
2019-08-02 00:08:38 +02:00
Thanasis Antoniou
1bca3de594
COMMON: Support text wrapping with even width line segments
...
The new arguments are optional. The lines segments will be close to the same width.
The algorithm is similar to the one we had for Blade Runner but not exactly the same, since that one would wrap a line at a white space after the theoretical split point (quotient of full line text width divided by target lines number)
2019-08-02 00:08:38 +02:00
SupSuper
1669ef6244
GRAPHICS: Fix ManagedSurface transBlitFrom ignoring flipped parameter
2019-07-14 00:46:30 +02:00
SupSuper
176109da59
GRAPHICS: Fix wrong rect size when blitting subsurface to ManagedSurface
...
We want the srcRect size and not the original surface size
2019-07-14 00:46:30 +02:00
Le Philousophe
3a7219fa57
JANITORIAL: Avoid C4121 warnings in MSVC by reordering fields
...
C4121 is about 'symbol': alignment of a member was sensitive to packing
2019-06-30 21:43:58 +03:00
lolbot-iichan
c4dc251f2b
GRAPHICS: Fix fully transparent pixel blit
...
In BLEND_NORMAL mode with color != 0xffffffff, blending fully
transparent pixel was resulted in slightly modifying some background
colors, because old value X was a bit different from new value (X*255>>8).
This fixes defect #10686 WME: Sprite background is not fully transparent
if AlphaColor is set
2019-06-24 11:27:44 +03:00
Le Philousophe
ed34a41810
GRAPHICS: Fix rects handling in ManagedSurface::copyFrom
...
Like in create(), when using copyFrom the whole surface gets new data
and is now completely dirty so let's use markAllDirty.
2019-06-09 14:38:31 -07:00
Le Philousophe
1297ae2b76
GRAPHICS: Fix ManagedSurface::copyFrom memory handling
...
When calling ManagedSurface::copyFrom, _disposeAfterUse should be set to
YES because inner surface frees up old pixels array and creates a new one.
2019-06-09 14:38:31 -07:00
Filippos Karapetis
7346b69d88
GRAPHICS: Initialize potentially uninitialized variables
2019-05-27 14:53:46 +03:00
Cameron Cawley
8c2b09d919
COMMON: Replace NEResourceType and PEResourceType with a shared enum
2019-05-01 23:52:56 +03:00
Bastien Bouclet
6a231e4b60
GRAPHICS: Look for fonts.dat in extrapath
...
When running from the source tree, it is convenient to have extrapath
set to dists/engine-data, where fonts.dat is located.
2019-05-01 05:50:08 +02:00
Bastien Bouclet
0d5d04ca3a
IMAGE: Allow setting the output pixel format to the JPEG decoder
2019-04-28 07:59:14 +02:00
Daniel
903569cab8
GRAPHICS: Fix ManagedSurface dirty rects when drawing lines
...
Fixes an invalidRect assert when drawing lines which don't go from top-left to bottom-right.
2019-04-26 13:08:38 +03:00
Johannes Schickel
3d469682fc
GRAPHICS: Add a PixelType to ColorMasks.
...
This PixelType is the underlying type (uint16/uint32) of a pixel specified by
ColorMasks.
2019-04-01 00:29:23 +03:00
Eric Culp
627fbaf8a0
GRAPHICS: Return value in dummy functions
2019-04-01 00:29:23 +03:00
Eric Culp
c666ecd41d
GRAPHICS: Respect alpha and rgba formats in interpolation and conversion
2019-04-01 00:29:23 +03:00
Eric Culp
c2ddab7dd2
GRAPHICS: Fix braces in two interpolate functions
2019-04-01 00:29:23 +03:00
Eric Culp
e3357083d7
GRAPHICS: Change another interpolation function in Edge filter.
...
A 2 to 1 interpolation was causing errors. It is fixed, renamed, and
moved to the common interpolation file.
2019-04-01 00:29:23 +03:00
Eric Culp
0246ca8da0
GRAPHICS: Change Edge filter to use shared interpolation functions
2019-04-01 00:29:23 +03:00
Eric Culp
3d57c13af0
GRAPHICS: Add dummy specializations for some interpolate* functions
...
They use ColorMask values not present in 2-byte ColorMasks. Since they
should never be used on 2-byte pixel data, the dummy implementations
assert(0) and should be removed by any optimizing compiler since no
code path can ever reach them.
2019-04-01 00:29:23 +03:00
Eric Culp
c6ee138b74
GRAPHICS: Fix typo of qlowBits
2019-04-01 00:29:23 +03:00
Eric Culp
2215e0cb51
GRAPHICS: Add 32bit versions of interpolate* functions
2019-04-01 00:29:23 +03:00
Thanasis Antoniou
672d216d11
GUI: Fix loading new (not already cached) localized fonts
2019-03-12 00:42:58 +02:00
Lothar Serra Mari
fe83c985be
GUI: Allow GUI background colors other than black in Classic Theme ( #1526 )
...
GUI: Allow GUI background colors other than black in Classic Theme
2019-03-10 16:56:17 +02:00
Cameron Cawley
07834616b3
GRAPHICS: Fix dstFormat check in Surface::convertTo
2019-03-03 13:44:53 +01:00
Cameron Cawley
fd1162cb71
GRAPHICS: Support converting to 3Bpp surfaces
2019-03-02 07:29:22 +01:00
Cameron Cawley
fa60ae728e
GRAPHICS: Add a function to load TrueType fonts from fonts.dat
2018-12-25 12:47:42 +01:00
Cameron Cawley
2097c33b57
GRAPHICS: MACGUI: Make use of Common::String::format ( #1454 )
2018-12-23 15:57:20 +02:00
Paul Gilbert
e232d024c5
GLK: Standardizing uint vs uint32 usage
2018-12-09 14:47:15 -08:00
Paul Gilbert
3e8ed4eafc
GRAPHICS: Add convertToInPlace method to ManagedSurface
2018-12-08 19:05:59 -08:00
Paul Gilbert
e5b73b2899
GRAPHICS: Add deltax optional parameter to Font drawString U32String version
2018-11-14 19:00:17 -08:00
athrxx
e4e5e68f0d
KYRA: implement SJIS features required for EOB II FM-Towns
...
- low res font drawing for intro and outro texts
- fat print mode for ingame texts
2018-11-14 17:22:20 +01:00
Thierry Crozat
3b542cea53
SURFACESDL: Respect filtering setting when performing aspect ratio correction
2018-10-24 23:34:41 +02:00
David Fioramonti
a66e661df1
GRAPHICS: Simplify trig usage in primitives
...
Combined if statements and simplified trig.
cos(atan2(y,x)) = x / sqrt(x^2 + y^2) and
sin(atan2(y,x)) = y / sqrt(x^2 + y^2).
2018-09-08 16:36:57 -07:00
Cameron Cawley
7a437e909c
COMMON: Move new_strdup to common/str.cpp
2018-08-18 16:30:05 +02:00
Colin Snover
f7e05a6ace
GRAPHICS: Fix incorrect maximum length passed to strlcpy
2018-08-18 16:30:05 +02:00
Colin Snover
c544d8050c
GRAPHICS: Remove use of nonstandard strdup API & fix mismatched malloc/delete
2018-08-18 16:30:05 +02:00
Paul Gilbert
11e33ba3fc
JANITORIAL: Removing trailing spaces after int casts
2018-08-17 20:30:20 -07:00
Andrei Prykhodko
bb995bc871
GRAPHICS: MACGUI: fixed mem leak in MacText
2018-08-05 23:07:55 +03:00
Bastien Bouclet
7362060c47
GRAPHICS: Improve check to test if text fits in the target surface
...
When rendering text, especially truetype fonts, we would use the next
character avance metric to check if the character fits in the target
surface. This commit changes it to use the bounding box metric. The
bounding box represents the actual pixels that will be touched when
drawing the character.
This fixes an issue noticed on the main menu of Myst ME where the last
character of the string "OPTIONEN" would not be rendered despite there
being enough room to render it. More precisely, this ensures that
calling Font::getBoundingBox for a string, and then passing a surface
exactly the size of the returned bounding box to the draw function
actually renders all the characters.
2018-08-03 22:35:16 +02:00
David Fioramonti
bafe22c782
GRAPHICS: Set thumbnail to nullptr when loading the thumbnail is skipped
...
Since Graphics::loadThumbnail can return successfully when a thumbnail is skipped
the caller may want to check to the see that the thumbnail is not null before using
it. Setting it to null is just defensive in case the caller didn't do so.
If the user tries to use the thumbnail in setThumbnail then it will just
show a black screen for the thumbnail rather than crashing if they have
not set the thumbnail to null.
2018-08-03 14:51:12 +02:00
Ľubomír Remák
d9b3853dec
COMMON: Fix kerning issue in wordWrapText.
2018-08-02 18:54:13 +02:00