-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathmap.h
More file actions
40 lines (30 loc) · 793 Bytes
/
map.h
File metadata and controls
40 lines (30 loc) · 793 Bytes
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
35
36
37
38
39
40
/*
* Copyright (C) 2016 Dmitry Morozov <dmorozov@outlook.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*/
#ifndef MAP_H
#define MAP_H
#include <QObject>
#include <QImage>
#include "object.h"
class Map : public QObject
{
Q_OBJECT
M_OBJECT
public:
Q_INVOKABLE explicit Map(QObject *parent = 0);
~Map() {}
Q_INVOKABLE void load(const QString &id);
Q_INVOKABLE bool contains(int x, int y) const;
Q_INVOKABLE int value(int x, int y) const;
const QImage &image() const;
signals:
public slots:
private:
QImage m_image;
};
#endif // MAP_H