MediaX v1.0.0rc7 [7e6cb74]
Video streaming for military vehicles
Loading...
Searching...
No Matches
utils.h
Go to the documentation of this file.
1//
2// Copyright (c) 2024, Astute Systems PTY LTD
3//
4// This file is part of the MediaX project developed by Astute Systems.
5//
6// Licensed under the Attribution-NonCommercial 4.0 International (CC BY-NC 4.0)
7// License. See the LICENSE file in the project root for full license details.
8//
13
14#ifndef UTILS_H
15#define UTILS_H
16#include <assert.h>
17#include <capture.h>
18#include <capture_yuyv.h>
19#include <errno.h>
20#include <fcntl.h> // low-level i/o
21#include <getopt.h> // getopt_long()
22#include <linux/videodev2.h>
23#include <stdio.h>
24#include <stdlib.h>
25#include <string.h>
26#include <sys/ioctl.h>
27#include <sys/mman.h>
28#include <sys/stat.h>
29#include <sys/time.h>
30#include <sys/types.h>
31#include <unistd.h>
32
33struct image_info_t {
34 int stride;
35 int width;
36 int height;
37};
38
39void YUV422toBGR888(int width, int height, unsigned char *src, unsigned char *dst);
40int SaveImageUncompressed(const unsigned char *image, const char *szFilename, image_info_t *info, int type);
41
42#endif // UTILS_H
A simple video receiver example.
A simple video receiver example.
Definition capture_yuyv.c:94