change font file in decoder-subplugins to build static library.
Signed-off-by: Jaeyun Jung <jy1210.jung@samsung.com>
# bounding boxes
decoder_sub_bounding_boxes_sources = [
- 'tensordec-boundingbox.c'
+ 'tensordec-boundingbox.c',
+ 'tensordec-font.c'
]
nnstreamer_decoder_bounding_boxes_sources = []
# pose estimation
decoder_sub_pose_estimation_sources = [
- 'tensordec-pose.c'
+ 'tensordec-pose.c',
+ 'tensordec-font.c'
]
nnstreamer_decoder_pose_estimation_sources = []
#include <glib.h>
#include <gst/gst.h>
#include <math.h> /* expf */
-#include "font.h"
#include <nnstreamer_plugin_api_decoder.h>
#include <nnstreamer_plugin_api.h>
void init_bb (void) __attribute__ ((constructor));
void fini_bb (void) __attribute__ ((destructor));
+/* font.c */
+extern uint8_t rasters[][13];
+
#define BOX_SIZE 4
#define TFLITE_SSD_DETECTION_MAX 1917
#define TFLITE_SSD_MAX_TENSORS 2
* OpenGL(TM) is a trademark of Silicon Graphics, Inc.
*/
/**
- * @file font.h
+ * @file tensordec-font.c
* @date 20 Nov 2018
* @brief imported from font.c of https://courses.cs.washington.edu/courses/cse457/98a/tech/OpenGL/font.c
* and modified to support tensordec-boundingbox.c
* @bug No known bugs.
* @author Silicon Graphics Inc. (imported and modified by MyungJoo Ham <myungjoo.ham@samsung.com>)
*/
-#ifndef _NNSTREAMER_FONT_H_
-#define _NNSTREAMER_FONT_H_
+
#include <stdint.h>
+
/**
* raster[ch][12] is the top pixels
* raster[ch][0] is the bottom pixels
{0x00, 0x00, 0xf0, 0x18, 0x18, 0x18, 0x1c, 0x0f, 0x1c, 0x18, 0x18, 0x18, 0xf0},
{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x8f, 0xf1, 0x60, 0x00, 0x00, 0x00}
};
-#endif /* _NNSTREAMER_FONT_H_ */
+
#include <string.h>
#include <stdint.h>
#include <glib.h>
-#include "font.h"
#include <gst/gst.h>
#include <nnstreamer_plugin_api_decoder.h>
#include <nnstreamer_plugin_api.h>
void init_pose (void) __attribute__ ((constructor));
void finish_pose (void) __attribute__ ((destructor));
+/* font.c */
+extern uint8_t rasters[][13];
+
#define POSE_SIZE 14
#define PIXEL_VALUE (0xFFFFFFFF) /* White 100% in RGBA */
# decoder boundingbox
NNSTREAMER_DECODER_BB_SRCS := \
- $(NNSTREAMER_EXT_HOME)/tensor_decoder/tensordec-boundingbox.c
+ $(NNSTREAMER_EXT_HOME)/tensor_decoder/tensordec-boundingbox.c \
+ $(NNSTREAMER_EXT_HOME)/tensor_decoder/tensordec-font.c
# decoder directvideo
NNSTREAMER_DECODER_DV_SRCS := \
# decoder pose estimation
NNSTREAMER_DECODER_PE_SRCS := \
- $(NNSTREAMER_EXT_HOME)/tensor_decoder/tensordec-pose.c
+ $(NNSTREAMER_EXT_HOME)/tensor_decoder/tensordec-pose.c \
+ $(NNSTREAMER_EXT_HOME)/tensor_decoder/tensordec-font.c
# common features
NO_AUDIO := false