1/* 2 * Copyright (C) 2011 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17#ifndef VIDEO_EDITOR_LOGGING_H 18#define VIDEO_EDITOR_LOGGING_H 19 20#ifndef LOG_TAG 21#error "No LOG_TAG defined!" 22#endif 23 24/* 25 * This file is used as a proxy for cutils/log.h. Include cutils/log.h here to 26 * avoid relying on import ordering. 27 */ 28#include <cutils/log.h> 29 30//#define VIDEOEDIT_LOGGING_ENABLED 31 32#define VIDEOEDIT_LOG_INDENTATION (3) 33 34#define VIDEOEDIT_LOG_ERROR __android_log_print 35#define VIDEOEDIT_LOG_EXCEPTION __android_log_print 36 37#ifdef VIDEOEDIT_LOGGING_ENABLED 38 39#define VIDEOEDIT_LOG_ALLOCATION __android_log_print 40#define VIDEOEDIT_LOG_API __android_log_print 41#define VIDEOEDIT_LOG_FUNCTION __android_log_print 42#define VIDEOEDIT_LOG_RESULT(x,y, ...) ALOGI(y, __VA_ARGS__ ) 43#define VIDEOEDIT_LOG_SETTING __android_log_print 44#define VIDEOEDIT_LOG_EDIT_SETTINGS(m_settings) videoEditClasses_logEditSettings\ 45 (m_settings, VIDEOEDIT_LOG_INDENTATION) 46#define VIDEOEDIT_PROP_LOG_PROPERTIES(m_properties) videoEditPropClass_logProperties\ 47 (m_properties, VIDEOEDIT_LOG_INDENTATION) 48#define VIDEOEDIT_PROP_LOG_RESULT __android_log_print 49 50#else 51 52#define VIDEOEDIT_LOG_ALLOCATION (void) 53#define VIDEOEDIT_LOG_API (void) 54#define VIDEOEDIT_LOG_FUNCTION (void) 55#define VIDEOEDIT_LOG_RESULT (void) 56#define VIDEOEDIT_LOG_SETTING (void) 57#define VIDEOEDIT_LOG_EDIT_SETTINGS(m_settings) (void)m_settings 58#define VIDEOEDIT_PROP_LOG_PROPERTIES(m_properties) (void)m_properties 59#define VIDEOEDIT_PROP_LOG_RESULT (void) 60 61#endif 62 63#endif // VIDEO_EDITOR_LOGGING_H 64 65