38#define PIX( _name, _type, _file, _width, _height, _data ) \
39 static const char _name ## __raw[] = _file; \
40 static const char _name ## __file \
41 [ sizeof ( _name ## __raw ) + 1 ] = _file; \
42 static const uint32_t _name ## __data[] = _data; \
43 static struct image _name ## __image = { \
44 .refcnt = REF_INIT ( ref_no_free ), \
46 .flags = ( IMAGE_STATIC | IMAGE_STATIC_NAME ), \
47 .data = _name ## __file, \
48 .len = ( sizeof ( _name ## __file ) - 1 ), \
50 static struct pixel_buffer_test _name = { \
52 .image = & _name ## __image, \
53 .data = _name ## __data, \
54 .len = sizeof ( _name ## __data ), \
67#define pixbuf_ok( test ) pixbuf_okx ( test, __FILE__, __LINE__ )
#define FILE_LICENCE(_licence)
Declare a particular licence as applying to a file.
void pixbuf_okx(struct pixel_buffer_test *test, const char *file, unsigned int line)
Report pixel buffer test result.
An executable image type.
struct image * image
Source image.
const uint32_t * data
Pixel data.
unsigned int height
Height.
size_t len
Length of pixel data.
struct image_type * type
Image type.
Self-test infrastructure.