/** * \file src/debug.cpp * MegRay is Licensed under the Apache License, Version 2.0 (the "License") * * Copyright (c) 2014-2020 Megvii Inc. All rights reserved. * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT ARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */ #include "debug.h" #include namespace MegRay { void MEGRAY_LOG(const char* level, const char* file, int line, const char* fmt, ...) { va_list ap; va_start(ap, fmt); fprintf(stderr, "[%s]\t%s:%d, ", level, file, line); vfprintf(stderr, fmt, ap); fprintf(stderr, "\n"); va_end(ap); } } // namespace MegRay