File: fswebcam.h

package info (click to toggle)
fswebcam 20140113-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 612 kB
  • sloc: ansic: 8,442; makefile: 58
file content (35 lines) | stat: -rw-r--r-- 936 bytes parent folder | download | duplicates (3)
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
/* fswebcam - Small and simple webcam for *nix                */
/*============================================================*/
/* Copyright (C)2005-2011 Philip Heron <phil@sanslogic.co.uk> */
/*                                                            */
/* This program is distributed under the terms of the GNU     */
/* General Public License, version 2. You may use, modify,    */
/* and redistribute it under the terms of this license. A     */
/* copy should be included with this source.                  */

#ifndef INC_FSWC_H
#define INC_FSWC_H

#include <stdint.h>

#ifdef HAVE_CONFIG_H
#include "config.h"
#endif

/* Define the bitmap type */
#ifdef USE_32BIT_BUFFER

typedef uint32_t avgbmp_t;
#define MAX_FRAMES (UINT32_MAX >> 8)

#else

typedef uint16_t avgbmp_t;
#define MAX_FRAMES (UINT16_MAX >> 8)

#endif
/*----*/

#define CLIP(val, min, max) (((val) > (max)) ? (max) : (((val) < (min)) ? (min) : (val)))

#endif