00001 // $Id: gdraw2.h 751 2006-03-31 15:43:49Z alex $ 00003 // 00004 // GDraw2.h 00005 // 00007 /* @@tag:xara-cn@@ DO NOT MODIFY THIS LINE 00008 ================================XARAHEADERSTART=========================== 00009 00010 Xara LX, a vector drawing and manipulation program. 00011 Copyright (C) 1993-2006 Xara Group Ltd. 00012 Copyright on certain contributions may be held in joint with their 00013 respective authors. See AUTHORS file for details. 00014 00015 LICENSE TO USE AND MODIFY SOFTWARE 00016 ---------------------------------- 00017 00018 This file is part of Xara LX. 00019 00020 Xara LX is free software; you can redistribute it and/or modify it 00021 under the terms of the GNU General Public License version 2 as published 00022 by the Free Software Foundation. 00023 00024 Xara LX and its component source files are distributed in the hope 00025 that it will be useful, but WITHOUT ANY WARRANTY; without even the 00026 implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 00027 See the GNU General Public License for more details. 00028 00029 You should have received a copy of the GNU General Public License along 00030 with Xara LX (see the file GPL in the root directory of the 00031 distribution); if not, write to the Free Software Foundation, Inc., 51 00032 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 00033 00034 00035 ADDITIONAL RIGHTS 00036 ----------------- 00037 00038 Conditional upon your continuing compliance with the GNU General Public 00039 License described above, Xara Group Ltd grants to you certain additional 00040 rights. 00041 00042 The additional rights are to use, modify, and distribute the software 00043 together with the wxWidgets library, the wxXtra library, and the "CDraw" 00044 library and any other such library that any version of Xara LX relased 00045 by Xara Group Ltd requires in order to compile and execute, including 00046 the static linking of that library to XaraLX. In the case of the 00047 "CDraw" library, you may satisfy obligation under the GNU General Public 00048 License to provide source code by providing a binary copy of the library 00049 concerned and a copy of the license accompanying it. 00050 00051 Nothing in this section restricts any of the rights you have under 00052 the GNU General Public License. 00053 00054 00055 SCOPE OF LICENSE 00056 ---------------- 00057 00058 This license applies to this program (XaraLX) and its constituent source 00059 files only, and does not necessarily apply to other Xara products which may 00060 in part share the same code base, and are subject to their own licensing 00061 terms. 00062 00063 This license does not apply to files in the wxXtra directory, which 00064 are built into a separate library, and are subject to the wxWindows 00065 license contained within that directory in the file "WXXTRA-LICENSE". 00066 00067 This license does not apply to the binary libraries (if any) within 00068 the "libs" directory, which are subject to a separate license contained 00069 within that directory in the file "LIBS-LICENSE". 00070 00071 00072 ARRANGEMENTS FOR CONTRIBUTION OF MODIFICATIONS 00073 ---------------------------------------------- 00074 00075 Subject to the terms of the GNU Public License (see above), you are 00076 free to do whatever you like with your modifications. However, you may 00077 (at your option) wish contribute them to Xara's source tree. You can 00078 find details of how to do this at: 00079 http://www.xaraxtreme.org/developers/ 00080 00081 Prior to contributing your modifications, you will need to complete our 00082 contributor agreement. This can be found at: 00083 http://www.xaraxtreme.org/developers/contribute/ 00084 00085 Please note that Xara will not accept modifications which modify any of 00086 the text between the start and end of this header (marked 00087 XARAHEADERSTART and XARAHEADEREND). 00088 00089 00090 MARKS 00091 ----- 00092 00093 Xara, Xara LX, Xara X, Xara X/Xtreme, Xara Xtreme, the Xtreme and Xara 00094 designs are registered or unregistered trademarks, design-marks, and/or 00095 service marks of Xara Group Ltd. All rights in these marks are reserved. 00096 00097 00098 Xara Group Ltd, Gaddesden Place, Hemel Hempstead, HP2 6EX, UK. 00099 http://www.xara.com/ 00100 00101 =================================XARAHEADEREND============================ 00102 */ 00103 00104 enum eBevelStyle { 00105 BEVEL_FLAT, 00106 BEVEL_ROUND, 00107 BEVEL_HALFROUND, 00108 BEVEL_FRAME, 00109 BEVEL_MESA_1, 00110 BEVEL_MESA_2, 00111 BEVEL_SMOOTH_1, 00112 BEVEL_SMOOTH_2, 00113 BEVEL_POINT_1, 00114 BEVEL_POINT_2a, 00115 BEVEL_POINT_2b, 00116 BEVEL_RUFFLE_2a, 00117 BEVEL_RUFFLE_2b, 00118 BEVEL_RUFFLE_3a, 00119 BEVEL_RUFFLE_3b 00120 } ; 00121 /* 00122 enum eError { 00123 GERROR_NO_ERROR, 00124 GERROR_BAD_BITMAP, 00125 GERROR_BAD_GRADUATION_STYLE, 00126 GERROR_BAD_GRADUATION_TABLE, 00127 GERROR_BAD_TILE_STYLE, 00128 GERROR_BAD_TRANSPARENCY_STYLE, 00129 GERROR_BAD_PARAMETERS, 00130 GERROR_BAD_PATH, 00131 GERROR_CORRUPT_EDGE_TABLE, 00132 GERROR_INCOMPATIBLE_BITMAPS, 00133 GERROR_INCOMPATIBLE_REGION, 00134 GERROR_INVALID_SCANLINE_ROUTINE, 00135 GERROR_NO_BITMAP, 00136 GERROR_NOT_32_BITS_PER_PIXEL, 00137 GERROR_OUT_OF_MEMORY, 00138 GERROR_OUTPUT_PATH_TOO_COMPLEX, 00139 GERROR_STACK_OVERFLOW, 00140 GERROR_UNDEFINED_FILL_STYLE, 00141 GERROR_UNDEFINED_MEMORY_HANDLERS, 00142 GERROR_UNIMPLEMENTED, 00143 GERROR_FAILED 00144 } ; 00145 */ 00146 extern "C" 00147 { 00148 extern INT32 GDraw2_GetVersion() ; 00149 00150 extern INT32 GDraw2_ClearLastError() ; 00151 extern eError GDraw2_GetLastError() ; 00152 /* 00153 extern INT32 GDraw2_SetMemoryHandlers( 00154 LPBYTE (*MemoryAlloc)( size_t Size ), 00155 void (*MemoryFree) ( LPBYTE Address ) 00156 ) ; 00157 extern INT32 GDraw2_Terminate() ; 00158 */ 00159 extern INT32 GDraw2_SetDIBitmap( 00160 CONST BITMAPINFOHEADER* pBitmapInfo, 00161 CONST BYTE* pBitmap, 00162 eBevelStyle nBevelStyle, 00163 float LightAngle1, 00164 float LightAngle2 00165 ) ; 00166 extern INT32 GDraw2_FillTriangle( 00167 CONST POINT aPoints[3], 00168 double fNormalX, 00169 double fNormalY 00170 ) ; 00171 extern INT32 GDraw2_FillTrapezium( 00172 CONST POINT aPoints[4], 00173 double fNormalX, 00174 double fNormalY 00175 ) ; 00176 } 00177