-
Notifications
You must be signed in to change notification settings - Fork 470
/
Copy pathtileimpl-n1x1.cpp
34 lines (28 loc) · 1.28 KB
/
tileimpl-n1x1.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
/*****************************************************************************\
Snes9x - Portable Super Nintendo Entertainment System (TM) emulator.
This file is licensed under the Snes9x License.
For further information, consult the LICENSE file in the root directory.
\*****************************************************************************/
#define _TILEIMPL_CPP_
#include "tileimpl.h"
namespace TileImpl {
template<class MATH, class BPSTART>
void Normal1x1Base<MATH, BPSTART>::Draw(int N, int M, uint32 Offset, uint32 OffsetInLine, uint8 Pix, uint8 Z1, uint8 Z2)
{
(void) OffsetInLine;
if (Z1 > GFX.DB[Offset + N] && (M))
{
GFX.S[Offset + N] = MATH::Calc(GFX.ScreenColors[Pix], GFX.SubScreen[Offset + N], GFX.SubZBuffer[Offset + N]);
GFX.DB[Offset + N] = Z2;
}
}
// normal width
template struct Renderers<DrawTile16, Normal1x1>;
template struct Renderers<DrawClippedTile16, Normal1x1>;
template struct Renderers<DrawMosaicPixel16, Normal1x1>;
template struct Renderers<DrawBackdrop16, Normal1x1>;
template struct Renderers<DrawMode7MosaicBG1, Normal1x1>;
template struct Renderers<DrawMode7BG1, Normal1x1>;
template struct Renderers<DrawMode7MosaicBG2, Normal1x1>;
template struct Renderers<DrawMode7BG2, Normal1x1>;
} // namespace TileImpl