summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/multimedia/opieplayer2/yuv2rgb_arm2.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/noncore/multimedia/opieplayer2/yuv2rgb_arm2.c b/noncore/multimedia/opieplayer2/yuv2rgb_arm2.c
index cbd32e8..91cd0b1 100644
--- a/noncore/multimedia/opieplayer2/yuv2rgb_arm2.c
+++ b/noncore/multimedia/opieplayer2/yuv2rgb_arm2.c
@@ -23,96 +23,97 @@
* project.
* In order to improve performance, by strongly reducing memory bandwidth
* needed, the scaling functions are merged with the yuv2rgb function.
*/
#ifdef __arm__
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <inttypes.h>
#include "yuv2rgb.h"
#include <xine/xineutils.h>
/* Prototypes of the "local" functions available here: */
/* first prototype, function called when no scaling is needed: */
static void arm_rgb16_noscale(yuv2rgb_t*, uint8_t*, uint8_t*, uint8_t*, uint8_t*);
/* second prototype, function called when no horizontal scaling is needed: */
static void arm_rgb16_step_dx_32768(yuv2rgb_t*, uint8_t*, uint8_t*, uint8_t*, uint8_t*);
/* third prototype, function called when scaling is needed for zooming in: */
static void arm_rgb16_step_dx_inf_32768(yuv2rgb_t*, uint8_t*, uint8_t*, uint8_t*, uint8_t*);
/* fourth prototype, function called when scaling is needed for zooming out (between 1x and 2x): */
static void arm_rgb16_step_dx_bet_32768_65536(yuv2rgb_t*, uint8_t*, uint8_t*, uint8_t*, uint8_t*);
/* fifth prototype, function called when scaling is needed for zooming out (greater than 2x): */
static void arm_rgb16_step_dx_sup_65536(yuv2rgb_t*, uint8_t*, uint8_t*, uint8_t*, uint8_t*);
/* sixth prototype, function where the decision of the scaling function to use is made.*/
static void arm_rgb16_2 (yuv2rgb_t*, uint8_t*, uint8_t*, uint8_t*, uint8_t*);
/* extern function: */
/* Function: */
void yuv2rgb_init_arm (yuv2rgb_factory_t *this)
/* This function initialise the member yuv2rgb_fun, if everything is right
the function optimised for the arm target should be used.*/
{
if (this->swapped)
return; /*no swapped pixel output upto now*/
switch (this->mode)
{
case MODE_16_RGB:
this->yuv2rgb_fun = arm_rgb16_2;
break;
default:
+ break;
}
}
/* local functions: */
/* Function: */
static void arm_rgb16_2 (yuv2rgb_t *this, uint8_t * _dst, uint8_t * _py, uint8_t * _pu, uint8_t * _pv)
/* This function takes care of applying the right scaling conversion
(yuv2rgb is included in each scaling function!)*/
{
if (!this->do_scale)
{
arm_rgb16_noscale(this, _dst, _py, _pu, _pv);
return;
}
if (this->step_dx<32768)
{
arm_rgb16_step_dx_inf_32768(this, _dst, _py, _pu, _pv);
return;
}
if (this->step_dx==32768)
{
arm_rgb16_step_dx_32768(this, _dst, _py, _pu, _pv);
return;
}
if (this->step_dx<65536)
{
arm_rgb16_step_dx_bet_32768_65536(this, _dst, _py, _pu, _pv);
return;
}
arm_rgb16_step_dx_sup_65536(this, _dst, _py, _pu, _pv);
return;
}
/* Function: */
static void arm_rgb16_noscale(yuv2rgb_t *this, uint8_t * _dst, uint8_t * _py, uint8_t * _pu, uint8_t * _pv)
/* This function is called when the source and the destination pictures have the same size.
In this case, scaling part is not needed.
(This code is probably far from being optimised, in particular, the asm
generated is not the most efficient, a pure asm version will probably
emerge sooner or later). But at least, this version is faster than what
was used before.*/
{
int height;