From 25ce805a58fa833cf9c4e818f34d9664de1f3636 Mon Sep 17 00:00:00 2001 From: Tamito Kajiyama Date: Mon, 26 Jul 2010 01:23:27 +0000 Subject: * Implemented the basic stroke rendering functionality for the new Parameter Editor mode. This is a WIP commit. Only the base line color, base alpha transparency, and base line thickness are respected. More additions are anticipated to account for other parameters. * Added FRS_finish_stroke_rendering() to clean Freestyle-related temporary resources after stroke rendering. * Some functions in FRS_freestyle.cpp are now declared as static functions, so as not to mess up the program-wide name space. * Made the StyleModule class inheritable, and defined new subclass BlenderStyleModule that takes a Text object instead of a file name. --- source/blender/freestyle/intern/stroke/StyleModule.h | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'source/blender/freestyle/intern/stroke/StyleModule.h') diff --git a/source/blender/freestyle/intern/stroke/StyleModule.h b/source/blender/freestyle/intern/stroke/StyleModule.h index c023ad7517b..5bdb54cf16c 100755 --- a/source/blender/freestyle/intern/stroke/StyleModule.h +++ b/source/blender/freestyle/intern/stroke/StyleModule.h @@ -54,7 +54,7 @@ public: _inter = inter; } - ~StyleModule() {} + virtual ~StyleModule() {} StrokeLayer* execute() { if (!_inter) { @@ -69,7 +69,7 @@ public: Operators::reset(); - if( _inter->interpretFile(_file_name) ) { + if( interpret() ) { cerr << "Error: interpretation failed" << endl; return NULL; } @@ -89,6 +89,14 @@ public: return sl; } +protected: + + virtual int interpret() { + return _inter->interpretFile(_file_name); + } + +public: + // accessors const string getFileName() const { @@ -151,6 +159,9 @@ private: bool _drawable; bool _modified; bool _displayed; + +protected: + Interpreter* _inter; }; -- cgit v1.2.3