[0.6.231] Fix typo error
[platform/core/multimedia/libmm-player.git] / src / mm_player_capture.c
index de46ba4..0297b6e 100644 (file)
@@ -45,7 +45,7 @@
 static GstPadProbeReturn __mmplayer_video_capture_probe(GstPad *pad, GstPadProbeInfo *info, gpointer u_data);
 static int  __mmplayer_get_video_frame_from_buffer(mmplayer_t *player, GstPad *pad, GstBuffer *buffer);
 static gpointer __mmplayer_capture_thread(gpointer data);
-static void __csc_tiled_to_linear_crop(unsigned char *yuv420_dest, unsigned char *nv12t_src, int yuv420_width, int yuv420_height, int left, int top, int right, int buttom);
+static void __csc_tiled_to_linear_crop(unsigned char *yuv420_dest, unsigned char *nv12t_src, int yuv420_width, int yuv420_height, int left, int top, int right, int bottom);
 static int __tile_4x2_read(int x_size, int y_size, int x_pos, int y_pos);
 static int __mm_player_convert_colorspace(mmplayer_t *player, unsigned char *src_data, size_t src_size, mm_util_color_format_e src_fmt, unsigned int src_w, unsigned int src_h, mm_util_color_format_e dst_fmt);
 static int __mm_player_convert_NV12_tiled(mmplayer_t *player);
@@ -102,7 +102,7 @@ _mmplayer_release_video_capture(mmplayer_t *player)
        MMPLAYER_CAPTURE_THREAD_SIGNAL(player);
        MMPLAYER_CAPTURE_THREAD_UNLOCK(player);
 
-       LOGD("waitting for capture thread exit");
+       LOGD("waiting for capture thread exit");
        g_thread_join(player->capture_thread);
        g_mutex_clear(&player->capture_thread_mutex);
        g_cond_clear(&player->capture_thread_cond);
@@ -511,10 +511,10 @@ __mm_player_convert_colorspace(mmplayer_t *player, unsigned char *src_data, size
  *   height of tiled[in]
  *
  * @param x_pos
- *   x position of tield[in]
+ *   x position of tiled[in]
  *
  * @param src_size
- *   y position of tield[in]
+ *   y position of tiled[in]
  *
  * @return
  *   address of tiled data
@@ -562,7 +562,7 @@ __tile_4x2_read(int x_size, int y_size, int x_pos, int y_pos)
 
 /*
  * Converts tiled data to linear
- * Crops left, top, right, buttom
+ * Crops left, top, right, bottom
  * 1. Y of NV12T to Y of YUV420P
  * 2. Y of NV12T to Y of YUV420S
  * 3. UV of NV12T to UV of YUV420S
@@ -588,12 +588,12 @@ __tile_4x2_read(int x_size, int y_size, int x_pos, int y_pos)
  * @param right
  *   Crop size of right
  *
- * @param buttom
- *   Crop size of buttom
+ * @param bottom
+ *   Crop size of bottom
  */
 static void
 __csc_tiled_to_linear_crop(unsigned char *yuv420_dest, unsigned char *nv12t_src, int yuv420_width, int yuv420_height,
-                                                       int left, int top, int right, int buttom)
+                                                       int left, int top, int right, int bottom)
 {
        int i, j;
        int tiled_offset = 0, tiled_offset1 = 0;
@@ -604,13 +604,13 @@ __csc_tiled_to_linear_crop(unsigned char *yuv420_dest, unsigned char *nv12t_src,
        temp1 = temp3-left;
        /* real width is greater than or equal 256 */
        if (temp1 >= 256) {
-               for (i = top; i < yuv420_height-buttom; i = i+1) {
+               for (i = top; i < yuv420_height-bottom; i = i+1) {
                        j = left;
                        temp3 = (j >> 8) << 8;
                        temp3 = temp3 >> 6;
                        temp4 = i >> 5;
                        if (temp4 & 0x1) {
-                               /* odd fomula: 2 + x + (x >> 2) << 2 + x_block_num * (y - 1) */
+                               /* odd formula: 2 + x + (x >> 2) << 2 + x_block_num * (y - 1) */
                                tiled_offset = temp4 - 1;
                                temp1 = ((yuv420_width + 127) >> 7) << 7;
                                tiled_offset = tiled_offset * (temp1 >> 6);
@@ -624,7 +624,7 @@ __csc_tiled_to_linear_crop(unsigned char *yuv420_dest, unsigned char *nv12t_src,
                        } else {
                                temp2 = ((yuv420_height+31) >> 5) << 5;
                                if ((i + 32) < temp2) {
-                                       /* even1 fomula: x + ((x + 2) >> 2) << 2 + x_block_num * y */
+                                       /* even1 formula: x + ((x + 2) >> 2) << 2 + x_block_num * y */
                                        temp1 = temp3 + 2;
                                        temp1 = (temp1 >> 2) << 2;
                                        tiled_offset = temp3 + temp1;
@@ -634,7 +634,7 @@ __csc_tiled_to_linear_crop(unsigned char *yuv420_dest, unsigned char *nv12t_src,
                                        tiled_offset1 = tiled_offset + 2048 * 6;
                                        temp4 = 8;
                                } else {
-                                       /* even2 fomula: x + x_block_num * y */
+                                       /* even2 formula: x + x_block_num * y */
                                        temp1 = ((yuv420_width + 127) >> 7) << 7;
                                        tiled_offset = temp4 * (temp1 >> 6);
                                        tiled_offset = tiled_offset + temp3;
@@ -705,7 +705,7 @@ __csc_tiled_to_linear_crop(unsigned char *yuv420_dest, unsigned char *nv12t_src,
                        }
                }
        } else if (temp1 >= 64) {
-               for (i = top; i < (yuv420_height - buttom); i++) {
+               for (i = top; i < (yuv420_height - bottom); i++) {
                        j = left;
                        tiled_offset = __tile_4x2_read(yuv420_width, yuv420_height, j, i);
                        temp2 = ((j + 64) >> 6) << 6;
@@ -735,7 +735,7 @@ __csc_tiled_to_linear_crop(unsigned char *yuv420_dest, unsigned char *nv12t_src,
                        }
                }
        } else {
-               for (i = top; i < (yuv420_height - buttom); i++) {
+               for (i = top; i < (yuv420_height - bottom); i++) {
                        linear_offset = temp1 * (i - top);
                        for (j = left; j < (yuv420_width - right); j += 2) {
                                tiled_offset = __tile_4x2_read(yuv420_width, yuv420_height, j, i);
@@ -841,7 +841,7 @@ __mm_player_convert_NV12(mmplayer_t *player)
        int ret = MM_ERROR_NONE;
        int i, j;
 
-       /* using original width otherwises, app can't know aligned to resize */
+       /* using original width otherwise, app can't know aligned to resize */
        planes[0] =  player->captured.stride_width[0] * player->captured.stride_height[0];
        planes[1] = player->captured.stride_width[1] * player->captured.stride_height[1];
        guint src_buffer_size = planes[0] + planes[1];
@@ -898,7 +898,7 @@ __mm_player_convert_I420(mmplayer_t *player)
        int ret = MM_ERROR_NONE;
        int i;
 
-       /* using original width otherwises, app can't know aligned to resize */
+       /* using original width otherwise, app can't know aligned to resize */
        planes[0] = player->captured.stride_width[0] * player->captured.stride_height[0];
        planes[1] = planes[2] = (player->captured.stride_width[0] >> 1)
                                                                * (player->captured.stride_height[0] >> 1);