Extended .NET SDK Documentation 2024 SP0
Loading...
Searching...
No Matches
Dwf3dExportParams.cs
Go to the documentation of this file.
1//------------------------------------------------------------------------------
2// <auto-generated />
3//
4// This file was automatically generated by SWIG (http://www.swig.org).
5// Version 4.0.2
6//
7// Do not make changes to this file unless you know what you are doing--modify
8// the SWIG interface file instead.
9//------------------------------------------------------------------------------
10
11namespace Teigha.Core {
12
13using System;
14using System.Runtime.InteropServices;
15
16public class Dwf3dExportParams : global::System.IDisposable {
17 private Object locker = new Object();
18 private HandleRef swigCPtr;
19 protected bool swigCMemOwn;
20 [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
21 public Dwf3dExportParams(IntPtr cPtr, bool cMemoryOwn) {
22 swigCMemOwn = cMemoryOwn;
23 swigCPtr = new HandleRef(this, cPtr);
24 }
25 [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
26 public static HandleRef getCPtr(Dwf3dExportParams obj) {
27 return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
28 }
29
31 Dispose(false);
32 }
33
34 public void Dispose() {
35 Dispose(true);
36 global::System.GC.SuppressFinalize(this);
37 }
38
39 protected virtual void Dispose(bool disposing) {
40 lock(this) {
41 if (swigCPtr.Handle != global::System.IntPtr.Zero) {
42 if (swigCMemOwn) {
43 swigCMemOwn = false;
45 }
46 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
47 }
48 }
49 }
50
51 private static UInt32[] UnMarshalPalette(IntPtr p)
52 {
53 if (p == IntPtr.Zero)
54 return null;
55 UInt32[] res = new UInt32[256];
56 for (int i = 0; i < 256; ++i)
57 {
58 res[i] = (UInt32)Marshal.ReadInt32(p, i * 4);
59 }
60 return res;
61 }
62 private static IntPtr MarshalPalette(UInt32[] p)
63 {
64 if (p == null)
65 return IntPtr.Zero;
66 if (p.Length != 256)
67 throw new Exception("MarshalPalette: palette size must be 256");
68 IntPtr res = Marshal.AllocCoTaskMem(256 * 4);
69 for (int i = 0; i < 256; ++i)
70 {
71 Marshal.WriteInt32(res, i * 4, (Int32)p[i]);
72 }
73 return res;
74 }
75
76 public UInt32[] Palette
77 {
78 get
79 {
80 return UnMarshalPalette(GlobalsPINVOKE.Dwf3dExportParams_getPalette(swigCPtr));
81 }
82 set
83 {
84 IntPtr p = MarshalPalette(value);
86 Marshal.FreeCoTaskMem(p);
87 }
88 }
89
90 public Dwf3dExportParams() : this(GlobalsPINVOKE.new_Dwf3dExportParams(), true) {
92 }
93
94 public OdRxObject database() {
95 OdRxObject ret = (OdRxObject)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdRxObject),GlobalsPINVOKE.Dwf3dExportParams_database(swigCPtr),false); /*createInt 3_2*/
96
98 return ret;
99}
100
101 public void setDatabase(OdRxObject pDb) {
104 }
105
106 public void setDwfFileName(String sDwfFileName) {
107 GlobalsPINVOKE.Dwf3dExportParams_setDwfFileName(swigCPtr, sDwfFileName);
109 }
110
112 string ret = GlobalsPINVOKE.Dwf3dExportParams_dwfFileName(swigCPtr);
114 return ret;
115}
116
117 public void setXSize(Int32 /*SIMPLETYPE*/ iValue) {
118 GlobalsPINVOKE.Dwf3dExportParams_setXSize(swigCPtr, iValue /*SIMPLETYPE*/);
120 }
121
122 public Int32 xSize() {
123// test csout
124 /*SIMPLETYPE*/
125 Int32 ret = GlobalsPINVOKE.Dwf3dExportParams_xSize(swigCPtr);
127 return ret;
128 }
129
130 public void setYSize(Int32 /*SIMPLETYPE*/ iValue) {
131 GlobalsPINVOKE.Dwf3dExportParams_setYSize(swigCPtr, iValue /*SIMPLETYPE*/);
133 }
134
135 public Int32 ySize() {
136// test csout
137 /*SIMPLETYPE*/
138 Int32 ret = GlobalsPINVOKE.Dwf3dExportParams_ySize(swigCPtr);
140 return ret;
141 }
142
143 public void setBackground(UInt32 /*SIMPLETYPE*/ background) {
146 }
147
148 public UInt32 background() {
149// test csout
150 /*SIMPLETYPE*/
151 UInt32 ret = GlobalsPINVOKE.Dwf3dExportParams_background(swigCPtr);
153 return ret;
154 }
155
156 public void setTitle(String sTitle) {
159 }
160
161 public String title() {
162 string ret = GlobalsPINVOKE.Dwf3dExportParams_title(swigCPtr);
164 return ret;
165}
166
170 }
171
175 return ret;
176 }
177
178}
179
180}
Dwf3dExportParams(IntPtr cPtr, bool cMemoryOwn)
virtual void Dispose(bool disposing)
void setThumbnail(ImageResource thumbnail)
void setDwfFileName(String sDwfFileName)
void setBackground(UInt32 background)
void setDatabase(OdRxObject pDb)
static HandleRef getCPtr(Dwf3dExportParams obj)
static global::System.Exception Retrieve()
static void delete_Dwf3dExportParams(global::System.Runtime.InteropServices.HandleRef jarg1)
static IntPtr Dwf3dExportParams_database(global::System.Runtime.InteropServices.HandleRef jarg1)
static void Dwf3dExportParams_setDatabase(global::System.Runtime.InteropServices.HandleRef jarg1, HandleRef jarg2)
static String Dwf3dExportParams_dwfFileName(global::System.Runtime.InteropServices.HandleRef jarg1)
static global::System.IntPtr Dwf3dExportParams_thumbnail(global::System.Runtime.InteropServices.HandleRef jarg1)
static IntPtr Dwf3dExportParams_getPalette(HandleRef jarg1)
static void Dwf3dExportParams_setYSize(global::System.Runtime.InteropServices.HandleRef jarg1, Int32 jarg2)
static UInt32 Dwf3dExportParams_background(global::System.Runtime.InteropServices.HandleRef jarg1)
static void Dwf3dExportParams_setDwfFileName(global::System.Runtime.InteropServices.HandleRef jarg1, [MarshalAs(UnmanagedType.LPWStr)]String jarg2)
static String Dwf3dExportParams_title(global::System.Runtime.InteropServices.HandleRef jarg1)
static void Dwf3dExportParams_setThumbnail(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2)
static Int32 Dwf3dExportParams_xSize(global::System.Runtime.InteropServices.HandleRef jarg1)
static void Dwf3dExportParams_setPalette(HandleRef jarg1, IntPtr jarg2)
static void Dwf3dExportParams_setBackground(global::System.Runtime.InteropServices.HandleRef jarg1, UInt32 jarg2)
static void Dwf3dExportParams_setTitle(global::System.Runtime.InteropServices.HandleRef jarg1, [MarshalAs(UnmanagedType.LPWStr)]String jarg2)
static Int32 Dwf3dExportParams_ySize(global::System.Runtime.InteropServices.HandleRef jarg1)
static void Dwf3dExportParams_setXSize(global::System.Runtime.InteropServices.HandleRef jarg1, Int32 jarg2)
static HandleRef getCPtr(ImageResource obj)
static HandleRef getCPtr(OdRxObject obj)
Definition: OdRxObject.cs:26