TexGen
PatternDraft.h
Go to the documentation of this file.
1/*=============================================================================
2TexGen: Geometric textile modeller.
3Copyright (C) 2014 Louise Brown
4
5This program is free software; you can redistribute it and/or
6modify it under the terms of the GNU General Public License
7as published by the Free Software Foundation; either version 2
8of the License, or (at your option) any later version.
9
10This program is distributed in the hope that it will be useful,
11but WITHOUT ANY WARRANTY; without even the implied warranty of
12MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13GNU General Public License for more details.
14
15You should have received a copy of the GNU General Public License
16along with this program; if not, write to the Free Software
17Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18=============================================================================*/
19
20#pragma once
21
22
23namespace TexGen
24{
25 using namespace std;
26
30 {
31 public:
33 virtual ~CPatternDraft(void);
34
36 void AddRow( string Row );
37 void ClearWeavePattern();
38 int GetNumWarps();
39 int GetNumWefts();
40 int GetNumHeddles() { return m_NumHeddles; }
42 void Output( string Filename );
44 bool CreatePatternDraft();
45 const vector<string>& GetWeavePattern() {return m_WeavePattern;}
46 const vector<int>& GetHeddleDraft() { return m_HeddleDraft; }
47 const vector<bool>& GetChainDraft() { return m_ChainDraft; }
48
49 protected:
51 void CreateColumnsVector();
53 bool CreateHeddleDraft();
57 bool CreateChainDraft();
58
59 vector<string> m_WeavePattern;
60 vector<string> m_Columns;
61 vector<string> m_UniqueColumns;
62 vector<int> m_HeddleDraft;
63 vector<bool> m_ChainDraft;
65 };
66
67}; // namespace TexGen
#define CLASS_DECLSPEC
Definition: Misc.h:35
vector< string > m_Columns
Definition: PatternDraft.h:60
const vector< int > & GetHeddleDraft()
Definition: PatternDraft.h:46
const vector< string > & GetWeavePattern()
Definition: PatternDraft.h:45
vector< bool > m_ChainDraft
Definition: PatternDraft.h:63
vector< string > m_UniqueColumns
Definition: PatternDraft.h:61
vector< int > m_HeddleDraft
Definition: PatternDraft.h:62
const vector< bool > & GetChainDraft()
Definition: PatternDraft.h:47
vector< string > m_WeavePattern
Definition: PatternDraft.h:59
Namespace containing a series of customised math operations not found in the standard c++ library.