diff options
author | SeokHoon Lee <andy.shlee@samsung.com> | 2016-01-14 15:07:17 +0900 |
---|---|---|
committer | SeokHoon Lee <andy.shlee@samsung.com> | 2016-01-14 15:10:50 +0900 |
commit | 68fee1fd89593908e8652e792fb6eba2dadcb8de (patch) | |
tree | 6d1f153aa7f305c2136ae838a527eedf70bc339d | |
parent | afb6b094a661099c6715e0760212526aa5a4939e (diff) | |
download | mediavision-68fee1fd89593908e8652e792fb6eba2dadcb8de.tar.gz mediavision-68fee1fd89593908e8652e792fb6eba2dadcb8de.tar.bz2 mediavision-68fee1fd89593908e8652e792fb6eba2dadcb8de.zip |
- Set default value for TEXT_ATTR in barcode generatesubmit/tizen/20160115.043907accepted/tizen/wearable/20160115.111707accepted/tizen/tv/20160115.111657accepted/tizen/mobile/20160115.111633
- Fix parameter for draw_rectangle_on_buffer in test suite
Signed-off-by: SeokHoon Lee <andy.shlee@samsung.com>
Change-Id: I8c139164bf9b9c74e84489879575594e0f68d4da
-rw-r--r-- | mv_barcode/barcode_generator/src/mv_barcode_generate_open.cpp | 19 | ||||
-rw-r--r-- | packaging/capi-media-vision.spec | 2 | ||||
-rw-r--r-- | test/testsuites/barcode/barcode_test_suite.c | 4 |
3 files changed, 14 insertions, 11 deletions
diff --git a/mv_barcode/barcode_generator/src/mv_barcode_generate_open.cpp b/mv_barcode/barcode_generator/src/mv_barcode_generate_open.cpp index 44c68b22..444ceb3a 100644 --- a/mv_barcode/barcode_generator/src/mv_barcode_generate_open.cpp +++ b/mv_barcode/barcode_generator/src/mv_barcode_generate_open.cpp @@ -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( diff --git a/packaging/capi-media-vision.spec b/packaging/capi-media-vision.spec index d7261c8a..d53e0ba9 100644 --- a/packaging/capi-media-vision.spec +++ b/packaging/capi-media-vision.spec @@ -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 diff --git a/test/testsuites/barcode/barcode_test_suite.c b/test/testsuites/barcode/barcode_test_suite.c index 52f845f6..1c69eac5 100644 --- a/test/testsuites/barcode/barcode_test_suite.c +++ b/test/testsuites/barcode/barcode_test_suite.c @@ -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; |