From 4d1cf25ae54addd1fd47ae2737efeecfaf7e5684 Mon Sep 17 00:00:00 2001 From: Calixte DENIZET Date: Thu, 31 Oct 2013 17:11:08 +0100 Subject: [PATCH] Graphics: Matplot broken after uid refactor Change-Id: Ia4916be0b4833c2535355d682ba2fc5f108da828 --- .../graphic_objects/src/cpp/MatPlotDecomposer.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/scilab/modules/graphic_objects/src/cpp/MatPlotDecomposer.cpp b/scilab/modules/graphic_objects/src/cpp/MatPlotDecomposer.cpp index ed5d4a2..2d4e4ad 100644 --- a/scilab/modules/graphic_objects/src/cpp/MatPlotDecomposer.cpp +++ b/scilab/modules/graphic_objects/src/cpp/MatPlotDecomposer.cpp @@ -50,6 +50,7 @@ int MatPlotDecomposer::fillTextureData(int id, unsigned char* buffer, int buffer // Indexed colors void * data = NULL; int parentFigure = 0; + int * piParentFigure = &parentFigure; double * colormap = NULL; int colormapSize = 0; int * piColormapSize = &colormapSize; @@ -60,7 +61,7 @@ int MatPlotDecomposer::fillTextureData(int id, unsigned char* buffer, int buffer getGraphicObjectProperty(id, __GO_DATA_MODEL_Z__, jni_double_vector, &data); getGraphicObjectProperty(id, __GO_DATA_MODEL_MATPLOT_DATA_TYPE__, jni_int, (void**) &pidataType); - getGraphicObjectProperty(id, __GO_PARENT_FIGURE__, jni_string, (void**) &parentFigure); + getGraphicObjectProperty(id, __GO_PARENT_FIGURE__, jni_int, (void**) &piParentFigure); getGraphicObjectProperty(parentFigure, __GO_COLORMAP__, jni_double_vector, (void**) &colormap); getGraphicObjectProperty(parentFigure, __GO_COLORMAP_SIZE__, jni_int, (void**) &piColormapSize); @@ -153,10 +154,11 @@ int MatPlotDecomposer::fillTextureData(int id, unsigned char* buffer, int buffer if (width * height * 4 == bufferLength) { int parentFigure = 0; + int * piParentFigure = &parentFigure; double* colormap = NULL; int colormapSize = 0; int* piColormapSize = &colormapSize; - getGraphicObjectProperty(id, __GO_PARENT_FIGURE__, jni_string, (void**) &parentFigure); + getGraphicObjectProperty(id, __GO_PARENT_FIGURE__, jni_int, (void**) &piParentFigure); getGraphicObjectProperty(parentFigure, __GO_COLORMAP__, jni_double_vector, (void**) &colormap); getGraphicObjectProperty(parentFigure, __GO_COLORMAP_SIZE__, jni_int, (void**) &piColormapSize); int textureHeight = getTextureHeight(id); -- 1.7.9.5