image_u8x3.h
Go to the documentation of this file.
1 /* Copyright (C) 2013-2016, The Regents of The University of Michigan.
2 All rights reserved.
3 
4 This software was developed in the APRIL Robotics Lab under the
5 direction of Edwin Olson, ebolson@umich.edu. This software may be
6 available under alternative licensing terms; contact the address above.
7 
8 This library is free software; you can redistribute it and/or
9 modify it under the terms of the GNU Lesser General Public
10 License as published by the Free Software Foundation; either
11 version 2.1 of the License, or (at your option) any later version.
12 
13 This library is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 Lesser General Public License for more details.
17 
18 You should have received a copy of the GNU Lesser General Public
19 License along with this library; if not, see <http://www.gnu.org/licenses/>.
20 */
21 
22 #ifndef _IMAGE_U8X3_H
23 #define _IMAGE_U8X3_H
24 
25 #include <stdint.h>
26 #include "common/image_types.h"
27 
28 #ifdef __cplusplus
29 extern "C" {
30 #endif
31 
32 
34 // IMPORTANT NOTE ON BYTE ORDER
35 //
36 // Format conversion routines will (unless otherwise specified) assume
37 // R, G, B, ordering of bytes. This is consistent with GTK, PNM, etc.
38 //
40 
41 // Create or load an image. returns NULL on failure
42 image_u8x3_t *image_u8x3_create(unsigned int width, unsigned int height);
43 image_u8x3_t *image_u8x3_create_alignment(unsigned int width, unsigned int height, unsigned int alignment);
44 image_u8x3_t *image_u8x3_create_from_pnm(const char *path);
45 
47 
48 void image_u8x3_gaussian_blur(image_u8x3_t *im, double sigma, int ksz);
49 
51 
52 int image_u8x3_write_pnm(const image_u8x3_t *im, const char *path);
53 
54 // only width 1 supported
55 void image_u8x3_draw_line(image_u8x3_t *im, float x0, float y0, float x1, float y1, uint8_t rgb[3], int width);
56 
57 #ifdef __cplusplus
58 }
59 #endif
60 
61 #endif
image_u8x3_t * image_u8x3_copy(const image_u8x3_t *in)
Definition: image_u8x3.c:59
image_u8x3_t * image_u8x3_create(unsigned int width, unsigned int height)
Definition: image_u8x3.c:37
image_u8x3_t * image_u8x3_create_from_pnm(const char *path)
Definition: image_u8x3.c:85
void image_u8x3_destroy(image_u8x3_t *im)
Definition: image_u8x3.c:72
int image_u8x3_write_pnm(const image_u8x3_t *im, const char *path)
Definition: image_u8x3.c:132
void image_u8x3_gaussian_blur(image_u8x3_t *im, double sigma, int ksz)
Definition: image_u8x3.c:199
image_u8x3_t * image_u8x3_create_alignment(unsigned int width, unsigned int height, unsigned int alignment)
Definition: image_u8x3.c:42
void image_u8x3_draw_line(image_u8x3_t *im, float x0, float y0, float x1, float y1, uint8_t rgb[3], int width)
Definition: image_u8x3.c:160


apriltags2
Author(s): Danylo Malyuta
autogenerated on Fri Oct 19 2018 04:02:32