diff options
author | nick <nick@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2001-10-29 18:25:07 +0000 |
---|---|---|
committer | nick <nick@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2001-10-29 18:25:07 +0000 |
commit | f348370e5a0e7423024ea6bc8a311688ba7311e2 (patch) | |
tree | 2900d190968e0249d403b6c734f32d83d5bd8da4 /libvo/vo_vesa.c | |
parent | 57144b5a28cfac6408763a02df6bfa99ffbc2a97 (diff) | |
download | mpv-f348370e5a0e7423024ea6bc8a311688ba7311e2.tar.bz2 mpv-f348370e5a0e7423024ea6bc8a311688ba7311e2.tar.xz |
memalign 64
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@2538 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libvo/vo_vesa.c')
-rw-r--r-- | libvo/vo_vesa.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libvo/vo_vesa.c b/libvo/vo_vesa.c index 2a3f0366d5..20ad8628e6 100644 --- a/libvo/vo_vesa.c +++ b/libvo/vo_vesa.c @@ -25,6 +25,10 @@ #include "video_out.h" #include "video_out_internal.h" +#ifdef HAVE_MEMALIGN +#include <malloc.h> +#endif + #include "fastmemcpy.h" #include "yuv2rgb.h" #include "sub.h" @@ -622,7 +626,11 @@ init(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint3 ,x_offset,y_offset); if(yuv_fmt || rgb2rgb_fnc) { +#ifdef HAVE_MEMALIGN + if(!(yuv_buffer = memalign(64,video_mode_info.XResolution*video_mode_info.YResolution*video_mode_info.BitsPerPixel))) +#else if(!(yuv_buffer = malloc(video_mode_info.XResolution*video_mode_info.YResolution*video_mode_info.BitsPerPixel))) +#endif { printf("vo_vesa: Can't allocate temporary buffer\n"); return -1; |