image_patterns.h 1.05 KB
Newer Older
1
2
3
4
#ifndef IMAGE_PATTERNS_H
#define IMAGE_PATTERNS_H

#include "patterns.h"
5
#include "image_patterns_common.h"
6
#include "frame_buffer_control.h"
7
#include "memory.h"
8

9
10
#ifndef IMG_MAX_NUM_IMAGES
  #error "Please, specify the maximum number of images with the IMG_MAX_NUM_IMAGES macro"
11
12
#endif

13
14
#ifndef IMG_MAX_IMAGE_WIDTH
  #error "Please, specify the maximum image width with the IMG_MAX_IMAGE_WIDTH macro"
15
16
#endif

17
18
#ifndef IMG_MAX_IMAGE_HEIGHT
  #error "Please, specify the maximum image height with the IMG_MAX_IMAGE_HEIGHT macro"
19
20
#endif

21
extern unsigned char img_pattern_data[IMG_MAX_NUM_IMAGES][IMG_MAX_IMAGE_HEIGHT][IMG_MAX_IMAGE_WIDTH][3];
22

23
void img_patterns_init(TMemory *memory,unsigned short int ram_base_address);
24
25
26
27
28
29
30
31
32
33
34
35

#pragma pack (push, 1)
typedef struct
{
  short int start_row;
  short int start_col;
  unsigned char buffer_id;
  unsigned char waveform_index;
  unsigned char motion_index;
}TIMGDisplayData;
#pragma pack (pop)

36
void img_general(TLEDArea *area,TIMGDisplayData *pattern_data,unsigned char buffer_id,unsigned short int period,TFBControl *control);
37
38

#endif