Class PaintToOpenGL
Implementation of CADability.IPaintTo3D via OpenGL
Inheritance
System.Object
PaintToOpenGL
Implements
CADability.IPaintTo3D
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetType()
System.Object.MemberwiseClone()
Assembly: CADability.Forms.dll
public class PaintToOpenGL : IPaintTo3D
Constructors
Declaration
public PaintToOpenGL(double precision = 1E-06)
Parameters
| Type |
Name |
Description |
| System.Double |
precision |
|
Fields
activeRenderContexts
Declaration
public static List<IntPtr> activeRenderContexts
Field Value
| Type |
Description |
| System.Collections.Generic.List<System.IntPtr> |
|
ContextsToDelete
Declaration
public static List<IntPtr> ContextsToDelete
Field Value
| Type |
Description |
| System.Collections.Generic.List<System.IntPtr> |
|
Declaration
public static int debugNumTriangles
Field Value
| Type |
Description |
| System.Int32 |
|
MainThread
Declaration
public static Thread MainThread
Field Value
| Type |
Description |
| System.Threading.Thread |
|
Properties
Declaration
public bool UseSharedLists { get; }
Property Value
| Type |
Description |
| System.Boolean |
|
Methods
Declaration
public override bool Equals(object obj)
Parameters
| Type |
Name |
Description |
| System.Object |
obj |
|
Returns
| Type |
Description |
| System.Boolean |
|
Overrides
System.Object.Equals(System.Object)
Declaration
protected void Finalize()
Declaration
public override int GetHashCode()
Returns
| Type |
Description |
| System.Int32 |
|
Overrides
System.Object.GetHashCode()
Declaration
public void Init(Bitmap image)
Parameters
| Type |
Name |
Description |
| System.Drawing.Bitmap |
image |
|
Declaration
public void Init(IntPtr deviceContext, int width, int height, bool toBitmap)
Parameters
| Type |
Name |
Description |
| System.IntPtr |
deviceContext |
|
| System.Int32 |
width |
|
| System.Int32 |
height |
|
| System.Boolean |
toBitmap |
|
Declaration
public static Bitmap PaintToBitmap(GeoObjectList list, GeoVector viewDirection, int width, int height, BoundingCube? extent = null)
Parameters
| Type |
Name |
Description |
| CADability.GeoObject.GeoObjectList |
list |
|
| CADability.GeoVector |
viewDirection |
|
| System.Int32 |
width |
|
| System.Int32 |
height |
|
| System.Nullable<CADability.BoundingCube> |
extent |
|
Returns
| Type |
Description |
| System.Drawing.Bitmap |
|
Declaration
public void SetClientSize(Size sz)
Parameters
| Type |
Name |
Description |
| System.Drawing.Size |
sz |
|
Explicit Interface Implementations
Declaration
void IPaintTo3D.Arc(GeoPoint center, GeoVector majorAxis, GeoVector minorAxis, double startParameter, double sweepParameter)
Parameters
| Type |
Name |
Description |
| CADability.GeoPoint |
center |
|
| CADability.GeoVector |
majorAxis |
|
| CADability.GeoVector |
minorAxis |
|
| System.Double |
startParameter |
|
| System.Double |
sweepParameter |
|
Declaration
void IPaintTo3D.AvoidColor(Color color)
Parameters
| Type |
Name |
Description |
| System.Drawing.Color |
color |
|
Declaration
void IPaintTo3D.Blending(bool on)
Parameters
| Type |
Name |
Description |
| System.Boolean |
on |
|
Declaration
PaintCapabilities IPaintTo3D.Capabilities { get; }
Returns
| Type |
Description |
| CADability.PaintCapabilities |
|
Declaration
void IPaintTo3D.Clear(Color background)
Parameters
| Type |
Name |
Description |
| System.Drawing.Color |
background |
|
Declaration
void IPaintTo3D.CloseFigure()
Declaration
IPaintTo3DList IPaintTo3D.CloseList()
Returns
| Type |
Description |
| CADability.IPaintTo3DList |
|
Declaration
void IPaintTo3D.ClosePath(Color color)
Parameters
| Type |
Name |
Description |
| System.Drawing.Color |
color |
|
Declaration
bool IPaintTo3D.DelayAll { get; set; }
Returns
| Type |
Description |
| System.Boolean |
|
IPaintTo3D.DelayText
Declaration
bool IPaintTo3D.DelayText { get; set; }
Returns
| Type |
Description |
| System.Boolean |
|
Declaration
void IPaintTo3D.DisplayBitmap(GeoPoint p, Bitmap bitmap)
Parameters
| Type |
Name |
Description |
| CADability.GeoPoint |
p |
|
| System.Drawing.Bitmap |
bitmap |
|
Declaration
void IPaintTo3D.DisplayIcon(GeoPoint p, Bitmap icon)
Parameters
| Type |
Name |
Description |
| CADability.GeoPoint |
p |
|
| System.Drawing.Bitmap |
icon |
|
Declaration
void IPaintTo3D.Dispose()
Declaration
bool IPaintTo3D.DontRecalcTriangulation { get; set; }
Returns
| Type |
Description |
| System.Boolean |
|
Declaration
IDisposable IPaintTo3D.FacesBehindEdgesOffset { get; }
Returns
| Type |
Description |
| System.IDisposable |
|
Declaration
void IPaintTo3D.FilledPolyline(GeoPoint[] points)
Parameters
| Type |
Name |
Description |
| CADability.GeoPoint[] |
points |
|
Declaration
void IPaintTo3D.FillRect2D(PointF p1, PointF p2)
Parameters
| Type |
Name |
Description |
| System.Drawing.PointF |
p1 |
|
| System.Drawing.PointF |
p2 |
|
Declaration
void IPaintTo3D.FinishPaint()
Declaration
void IPaintTo3D.FreeUnusedLists()
Declaration
bool IPaintTo3D.IsBitmap { get; }
Returns
| Type |
Description |
| System.Boolean |
|
Declaration
void IPaintTo3D.Line2D(PointF p1, PointF p2)
Parameters
| Type |
Name |
Description |
| System.Drawing.PointF |
p1 |
|
| System.Drawing.PointF |
p2 |
|
Declaration
void IPaintTo3D.Line2D(int sx, int sy, int ex, int ey)
Parameters
| Type |
Name |
Description |
| System.Int32 |
sx |
|
| System.Int32 |
sy |
|
| System.Int32 |
ex |
|
| System.Int32 |
ey |
|
Declaration
void IPaintTo3D.List(IPaintTo3DList paintThisList)
Parameters
| Type |
Name |
Description |
| CADability.IPaintTo3DList |
paintThisList |
|
Declaration
void IPaintTo3D.MakeCurrent()
Declaration
IPaintTo3DList IPaintTo3D.MakeList(List<IPaintTo3DList> sublists)
Parameters
| Type |
Name |
Description |
| System.Collections.Generic.List<CADability.IPaintTo3DList> |
sublists |
|
Returns
| Type |
Description |
| CADability.IPaintTo3DList |
|
Declaration
void IPaintTo3D.Nurbs(GeoPoint[] poles, double[] weights, double[] knots, int degree)
Parameters
| Type |
Name |
Description |
| CADability.GeoPoint[] |
poles |
|
| System.Double[] |
weights |
|
| System.Double[] |
knots |
|
| System.Int32 |
degree |
|
Declaration
void IPaintTo3D.OpenList(string name)
Parameters
| Type |
Name |
Description |
| System.String |
name |
|
Declaration
void IPaintTo3D.OpenPath()
Declaration
bool IPaintTo3D.PaintEdges { get; }
Returns
| Type |
Description |
| System.Boolean |
|
Declaration
void IPaintTo3D.PaintFaces(PaintTo3D.PaintMode paintMode)
Parameters
| Type |
Name |
Description |
| CADability.PaintTo3D.PaintMode |
paintMode |
|
Declaration
bool IPaintTo3D.PaintSurfaceEdges { get; set; }
Returns
| Type |
Description |
| System.Boolean |
|
Declaration
bool IPaintTo3D.PaintSurfaces { get; }
Returns
| Type |
Description |
| System.Boolean |
|
Declaration
double IPaintTo3D.PixelToWorld { get; }
Returns
| Type |
Description |
| System.Double |
|
Declaration
void IPaintTo3D.Point2D(int x, int y)
Parameters
| Type |
Name |
Description |
| System.Int32 |
x |
|
| System.Int32 |
y |
|
Declaration
void IPaintTo3D.Points(GeoPoint[] points, float size, PointSymbol pointSymbol)
Parameters
| Type |
Name |
Description |
| CADability.GeoPoint[] |
points |
|
| System.Single |
size |
|
| CADability.GeoObject.PointSymbol |
pointSymbol |
|
Declaration
void IPaintTo3D.Polyline(GeoPoint[] points)
Parameters
| Type |
Name |
Description |
| CADability.GeoPoint[] |
points |
|
Declaration
void IPaintTo3D.PopModOp()
Declaration
void IPaintTo3D.PopState()
Declaration
double IPaintTo3D.Precision { get; set; }
Returns
| Type |
Description |
| System.Double |
|
Declaration
void IPaintTo3D.PrepareBitmap(Bitmap bitmap)
Parameters
| Type |
Name |
Description |
| System.Drawing.Bitmap |
bitmap |
|
Declaration
void IPaintTo3D.PrepareBitmap(Bitmap bitmap, int xoffset, int yoffset)
Parameters
| Type |
Name |
Description |
| System.Drawing.Bitmap |
bitmap |
|
| System.Int32 |
xoffset |
|
| System.Int32 |
yoffset |
|
Declaration
void IPaintTo3D.PrepareIcon(Bitmap icon)
Parameters
| Type |
Name |
Description |
| System.Drawing.Bitmap |
icon |
|
Declaration
void IPaintTo3D.PreparePointSymbol(PointSymbol symbol)
Parameters
| Type |
Name |
Description |
| CADability.GeoObject.PointSymbol |
symbol |
|
IPaintTo3D.PrepareText(String, String, FontStyle)
Declaration
void IPaintTo3D.PrepareText(string fontName, string textString, FontStyle fontStyle)
Parameters
| Type |
Name |
Description |
| System.String |
fontName |
|
| System.String |
textString |
|
| System.Drawing.FontStyle |
fontStyle |
|
Declaration
void IPaintTo3D.PushMultModOp(ModOp mm)
Parameters
| Type |
Name |
Description |
| CADability.ModOp |
mm |
|
Declaration
void IPaintTo3D.PushState()
Declaration
void IPaintTo3D.RectangularBitmap(Bitmap bitmap, GeoPoint location, GeoVector directionWidth, GeoVector directionHeight)
Parameters
| Type |
Name |
Description |
| System.Drawing.Bitmap |
bitmap |
|
| CADability.GeoPoint |
location |
|
| CADability.GeoVector |
directionWidth |
|
| CADability.GeoVector |
directionHeight |
|
Declaration
void IPaintTo3D.Resize(int width, int height)
Parameters
| Type |
Name |
Description |
| System.Int32 |
width |
|
| System.Int32 |
height |
|
Declaration
Color IPaintTo3D.SelectColor { get; set; }
Returns
| Type |
Description |
| System.Drawing.Color |
|
Declaration
void IPaintTo3D.SelectedList(IPaintTo3DList paintThisList, int wobbleRadius)
Parameters
| Type |
Name |
Description |
| CADability.IPaintTo3DList |
paintThisList |
|
| System.Int32 |
wobbleRadius |
|
Declaration
bool IPaintTo3D.SelectMode { get; set; }
Returns
| Type |
Description |
| System.Boolean |
|
Declaration
void IPaintTo3D.SetClip(Rectangle clipRectangle)
Parameters
| Type |
Name |
Description |
| System.Drawing.Rectangle |
clipRectangle |
|
Declaration
void IPaintTo3D.SetColor(Color color, int lockColor)
Parameters
| Type |
Name |
Description |
| System.Drawing.Color |
color |
|
| System.Int32 |
lockColor |
|
Declaration
void IPaintTo3D.SetLinePattern(LinePattern pattern)
Parameters
| Type |
Name |
Description |
| CADability.Attribute.LinePattern |
pattern |
|
Declaration
void IPaintTo3D.SetLineWidth(LineWidth lineWidth)
Parameters
| Type |
Name |
Description |
| CADability.Attribute.LineWidth |
lineWidth |
|
Declaration
void IPaintTo3D.SetProjection(Projection projection, BoundingCube boundingCube)
Parameters
| Type |
Name |
Description |
| CADability.Projection |
projection |
|
| CADability.BoundingCube |
boundingCube |
|
IPaintTo3D.Text(GeoVector, GeoVector, GeoPoint, String, String, FontStyle, Text.AlignMode, Text.LineAlignMode)
Declaration
void IPaintTo3D.Text(GeoVector lineDirection, GeoVector glyphDirection, GeoPoint location, string fontName, string textString, FontStyle fontStyle, Text.AlignMode alignment, Text.LineAlignMode lineAlignment)
Parameters
| Type |
Name |
Description |
| CADability.GeoVector |
lineDirection |
|
| CADability.GeoVector |
glyphDirection |
|
| CADability.GeoPoint |
location |
|
| System.String |
fontName |
|
| System.String |
textString |
|
| System.Drawing.FontStyle |
fontStyle |
|
| CADability.GeoObject.Text.AlignMode |
alignment |
|
| CADability.GeoObject.Text.LineAlignMode |
lineAlignment |
|
Declaration
void IPaintTo3D.Triangle(GeoPoint[] vertex, GeoVector[] normals, int[] indextriples)
Parameters
| Type |
Name |
Description |
| CADability.GeoPoint[] |
vertex |
|
| CADability.GeoVector[] |
normals |
|
| System.Int32[] |
indextriples |
|
IPaintTo3D.TriangulateText
Declaration
bool IPaintTo3D.TriangulateText { get; set; }
Returns
| Type |
Description |
| System.Boolean |
|
Declaration
bool IPaintTo3D.UseLineWidth { get; set; }
Returns
| Type |
Description |
| System.Boolean |
|
Declaration
void IPaintTo3D.UseZBuffer(bool use)
Parameters
| Type |
Name |
Description |
| System.Boolean |
use |
|
Implements
CADability.IPaintTo3D