Extended .NET SDK Documentation 2024 SP0
Loading...
Searching...
No Matches
OdGiBitonalRasterTransformer.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
17 private Object locker = new Object();
18 private HandleRef swigCPtr;
19 [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
20 public OdGiBitonalRasterTransformer(IntPtr cPtr, bool cMemoryOwn) : base(GlobalsPINVOKE.OdGiBitonalRasterTransformer_SWIGUpcast(cPtr), cMemoryOwn) {
21 swigCPtr = new HandleRef(this, cPtr);
22 }
23
24 [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Never)]
25 public static HandleRef getCPtr(OdGiBitonalRasterTransformer obj) {
26 return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
27 }
28
29 protected override void Dispose(bool disposing) {
30 lock(this) {
31 if (swigCPtr.Handle != global::System.IntPtr.Zero) {
32 if (swigCMemOwn) {
33 swigCMemOwn = false;
35 }
36 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
37 }
38 base.Dispose(disposing);
39 }
40 }
41
42 public static OdGiRasterImage createObject(OdGiRasterImage pOrig, UInt32 /*SIMPLETYPE*/ foregroundColor, UInt32 /*SIMPLETYPE*/ backgroundColor, bool transparent) {// OdGiRasterImagePtr
43 MemoryManager mMan = MemoryManager.GetMemoryManager();
44 MemoryTransaction mTrans = mMan.GetCurrentTransaction(); // MemoryTransaction #17
45 IntPtr ptr = GlobalsPINVOKE.OdGiBitonalRasterTransformer_createObject(OdGiRasterImage.getCPtr(pOrig), foregroundColor /*SIMPLETYPE*/, backgroundColor /*SIMPLETYPE*/, transparent);
46
47 OdGiRasterImage ret = null;
48 if (null != mTrans)
49 {
50 mTrans.AddObject((OdGiRasterImage)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdGiRasterImage),ptr, true));
51 ret = (OdGiRasterImage)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdGiRasterImage),ptr, false);
52 }
53 else
54 {
55 ret = (OdGiRasterImage)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdGiRasterImage),ptr, true);
56 }
57
59 return ret;
60}
61
62 public void setOriginal(OdGiRasterImage pOrig, UInt32 /*SIMPLETYPE*/ foregroundColor, UInt32 /*SIMPLETYPE*/ backgroundColor, bool transparent) {
63 GlobalsPINVOKE.OdGiBitonalRasterTransformer_setOriginal(swigCPtr, OdGiRasterImage.getCPtr(pOrig), foregroundColor /*SIMPLETYPE*/, backgroundColor /*SIMPLETYPE*/, transparent);
65 }
66
67 public override UInt32 numColors() {
68// test csout
69 /*SIMPLETYPE*/
72 return ret;
73 }
74
75 public override UInt32 color(UInt32 /*SIMPLETYPE*/ colorIndex) {
76// test csout
77 /*SIMPLETYPE*/
78 UInt32 ret = GlobalsPINVOKE.OdGiBitonalRasterTransformer_color(swigCPtr, colorIndex /*SIMPLETYPE*/);
80 return ret;
81 }
82
83 public override UInt32 paletteDataSize() {
84// test csout
85 /*SIMPLETYPE*/
88 return ret;
89 }
90
91 public override void paletteData(ref byte[] /*OUT_ARRAY*/ bytes) {
92IntPtr p_bytes=Teigha.Core.Helpers.MarshalbyteFixedArray(bytes);
93 try {
96 } finally {
97bytes = Teigha.Core.Helpers.UnMarshalbyteFixedArray(p_bytes); Marshal.FreeCoTaskMem(p_bytes);
98 }
99 }
100
104 return ret;
105 }
106
107 public override int transparentColor() {
110 return ret;
111 }
112
113 public override OdRxObject clone() {// OdRxObjectPtr
114 MemoryManager mMan = MemoryManager.GetMemoryManager();
115 MemoryTransaction mTrans = mMan.GetCurrentTransaction(); // MemoryTransaction #17
117
118 OdRxObject ret = null;
119 if (null != mTrans)
120 {
121 mTrans.AddObject((OdRxObject)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdRxObject),ptr, true));
122 ret = (OdRxObject)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdRxObject),ptr, false);
123 }
124 else
125 {
126 ret = (OdRxObject)Teigha.Core.Helpers.odrxCreateObjectInternalUniversal(typeof(OdRxObject),ptr, true);
127 }
128
130 return ret;
131}
132
133 public override void copyFrom(OdRxObject pSource) {
136 }
137
138 protected static string getRealClassName(IntPtr /*SIMPLETYPE*/ ptr) {
139 string ret = GlobalsPINVOKE.OdGiBitonalRasterTransformer_getRealClassName(ptr /*SIMPLETYPE*/);
141 return ret;
142 }
143
149
155
156}
157
158}
static global::System.Exception Retrieve()
static void OdGiBitonalRasterTransformer_paletteData(HandleRef jarg1, IntPtr jarg2)
static IntPtr OdGiBitonalRasterTransformer_createObject(HandleRef jarg1, UInt32 jarg2, UInt32 jarg3, bool jarg4)
static string OdGiBitonalRasterTransformer_getRealClassName(IntPtr jarg1)
static void OdGiBitonalRasterTransformer_copyFrom(HandleRef jarg1, HandleRef jarg2)
static void delete_OdGiBitonalRasterTransformer(HandleRef jarg1)
static IntPtr OdGiBitonalRasterTransformer_clone(HandleRef jarg1)
static UInt32 OdGiBitonalRasterTransformer_numColors(HandleRef jarg1)
static int OdGiBitonalRasterTransformer_transparentColor(HandleRef jarg1)
static void OdGiBitonalRasterTransformer_setOriginal(HandleRef jarg1, HandleRef jarg2, UInt32 jarg3, UInt32 jarg4, bool jarg5)
static UInt32 OdGiBitonalRasterTransformer_paletteDataSize(HandleRef jarg1)
static global::System.IntPtr OdGiBitonalRasterTransformer_pixelFormat(HandleRef jarg1)
static UInt32 OdGiBitonalRasterTransformer_color(HandleRef jarg1, UInt32 jarg2)
static OdGiRasterImage createObject(OdGiRasterImage pOrig, UInt32 foregroundColor, UInt32 backgroundColor, bool transparent)
override OdGiRasterImage.PixelFormatInfo pixelFormat()
OdGiBitonalRasterTransformer(IntPtr cPtr, bool cMemoryOwn)
override Teigha.Core.OdGiRasterImage.ImageSource vb_imageSource()
override Teigha.Core.OdGiRasterImage.TransparencyMode vb_transparencyMode()
static HandleRef getCPtr(OdGiBitonalRasterTransformer obj)
void setOriginal(OdGiRasterImage pOrig, UInt32 foregroundColor, UInt32 backgroundColor, bool transparent)
static HandleRef getCPtr(OdGiRasterImage obj)
override OdGiRasterImage.ImageSource imageSource()
override OdGiRasterImage.TransparencyMode transparencyMode()
static HandleRef getCPtr(OdRxObject obj)
Definition: OdRxObject.cs:26