~ubuntu-branches/ubuntu/raring/simutrans/raring-proposed

« back to all changes in this revision

Viewing changes to besch/bild_besch.h

  • Committer: Package Import Robot
  • Author(s): Ansgar Burchardt
  • Date: 2011-11-03 19:59:02 UTC
  • mfrom: (1.2.7)
  • Revision ID: package-import@ubuntu.com-20111103195902-uopgwf488mfctb75
Tags: 111.0-1
* New upstream release.
* debian/rules: Update get-orig-source target for new upstream release.
* Use xz compression for source and binary packages.
* Use override_* targets to simplify debian/rules.

Show diffs side-by-side

added added

removed removed

Lines of Context:
7
7
#ifndef __BILD_BESCH_H
8
8
#define __BILD_BESCH_H
9
9
 
 
10
#include "../simgraph.h"
10
11
#include "../simimg.h"
11
12
#include "obj_besch.h"
12
13
 
13
14
 
 
15
// number of special colors
 
16
#define SPECIAL (31)
 
17
 
 
18
//#define TRANSPARENT 0x808088
 
19
#define SPECIAL_TRANSPARENT (0xE7FFFF)
 
20
 
 
21
 
14
22
struct bild_t {
15
23
        sint16 x;
16
24
        sint16 y;
35
43
class bild_besch_t : public obj_besch_t
36
44
{
37
45
public:
 
46
        static const uint32 rgbtab[SPECIAL];
 
47
 
38
48
        const bild_t* get_pic() const { return &pic; }
39
49
 
40
50
        uint16 const* get_daten() const { return pic.data; }
48
58
         */
49
59
        bild_besch_t* copy_rotate(const sint16 angle) const;
50
60
 
 
61
        void register_image() { ::register_image(&pic); }
 
62
 
51
63
        using obj_besch_t::operator new;
52
64
 
 
65
        // decodes this image into a 32 bit bitmap with width target_width
 
66
        void decode_img( sint16 xoff, sint16 yoff, uint32 *target, uint32 target_width, uint32 target_height );
 
67
 
53
68
private:
54
69
        bild_t pic;
55
70
 
56
71
        friend class image_reader_t;
57
 
        friend class grund_besch_t; // XXX ugly
58
72
};
59
73
 
60
74
#endif