From: Hermet Park Date: Thu, 13 Aug 2020 10:02:31 +0000 (+0900) Subject: gl_engine renderer: initialize member data in default. X-Git-Tag: submit/tizen/20200813.110752~9 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F79%2F240979%2F1;p=platform%2Fcore%2Fgraphics%2Ftizenvg.git gl_engine renderer: initialize member data in default. static analizyer bothers us due to this. we'd rather initialize members for free of them. Change-Id: Ifa6ebffdfdcb31d2dd3a1d6b911226928f654e3f --- diff --git a/src/lib/gl_engine/tvgGlRenderer.h b/src/lib/gl_engine/tvgGlRenderer.h index 9c893b3..9a86bae 100644 --- a/src/lib/gl_engine/tvgGlRenderer.h +++ b/src/lib/gl_engine/tvgGlRenderer.h @@ -30,7 +30,7 @@ class GlRenderer : public RenderMethod { public: - Surface surface; + Surface surface = {nullptr, 0, 0, 0}; void* prepare(const Shape& shape, void* data, const RenderTransform* transform, RenderUpdateFlag flags) override; bool dispose(const Shape& shape, void *data) override; @@ -54,9 +54,9 @@ private: void initShaders(); void drawPrimitive(GlGeometry& geometry, float r, float g, float b, float a, uint32_t primitiveIndex, RenderUpdateFlag flag); - unique_ptr mColorProgram; - int32_t mColorUniformLoc; - uint32_t mVertexAttrLoc; + unique_ptr mColorProgram = nullptr; + int32_t mColorUniformLoc = 0; + uint32_t mVertexAttrLoc = 0; }; #endif /* _TVG_GL_RENDERER_H_ */