summaryrefslogtreecommitdiffstats
path: root/libvo/vesa_lvo.c
diff options
context:
space:
mode:
authordiego <diego@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-03-24 08:12:03 +0000
committerdiego <diego@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-03-24 08:12:03 +0000
commiteebf08b978f91243bb6eed54012267cc27183438 (patch)
tree83ce4df0814283621f24ef1d3ea4217981046993 /libvo/vesa_lvo.c
parent35e90f1556475ee205dee6c253b788ab073133c0 (diff)
downloadmpv-eebf08b978f91243bb6eed54012267cc27183438.tar.bz2
mpv-eebf08b978f91243bb6eed54012267cc27183438.tar.xz
Convert all if(verbose>X) to mp_msg_test calls.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@17933 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libvo/vesa_lvo.c')
-rw-r--r--libvo/vesa_lvo.c26
1 files changed, 17 insertions, 9 deletions
diff --git a/libvo/vesa_lvo.c b/libvo/vesa_lvo.c
index 2ab2c0d798..b108bfbfac 100644
--- a/libvo/vesa_lvo.c
+++ b/libvo/vesa_lvo.c
@@ -20,6 +20,7 @@
#include <string.h>
#include "config.h"
+#include "mp_msg.h"
#include "vesa_lvo.h"
#include "img_format.h"
@@ -40,7 +41,6 @@ static uint8_t *lvo_mem = NULL;
static uint8_t next_frame;
static mga_vid_config_t mga_vid_config;
static unsigned image_bpp,image_height,image_width,src_format;
-extern int verbose;
uint32_t vlvo_control(uint32_t request, void *data, ...);
#define PIXEL_SIZE() ((video_mode_info.BitsPerPixel+7)/8)
@@ -54,7 +54,8 @@ int vlvo_preinit(const char *drvname)
printf("vesa_lvo: This branch is no longer supported.\n"
"vesa_lvo: Please use -vo vesa:vidix instead\n");
return -1;
- if(verbose > 1) printf("vesa_lvo: vlvo_preinit(%s) was called\n",drvname);
+ if( mp_msg_test(MSGT_VO,MSGL_DBG2) ) {
+ printf("vesa_lvo: vlvo_preinit(%s) was called\n",drvname); }
lvo_handler = open(drvname,O_RDWR);
if(lvo_handler == -1)
{
@@ -78,7 +79,8 @@ int vlvo_init(unsigned src_width,unsigned src_height,
printf("vesa_lvo: This branch is no longer supported.\n"
"vesa_lvo: Please use -vo vesa:vidix instead\n");
return -1;
- if(verbose > 1) printf("vesa_lvo: vlvo_init() was called\n");
+ if( mp_msg_test(MSGT_VO,MSGL_DBG2) ) {
+ printf("vesa_lvo: vlvo_init() was called\n"); }
image_width = src_width;
image_height = src_height;
mga_vid_config.version=MGA_VID_VERSION;
@@ -146,7 +148,8 @@ int vlvo_init(unsigned src_width,unsigned src_height,
void vlvo_term( void )
{
- if(verbose > 1) printf("vesa_lvo: vlvo_term() was called\n");
+ if( mp_msg_test(MSGT_VO,MSGL_DBG2) ) {
+ printf("vesa_lvo: vlvo_term() was called\n"); }
ioctl( lvo_handler,MGA_VID_OFF,0 );
munmap(frames[0],mga_vid_config.frame_size*mga_vid_config.num_frames);
if(lvo_handler != -1) close(lvo_handler);
@@ -194,7 +197,8 @@ uint32_t vlvo_draw_slice_420(uint8_t *image[], int stride[], int w,int h,int x,i
uint32_t vlvo_draw_slice(uint8_t *image[], int stride[], int w,int h,int x,int y)
{
- if(verbose > 1) printf("vesa_lvo: vlvo_draw_slice() was called\n");
+ if( mp_msg_test(MSGT_VO,MSGL_DBG2) ) {
+ printf("vesa_lvo: vlvo_draw_slice() was called\n"); }
if(src_format == IMGFMT_YV12 || src_format == IMGFMT_I420 || src_format == IMGFMT_IYUV)
vlvo_draw_slice_420(image,stride,w,h,x,y);
else
@@ -213,13 +217,15 @@ uint32_t vlvo_draw_frame(uint8_t *image[])
{
/* Note it's very strange but sometime for YUY2 draw_frame is called */
memcpy(lvo_mem,image[0],mga_vid_config.frame_size);
- if(verbose > 1) printf("vesa_lvo: vlvo_draw_frame() was called\n");
+ if( mp_msg_test(MSGT_VO,MSGL_DBG2) ) {
+ printf("vesa_lvo: vlvo_draw_frame() was called\n"); }
return 0;
}
void vlvo_flip_page(void)
{
- if(verbose > 1) printf("vesa_lvo: vlvo_flip_page() was called\n");
+ if( mp_msg_test(MSGT_VO,MSGL_DBG2) ) {
+ printf("vesa_lvo: vlvo_flip_page() was called\n"); }
if(vo_doublebuffering)
{
ioctl(lvo_handler,MGA_VID_FSEL,&next_frame);
@@ -277,7 +283,8 @@ static void draw_alpha(int x0,int y0, int w,int h, unsigned char* src, unsigned
void vlvo_draw_osd(void)
{
- if(verbose > 1) printf("vesa_lvo: vlvo_draw_osd() was called\n");
+ if( mp_msg_test(MSGT_VO,MSGL_DBG2) ) {
+ printf("vesa_lvo: vlvo_draw_osd() was called\n"); }
/* TODO: hw support */
#if 0
/* disable this stuff until new fbvid.h interface will be implemented
@@ -289,7 +296,8 @@ void vlvo_draw_osd(void)
uint32_t vlvo_query_info(uint32_t format)
{
- if(verbose > 1) printf("vesa_lvo: query_format was called: %x (%s)\n",format,vo_format_name(format));
+ if( mp_msg_test(MSGT_VO,MSGL_DBG2) ) {
+ printf("vesa_lvo: query_format was called: %x (%s)\n",format,vo_format_name(format)); }
return VFCAP_CSP_SUPPORTED;
}