mirror of
git://projects.qi-hardware.com/ben-blinkenlights.git
synced 2025-04-21 12:27:27 +03:00
ubb-vga2: move image generation out of the main program
- ubb-vga2.c (session, grab): made the frame buffer "void *" and pass frame buffer resolution - ubb-vga.h: color encoding and items shared between compilation units - ubb-vga2.c (thres, pattern, grab), grabfb.c: move to grabfb.c - ubb-vga2.c (map): make global, for use by grabfb.c - ubb-vga2.c (pick, pattern, tricolor, grid): removed obsolete test image generators - Makefile (OBJS, ubb-vga2): added grabfb.o - Makefile (clean): remove only .o files - Makefile (spotless): remove only executables
This commit is contained in:
33
ubb-vga/ubb-vga.h
Normal file
33
ubb-vga/ubb-vga.h
Normal file
@@ -0,0 +1,33 @@
|
||||
/*
|
||||
* ubb-vga.h - Output video on UBB with more or less VGA timing
|
||||
*
|
||||
* Written 2011 by Werner Almesberger
|
||||
* Copyright 2011 Werner Almesberger
|
||||
*
|
||||
* 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 UBB_VGA_H
|
||||
#define UBB_VGA_H
|
||||
|
||||
#include <stdint.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
|
||||
#define R_VAL (1 << 3)
|
||||
#define G_VAL (1 << 0)
|
||||
#define B_VAL (1 << 1)
|
||||
#define Y_VAL (1 << 2)
|
||||
|
||||
|
||||
void *map(off_t addr, size_t size);
|
||||
|
||||
|
||||
extern uint8_t thres;
|
||||
|
||||
void grabfb(void *f, int xres, int yres);
|
||||
|
||||
#endif /* !UBB_VGA_H */
|
||||
Reference in New Issue
Block a user