src/common.h
author Radek Brich <radek.brich@devl.cz>
Thu, 29 Nov 2007 18:30:16 +0100
branchpyrit
changeset 20 f22952603f29
parent 15 a0a3e334744f
permissions -rw-r--r--
new C++ demo: realtime.cc (real-time scene viewer using SDL) Quaternion, Camera::rotate and Camera::move replace all printf's with infomsg wrapper don't allocate memory in Raytracer::render, just blindly write to provided address don't creat Container object in Raytracer, let user do it

#ifndef COMMON_H
#define COMMON_H

#include <stdio.h>
#include <stdarg.h>
#include <float.h>

#define Eps 1e-6
#define Inf FLT_MAX

inline void infomsg(const char *format, ...)
{
#ifndef PYRIT_QUITE
	va_list ap;
	va_start(ap, format);
	vprintf(format, ap);
	va_end(ap);
#endif
}

#endif