7 #define _CRT_SECURE_NO_WARNINGS 13 #define DB_FLG "[deprint ] " 14 #define PRINTF_NUM_MAX 128 15 #define log_put printf 20 va_start(arg, format);
28 for (
int i = 0; i < n; ++i) {
print_log(
"%0.3f ", vect[i]); }
34 for (
int i = 0; i < n; ++i) {
print_log(
"%0.3f ", vect[i]); }
38 void print_nvect(
const char *str,
unsigned char vect[],
int n) {
40 for (
int i = 0; i < n; ++i) {
print_log(
"%d ", vect[i]); }
46 for (
int i = 0; i < n; ++i) {
print_log(
"%d ", vect[i]); }
50 void print_hex(
const char *str,
unsigned char *hex,
int len) {
52 char *buf =
new char[len * 3 + 1];
54 for (i = 0; i < len; ++i) { sprintf((
char *)&buf[i * 3],
"%02x ", hex[i]); }
56 printf(
"%s %s\n", str, buf);
void print_nvect(const char *str, double vect[], int n)
void print_hex(const char *str, unsigned char *hex, int len)
void print_log(const char *format,...)