summaryrefslogtreecommitdiff
path: root/amiga/plotters.c
diff options
context:
space:
mode:
authorChris Young <chris@unsatisfactorysoftware.co.uk>2015-03-01 11:48:21 +0000
committerChris Young <chris@unsatisfactorysoftware.co.uk>2015-03-01 11:50:20 +0000
commitdb9144230426e9dfa0203ddd4f98568f48160fd6 (patch)
tree93bb6afa6892f02d1f5bb0144c69d98b1df55043 /amiga/plotters.c
parentc0c9f54a9c9096eaf68de4f7b8d5d2d15282f4a5 (diff)
downloadnetsurf-db9144230426e9dfa0203ddd4f98568f48160fd6.tar.gz
netsurf-db9144230426e9dfa0203ddd4f98568f48160fd6.tar.bz2
Remove branches that can't be taken under OS3
Micro-optimise these for OS4.1 Remove dummy compositing defines from os3support.h
Diffstat (limited to 'amiga/plotters.c')
-rw-r--r--amiga/plotters.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/amiga/plotters.c b/amiga/plotters.c
index 660dea74d..256f47747 100644
--- a/amiga/plotters.c
+++ b/amiga/plotters.c
@@ -501,10 +501,9 @@ static bool ami_bitmap(int x, int y, int width, int height, struct bitmap *bitma
LOG(("[ami_plotter] ami_bitmap() got native bitmap"));
#endif
- if((GfxBase->LibNode.lib_Version >= 53) && (palette_mapped == false) &&
- (nsoption_bool(direct_render) == false))
- {
#ifdef __amigaos4__
+ if(__builtin_expect((GfxBase->LibNode.lib_Version >= 53) && (palette_mapped == false) &&
+ (nsoption_bool(direct_render) == false), 1)) {
uint32 comptype = COMPOSITE_Src_Over_Dest;
uint32 compflags = COMPFLAG_IgnoreDestAlpha;
if(bitmap_get_opaque(bitmap)) {
@@ -524,9 +523,9 @@ static bool ami_bitmap(int x, int y, int width, int height, struct bitmap *bitma
COMPTAG_OffsetY,y,
COMPTAG_FriendBitMap, scrn->RastPort.BitMap,
TAG_DONE);
-#endif
}
else
+#endif
{
ULONG tag, tag_data, minterm = 0xc0;
@@ -710,10 +709,9 @@ static void ami_bitmap_tile_hook(struct Hook *hook,struct RastPort *rp,struct Ba
/* tile down and across to extents (bfmsg->Bounds.MinX)*/
for (xf = -bfbm->offsetx; xf < bfmsg->Bounds.MaxX; xf += bfbm->width) {
for (yf = -bfbm->offsety; yf < bfmsg->Bounds.MaxY; yf += bfbm->height) {
-
- if((GfxBase->LibNode.lib_Version >= 53) && (palette_mapped == false))
- {
#ifdef __amigaos4__
+ if(__builtin_expect((GfxBase->LibNode.lib_Version >= 53) &&
+ (palette_mapped == false), 1)) {
CompositeTags(COMPOSITE_Src_Over_Dest, bfbm->bm, rp->BitMap,
COMPTAG_Flags, COMPFLAG_IgnoreDestAlpha,
COMPTAG_DestX,bfmsg->Bounds.MinX,
@@ -726,9 +724,9 @@ static void ami_bitmap_tile_hook(struct Hook *hook,struct RastPort *rp,struct Ba
COMPTAG_OffsetY,yf,
COMPTAG_FriendBitMap, scrn->RastPort.BitMap,
TAG_DONE);
-#endif
}
else
+#endif
{
ULONG tag, tag_data, minterm = 0xc0;