author | sandman <sandman> | 2002-08-27 21:47:10 (UTC) |
---|---|---|
committer | sandman <sandman> | 2002-08-27 21:47:10 (UTC) |
commit | c9fdf2ca20f650ff4e4ef94036bccdbe8d830f26 (patch) (side-by-side diff) | |
tree | 30b2656ab4de07a908caf6732da8fd934010ae2a | |
parent | a6432554a1e64d54c53c1400aa1dfa11ae83f11a (diff) | |
download | opie-c9fdf2ca20f650ff4e4ef94036bccdbe8d830f26.zip opie-c9fdf2ca20f650ff4e4ef94036bccdbe8d830f26.tar.gz opie-c9fdf2ca20f650ff4e4ef94036bccdbe8d830f26.tar.bz2 |
Added copyright header
-rw-r--r-- | noncore/multimedia/opieplayer2/yuv2rgb_arm4l.S | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/noncore/multimedia/opieplayer2/yuv2rgb_arm4l.S b/noncore/multimedia/opieplayer2/yuv2rgb_arm4l.S index f4a3395..521bcaa 100644 --- a/noncore/multimedia/opieplayer2/yuv2rgb_arm4l.S +++ b/noncore/multimedia/opieplayer2/yuv2rgb_arm4l.S @@ -1,48 +1,69 @@ +/* +Copyright (c) 2001 Lionel Ulmer (lionel.ulmer@free.fr / bbrox@bbrox.org) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +*/ + /* WARNING : this function only works when stride_U == stride_V (I use some hacks to not have to do too many computations at line's end)... C-like prototype : void convert_yuv420_rgb565(AVPicture *picture, unsigned char *results, int w, int h) ; */ #ifdef __arm__ .text .align .global convert_yuv420_rgb565 convert_yuv420_rgb565: stmdb sp!, { r4 - r12, lr } @ all callee saved regs ldr r7, [r0, #0] @ Y ptr ldr r9, [r0, #4] @ U ptr ldr r10, [r0, #8] @ V ptr subs r10, r10, r9 @ V ptr - U ptr ldr r8, [r0, #12] add r8, r8, r7 @ Y + stride_Y ldr r4, [r0, #12] @ Stride_Y mov r4, r4, lsl #1 sub r4, r4, r2 @ (2 * Stride_Y) - width ldr r5, [r0, #16] @ Stride_U sub r5, r5, r2, lsr #1 @ Stride_U - (width / 2) ldr r6, [r0, #20] @ Stride_V sub r6, r6, r2, lsr #1 @ Stride_V - (width / 2) add r0, r1, r2, lsl #1 @ RGB + 1 stmdb sp!, { r0-r10 } @ Stack description : @ (sp+ 0) RGB + one line @ (sp+ 4) RGB @ (sp+ 8) width (save) @ (sp+12) height @ (sp+16) (2 * stride_Y) - width @ (sp+20) stride_U - (width / 2) @ (sp+24) stride_V - (width / 2) !!! UNUSED !!! @ (sp+28) Y ptr @ (sp+32) Y ptr + one line @ (sp+36) U ptr @ (sp+40) V - U mov lr, r2 @ Initialize the width counter add r0, pc, #(const_storage-.-8) @ r0 = base pointer to the constants array ldr r8, [r0, #(4*4)] @ r8 = multy yuv_loop: add r0, pc, #(const_storage-.-8) @ r0 = base pointer to the constants array |