- Set default value for TEXT_ATTR in barcode generate 81/56981/2 accepted/tizen/mobile/20160115.111633 accepted/tizen/tv/20160115.111657 accepted/tizen/wearable/20160115.111707 submit/tizen/20160115.043907
authorSeokHoon Lee <andy.shlee@samsung.com>
Thu, 14 Jan 2016 06:07:17 +0000 (15:07 +0900)
committerSeokHoon Lee <andy.shlee@samsung.com>
Thu, 14 Jan 2016 06:10:50 +0000 (15:10 +0900)
- Fix parameter for  draw_rectangle_on_buffer in test suite

Signed-off-by: SeokHoon Lee <andy.shlee@samsung.com>
Change-Id: I8c139164bf9b9c74e84489879575594e0f68d4da

mv_barcode/barcode_generator/src/mv_barcode_generate_open.cpp
packaging/capi-media-vision.spec
test/testsuites/barcode/barcode_test_suite.c

index 44c68b2..444ceb3 100644 (file)
@@ -316,15 +316,18 @@ int mv_barcode_generate_image_open(
        }
 
        int showText = 0;
-       error = mv_engine_config_get_int_attribute(engine_cfg, "MV_BARCODE_GENERATE_ATTR_TEXT", &showText);
-       if (error != MEDIA_VISION_ERROR_NONE) {
-               LOGW("mv_engine_config_get_int_attribute failed");
-               return error;
-       }
 
-       if (showText == BARCODE_GEN_TEXT_VISIBLE && type == MV_BARCODE_QR) {
-               LOGW("QR code generation with visible text is not supported");
-               return MEDIA_VISION_ERROR_INVALID_OPERATION;
+       if (engine_cfg != NULL) {
+               error = mv_engine_config_get_int_attribute(engine_cfg, "MV_BARCODE_GENERATE_ATTR_TEXT", &showText);
+               if (error != MEDIA_VISION_ERROR_NONE) {
+                       LOGW("mv_engine_config_get_int_attribute failed");
+                       return error;
+               }
+
+               if (showText == BARCODE_GEN_TEXT_VISIBLE && type == MV_BARCODE_QR) {
+                       LOGW("QR code generation with visible text is not supported");
+                       return MEDIA_VISION_ERROR_INVALID_OPERATION;
+               }
        }
 
        error = BarcodeGenerator::generateBarcodeToImage(
index d7261c8..d53e0ba 100644 (file)
@@ -1,6 +1,6 @@
 Name:        capi-media-vision
 Summary:     Media Vision library for Tizen Native API
-Version:     0.3.5
+Version:     0.3.6
 Release:     0
 Group:       Multimedia/Framework
 License:     Apache-2.0 and BSD-2.0
index 52f845f..1c69eac 100644 (file)
@@ -357,15 +357,15 @@ void barcode_detected_cb(
                                        continue;
                                }
 
-                               const int rectangle_thickness = 6;
                                const int drawing_color[] = {255, 0, 0};
+
                                if (MEDIA_VISION_ERROR_NONE != draw_rectangle_on_buffer(
                                        minX,
                                        minY,
                                        maxX,
                                        maxY,
+                                       6,
                                        drawing_color,
-                                       rectangle_thickness,
                                        &image_data,
                                        draw_buffer)) {
                                        continue;