all repos — mgba @ 686380b6c4d8acf219a704a8932668b11efc47c2

mGBA Game Boy Advance Emulator

src/platform/qt/TileView.h (view raw)

 1/* Copyright (c) 2013-2016 Jeffrey Pfau
 2 *
 3 * This Source Code Form is subject to the terms of the Mozilla Public
 4 * License, v. 2.0. If a copy of the MPL was not distributed with this
 5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 6#ifndef QGBA_TILE_VIEW
 7#define QGBA_TILE_VIEW
 8
 9#include "AssetView.h"
10#include "GameController.h"
11
12#include "ui_TileView.h"
13
14#include <mgba/core/tile-cache.h>
15
16namespace QGBA {
17
18class TileView : public AssetView {
19Q_OBJECT
20
21public:
22	TileView(GameController* controller, QWidget* parent = nullptr);
23
24public slots:
25	void updatePalette(int);
26
27private:
28#ifdef M_CORE_GBA
29	void updateTilesGBA(bool force) override;
30#endif
31#ifdef M_CORE_GB
32	void updateTilesGB(bool force) override;
33#endif
34
35	Ui::TileView m_ui;
36
37	GameController* m_controller;
38	mTileCacheEntry m_tileStatus[3072 * 32]; // TODO: Correct size
39	int m_paletteId;
40};
41
42}
43
44#endif