public void FillPath(D2DPathGeometry path, D2DColor fillColor) { D2D.FillPathD(path.Handle, fillColor); }
public void ClosePath() { D2D.ClosePath(this.Handle); }
public void DrawLine(D2DPoint start, D2DPoint end, D2DColor color, FLOAT weight = 1, D2DDashStyle dashStyle = D2DDashStyle.Solid) { D2D.DrawLine(this.Handle, start, end, color, weight, dashStyle); }
public void AddEllipse(D2DEllipse ellipse) { D2D.AddPathEllipse(this.Handle, ref ellipse); }
public bool FillContainsPoint(D2DPoint point) { return(D2D.PathFillContainsPoint(this.Handle, point)); }
internal D2DBitmap(HANDLE handle) : base(handle) { this.Size = D2D.GetBitmapSize(handle); }
public void AddLines(D2DPoint[] points) { D2D.AddPathLines(this.Handle, points); }
public void Flush() { D2D.Flush(this.DeviceHandle); }
public D2DBitmap GetBitmap() { HANDLE bitmapHandle = D2D.GetBitmapRenderTargetBitmap(this.Handle); return(bitmapHandle == HANDLE.Zero ? null : new D2DBitmap(bitmapHandle)); }
public void BeginRender(D2DBitmap bitmap) { D2D.BeginRenderWithBackgroundBitmap(this.DeviceHandle, bitmap.Handle); }
public void EndRender() { D2D.EndRender(this.DeviceHandle); }
public void BeginRender(D2DColor color) { D2D.BeginRenderWithBackgroundColor(this.DeviceHandle, color); }
public void BeginRender() { D2D.BeginRender(this.DeviceHandle); }
public void Clear(D2DColor color) { D2D.Clear(DeviceHandle, color); }
public static D2DDevice FromHwnd(HWND hwnd) { HANDLE contextHandle = D2D.CreateContext(hwnd); return(new D2DDevice(contextHandle)); }
public void Dispose() { D2D.DestroyBitmapRenderTarget(this.Handle); }
public D2DSolidColorBrush CreateSolidColorBrush(D2DColor color) { HANDLE handle = D2D.CreateSolidColorBrush(this.Handle, color); return(handle == HANDLE.Zero ? null : new D2DSolidColorBrush(handle, color)); }
public D2DRectangleGeometry CreateRectangleGeometry(ref D2DRect rect) { HANDLE rectHandle = D2D.CreateRectangleGeometry(this.Handle, ref rect); return(new D2DRectangleGeometry(this.Handle, rectHandle)); }
public void SetStartPoint(D2DPoint startPoint) { D2D.SetPathStartPoint(this.Handle, startPoint); }
public D2DPathGeometry CreatePathGeometry() { HANDLE geoHandle = D2D.CreatePathGeometry(this.Handle); return(new D2DPathGeometry(this.Handle, geoHandle)); }
public void AddBeziers(D2DBezierSegment[] bezierSegments) { D2D.AddPathBeziers(this.Handle, bezierSegments); }
public D2DBitmap LoadBitmap(byte[] buffer, UINT offset, UINT length) { var bitmapHandle = D2D.CreateBitmapFromBytes(this.Handle, buffer, offset, length); return((bitmapHandle != HWND.Zero) ? new D2DBitmap(bitmapHandle) : null); }
public void AddArc(D2DPoint endPoint, D2DSize size, FLOAT sweepAngle, D2D1_ARC_SIZE arcSize = D2D1_ARC_SIZE.D2D1_ARC_SIZE_SMALL, D2D1_SWEEP_DIRECTION sweepDirection = D2D1_SWEEP_DIRECTION.D2D1_SWEEP_DIRECTION_CLOCKWISE) { D2D.AddPathArc(this.Handle, endPoint, size, sweepAngle, arcSize, sweepDirection); }
public D2DBitmap LoadBitmap(string filepath) { var bitmapHandle = D2D.CreateBitmapFromFile(this.Handle, filepath); return((bitmapHandle != HWND.Zero) ? new D2DBitmap(bitmapHandle) : null); }
public bool StrokeContainsPoint(D2DPoint point, FLOAT width = 1, D2DDashStyle dashStyle = D2DDashStyle.Solid) { return(D2D.PathStrokeContainsPoint(this.Handle, point, width, dashStyle)); }
public D2DBitmap CreateBitmapFromMemory(UINT width, UINT height, UINT stride, IntPtr buffer, UINT offset, UINT length) { HANDLE d2dbmp = D2D.CreateBitmapFromMemory(this.Handle, width, height, stride, buffer, offset, length); return(d2dbmp == HANDLE.Zero ? null : new D2DBitmap(d2dbmp)); }
public override void Dispose() { D2D.DestroyPathGeometry(this.Handle); }
public void Dispose() { D2D.DestroyContext(this.Handle); }
public void DrawLines(D2DPoint[] points, D2DColor color, FLOAT weight = 1, D2DDashStyle dashStyle = D2DDashStyle.Solid) { D2D.DrawLines(this.Handle, points, (uint)points.Length, color, weight, dashStyle); }
public void DrawPath(D2DPathGeometry path, D2DColor strokeColor, FLOAT strokeWidth = 1f, D2DDashStyle dashStyle = D2DDashStyle.Solid) { D2D.DrawPath(path.Handle, strokeColor, strokeWidth, dashStyle); }