- Add planar audio support. FFmpeg and libav use planar audio for many encoders, so it was somewhat necessary to add support in libobs itself. - Improve/adjust FFmpeg test output plugin. The exports were somewhat messed up (making me rethink how exports should be done). Not yet functional; it handles video properly, but it still does not handle audio properly. - Improve planar video code. The planar video code was not properly accounting for row sizes for each plane. Specifying row sizes for each plane has now been added. This will also make it more compatible with FFmpeg/libav. - Fixed a bug where callbacks wouldn't create properly in audio-io and video-io code. - Implement 'blogva' function to allow for va_list usage with libobs logging.
60 lines
1.5 KiB
C
60 lines
1.5 KiB
C
/*
|
|
* Copyright (c) 2013 Hugh Bailey <obs.jim@gmail.com>
|
|
*
|
|
* Permission to use, copy, modify, and distribute this software for any
|
|
* purpose with or without fee is hereby granted, provided that the above
|
|
* copyright notice and this permission notice appear in all copies.
|
|
*
|
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include <stdarg.h>
|
|
|
|
#include "c99defs.h"
|
|
|
|
/*
|
|
* Just contains logging/crash related stuff
|
|
*/
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
enum log_type {
|
|
LOG_DEBUG,
|
|
LOG_INFO,
|
|
LOG_WARNING,
|
|
LOG_ERROR
|
|
};
|
|
|
|
EXPORT void base_set_log_handler(
|
|
void (*handler)(enum log_type, const char *, va_list));
|
|
EXPORT void base_set_crash_handler(void (*handler)(const char *, va_list));
|
|
|
|
EXPORT void blogva(enum log_type type, const char *format, va_list args);
|
|
|
|
#ifndef _MSC_VER
|
|
#define PRINTFATTR(f, a) __attribute__((__format__(__printf__, f, a)))
|
|
#else
|
|
#define PRINTFATTR(f, a)
|
|
#endif
|
|
|
|
PRINTFATTR(2, 3)
|
|
EXPORT void blog(enum log_type type, const char *format, ...);
|
|
PRINTFATTR(1, 2)
|
|
EXPORT void bcrash(const char *format, ...);
|
|
|
|
#undef PRINTFATTR
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|