misc.h
1 // Copyright (c) Tech Soft 3D
2 //
3 // The information contained herein is confidential and proprietary to Tech Soft 3D, Inc.,
4 // and considered a trade secret as defined under civil and criminal statutes.
5 // Tech Soft 3D, Inc. shall pursue its civil and criminal remedies in the event of
6 // unauthorized use or misappropriation of its trade secrets. Use of this information
7 // by anyone other than authorized employees of Tech Soft 3D, Inc. is granted only under
8 // a written non-disclosure agreement, expressly prescribing the scope and manner of such use.
9 
10 #pragma once
11 
12 #include <dbcolor.h>
13 #include <dbents.h>
14 #include <gevec3d.h>
15 #include <hc.h>
16 
17 #include <set>
18 #include <map>
19 
20 HC_KEY My_Insert_Circle(double const * ip1, double const * ip2, double const * ip3);
21 void copy_dwg_matrix(float matrix[16], AcGeMatrix3d const & autocad_matrix);
22 void calculate_alignment(AcDbText * in_text, char * out_alignment);
23 void calculate_alignment(AcDbMText::AttachmentPoint attachmentPoint, char * out_alignment);
24 void insert_arrow(AcGePoint3d startPoint, AcGePoint3d endPoint);
25 
26 #define DWG_HASH_BYTES 16
27 #define DWG_HASH_SIZE 2*DWG_HASH_BYTES+1
28 
29 struct mTextData
30 {
31 public:
32  std::map<AcDbHandle, HC_KEY> mtext_handles;
33  std::set<HC_KEY> mtext_segments;
34 };
35 
36 class DWG_HASH
37 {
38 private:
39  char m_str[DWG_HASH_SIZE];
40 public:
41  DWG_HASH(void const * input, size_t const len);
42  ~DWG_HASH();
43 
44  operator const char* () const;
45 };
46 
47 bool applyColor(AcCmEntityColor const & color, bool open_segment = false);
Definition: misc.h:36
#define HC_KEY
Definition: misc.h:29