summaryrefslogtreecommitdiffstats
path: root/exynos4/hal/libfimg4x/FimgApi.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'exynos4/hal/libfimg4x/FimgApi.cpp')
-rw-r--r--exynos4/hal/libfimg4x/FimgApi.cpp106
1 files changed, 30 insertions, 76 deletions
diff --git a/exynos4/hal/libfimg4x/FimgApi.cpp b/exynos4/hal/libfimg4x/FimgApi.cpp
index 444e9c9..8cca61c 100644
--- a/exynos4/hal/libfimg4x/FimgApi.cpp
+++ b/exynos4/hal/libfimg4x/FimgApi.cpp
@@ -270,107 +270,61 @@ extern "C" int SyncFimgApi(void)
void printDataBlit(char *title, struct fimg2d_blit *cmd)
{
- ALOGI("%s\n", title);
+ SLOGI("%s\n", title);
- ALOGI(" sequence_no. = %u\n", cmd->seq_no);
- ALOGI(" blit_op = %d(%s)\n", cmd->op, optbl[cmd->op].str);
- ALOGI(" fill_color = %X\n", cmd->solid_color);
- ALOGI(" global_alpha = %u\n", (unsigned int)cmd->g_alpha);
- ALOGI(" PREMULT = %s\n", cmd->premult == PREMULTIPLIED ? "PREMULTIPLIED" : "NON-PREMULTIPLIED");
- ALOGI(" do_dither = %s\n", cmd->dither == true ? "dither" : "no-dither");
+ SLOGI(" sequence_no. = %u\n", cmd->seq_no);
+ SLOGI(" blit_op = %d(%s)\n", cmd->op, optbl[cmd->op].str);
+ SLOGI(" fill_color = %X\n", cmd->param.solid_color);
+ SLOGI(" global_alpha = %u\n", (unsigned int)cmd->param.g_alpha);
+ SLOGI(" PREMULT = %s\n", cmd->param.premult == PREMULTIPLIED ? "PREMULTIPLIED" : "NON-PREMULTIPLIED");
+ SLOGI(" do_dither = %s\n", cmd->param.dither == true ? "dither" : "no-dither");
- printDataBlitRotate(cmd->rotate);
+ printDataBlitRotate(cmd->param.rotate);
- printDataBlitScale(cmd->scaling);
+ printDataBlitScale(&cmd->param.scaling);
printDataBlitImage("SRC", cmd->src);
printDataBlitImage("DST", cmd->dst);
printDataBlitImage("MSK", cmd->msk);
- printDataBlitRect("SRC", cmd->src_rect);
- printDataBlitRect("DST", cmd->dst_rect);
- printDataBlitRect("MSK", cmd->msk_rect);
-
- printDataBlitClip(cmd->clipping);
+ printDataBlitRect("SRC", &cmd->src->rect);
+ printDataBlitRect("DST", &cmd->dst->rect);
+ printDataBlitRect("MSK", &cmd->msk->rect);
}
void printDataBlitImage(char *title, struct fimg2d_image *image)
{
if (NULL != image) {
- ALOGI(" Image_%s\n", title);
- ALOGI(" addr = %X\n", image->addr.start);
- ALOGI(" size = %u\n", image->addr.size);
- ALOGI(" (width, height) = (%d, %d)\n", image->width, image->height);
- ALOGI(" format = %d\n", image->fmt);
+ SLOGI(" Image_%s\n", title);
+ SLOGI(" addr = %X\n", image->addr.start);
+ SLOGI(" format = %d\n", image->fmt);
} else
- ALOGI(" Image_%s : NULL\n", title);
+ SLOGI(" Image_%s : NULL\n", title);
}
void printDataBlitRect(char *title, struct fimg2d_rect *rect)
{
if (NULL != rect) {
- ALOGI(" RECT_%s\n", title);
- ALOGI(" (x1, y1) = (%d, %d)\n", rect->x1, rect->y1);
- ALOGI(" (x2, y2) = (%d, %d)\n", rect->x2, rect->y2);
- ALOGI(" (width, height) = (%d, %d)\n", rect->x2 - rect->x1, rect->y2 - rect->y1);
+ SLOGI(" RECT_%s\n", title);
+ SLOGI(" (x1, y1) = (%d, %d)\n", rect->x1, rect->y1);
+ SLOGI(" (x2, y2) = (%d, %d)\n", rect->x2, rect->y2);
+ SLOGI(" (width, height) = (%d, %d)\n", rect->x2 - rect->x1, rect->y2 - rect->y1);
} else
- ALOGI(" RECT_%s : NULL\n", title);
-}
-
-void printDataBlitRotate(enum rotation rotate)
-{
- ALOGI(" ROTATE : %d\n", rotate);
+ SLOGI(" RECT_%s : NULL\n", title);
}
-void printDataBlitClip(struct fimg2d_clip *clip)
+void printDataBlitRotate(int rotate)
{
- if (NULL != clip) {
- ALOGI(" CLIP\n");
- ALOGI(" clip %s\n", clip->enable == true ? "enabled" : "disabled");
- ALOGI(" (x1, y1) = (%d, %d)\n", clip->x1, clip->y1);
- ALOGI(" (x2, y2) = (%d, %d)\n", clip->x2, clip->y2);
- ALOGI(" (width, hight) = (%d, %d)\n", clip->x2 - clip->x1, clip->y2 - clip->y1);
- } else
- ALOGI(" CLIP : NULL\n");
+ SLOGI(" ROTATE : %d\n", rotate);
}
void printDataBlitScale(struct fimg2d_scale *scaling)
{
- if (NULL != scaling) {
- ALOGI(" SCALING\n");
- ALOGI(" scale_mode : %s\n", scaling->mode == 0 ?
- "NO_SCALING" :
- (scaling->mode == 1 ? "SCALING_NEAREST" : "SCALING_BILINEAR"));
- ALOGI(" scaling_factor_unit : %s\n", scaling->factor == 0 ? "PERCENT" : "PIXEL");
-
- if (scaling->factor == 0)
- ALOGI(" scaling_factor : (scale_w, scale_y) = (%d, %d)\n", scaling->scale_w, scaling->scale_h);
- else {
- ALOGI(" src : (src_w, src_h) = (%d, %d)\n", scaling->src_w, scaling->src_h);
- ALOGI(" dst : (dst_w, dst_h) = (%d, %d)\n", scaling->dst_w, scaling->dst_h);
- ALOGI(" scaling_factor : (scale_w, scale_y) = (%3.2f, %3.2f)\n", (double)scaling->dst_w / scaling->src_w, (double)scaling->dst_h / scaling->src_h);
- }
- } else
- ALOGI(" SCALING : NULL(NO SCALE MODE)\n");
-
-}
-
-void printDataMatrix(int matrixType)
-{
- ALOGI(" MATRIX\n");
-
- if (matrixType & SkMatrix::kIdentity_Mask)
- ALOGI(" Matrix_type : Identity_Mask\n");
-
- if (matrixType & SkMatrix::kTranslate_Mask)
- ALOGI(" Matrix_type : Translate_Mask(the matrix has translation)\n");
-
- if (matrixType & SkMatrix::kScale_Mask)
- ALOGI(" Matrix_type : Scale_Mask(the matrix has X or Y scale)\n");
-
- if (matrixType & SkMatrix::kAffine_Mask)
- ALOGI(" Matrix_type : Affine_Mask(the matrix skews or rotates)\n");
-
- if (matrixType & SkMatrix::kPerspective_Mask)
- ALOGI(" Matrix_type : Perspective_Mask(the matrix is in perspective)\n");
+ SLOGI(" SCALING\n");
+ SLOGI(" scale_mode : %s\n", scaling->mode == 0 ?
+ "NO_SCALING" :
+ (scaling->mode == 1 ? "SCALING_NEAREST" : "SCALING_BILINEAR"));
+ SLOGI(" src : (src_w, src_h) = (%d, %d)\n", scaling->src_w, scaling->src_h);
+ SLOGI(" dst : (dst_w, dst_h) = (%d, %d)\n", scaling->dst_w, scaling->dst_h);
+ SLOGI(" scaling_factor : (scale_w, scale_y) = (%3.2f, %3.2f)\n", (double)scaling->dst_w / scaling->src_w, (double)scaling->dst_h / scaling->src_h);
}