Mercurial > mplayer.hg
comparison libmpeg2/decode.c @ 3147:5da6e1b6c93e
runtime cpu detection
author | michael |
---|---|
date | Mon, 26 Nov 2001 23:21:24 +0000 |
parents | 8e3875816f6d |
children | 0796862b88db |
comparison
equal
deleted
inserted
replaced
3146:3164eaa93396 | 3147:5da6e1b6c93e |
---|---|
40 #include "mmx.h" | 40 #include "mmx.h" |
41 #endif | 41 #endif |
42 | 42 |
43 #include "mm_accel.h" | 43 #include "mm_accel.h" |
44 | 44 |
45 #include "../cpudetect.h" | |
45 | 46 |
46 //this is where we keep the state of the decoder | 47 //this is where we keep the state of the decoder |
47 //picture_t picture_data; | 48 //picture_t picture_data; |
48 //picture_t *picture=&picture_data; | 49 //picture_t *picture=&picture_data; |
49 picture_t *picture=NULL; | 50 picture_t *picture=NULL; |
69 void mpeg2_init (void) | 70 void mpeg2_init (void) |
70 { | 71 { |
71 | 72 |
72 printf (PACKAGE"-"VERSION" (C) 2000-2001 Aaron Holtzman & Michel Lespinasse\n"); | 73 printf (PACKAGE"-"VERSION" (C) 2000-2001 Aaron Holtzman & Michel Lespinasse\n"); |
73 config.flags = 0; | 74 config.flags = 0; |
74 #ifdef HAVE_MMX | 75 if(gCpuCaps.hasMMX) |
75 config.flags |= MM_ACCEL_X86_MMX; | 76 config.flags |= MM_ACCEL_X86_MMX; |
76 #endif | 77 if(gCpuCaps.hasMMX2) |
77 #ifdef HAVE_SSE | |
78 config.flags |= MM_ACCEL_X86_MMXEXT; | 78 config.flags |= MM_ACCEL_X86_MMXEXT; |
79 #endif | 79 if(gCpuCaps.has3DNow) |
80 #ifdef HAVE_3DNOW | |
81 config.flags |= MM_ACCEL_X86_3DNOW; | 80 config.flags |= MM_ACCEL_X86_3DNOW; |
82 #endif | |
83 #ifdef HAVE_MLIB | 81 #ifdef HAVE_MLIB |
84 config.flags |= MM_ACCEL_MLIB; | 82 config.flags |= MM_ACCEL_MLIB; |
85 #endif | 83 #endif |
86 | 84 |
87 // printf("libmpeg2 config flags = 0x%X\n",config.flags); | 85 // printf("libmpeg2 config flags = 0x%X\n",config.flags); |