public Msdf(MsdfMode mode, int width, int height) { _nativeHandle = MsdfNative.MSDF_Create(mode, width, height); MsdfNative.CheckAndThrow(); Shape = new Shape(MsdfNative.MSDF_GetShape(_nativeHandle)); }
public void Dispose() { if (_owner) { MsdfNative.MSDF_Bitmap_Delete(NativeHandle); } }
public bool Save(string filename, Format format) { if (MsdfNative.MSDF_Save(_nativeHandle, filename, format)) { return(true); } MsdfNative.CheckAndThrow(); return(false); }
public bool ApplyScanlinePass() { if (MsdfNative.MSDF_ApplyScanlinePass(_nativeHandle)) { return(true); } MsdfNative.CheckAndThrow(); return(false); }
public bool ApplyOutputDistanceShift() { if (MsdfNative.MSDF_ApplyOutputDistanceShift(_nativeHandle)) { return(true); } MsdfNative.CheckAndThrow(); return(false); }
public bool ApplyOrientation() { if (MsdfNative.MSDF_ApplyOrientation(_nativeHandle)) { return(true); } MsdfNative.CheckAndThrow(); return(false); }
public bool TestRenderMulti(MsdfNative.BitmapBase *renderDestination) { if (MsdfNative.MSDF_TestRenderMulti(_nativeHandle, renderDestination)) { return(true); } MsdfNative.CheckAndThrow(); return(false); }
public BitmapBase(MsdfNative.BitmapBase *bitmapBase, bool owner = false) { NativeHandle = bitmapBase; _owner = false; PixelData = MsdfNative.MSDF_Bitmap_GetPixelData(NativeHandle, out var width, out var height, out var channelCount); Width = width; Height = height; ChannelCount = channelCount; MsdfNative.CheckAndThrow(); }
public BitmapBase(int channels, int width, int height) : this(MsdfNative.MSDF_Bitmap_Create(channels, width, height), true) { }
public static delegate * < MsdfNative.Shape *, double, ulong, void > GetColoringStrategy(MsdfColoringStrategy coloringStrategy) { return(MsdfNative.MSDF_GetColoringStrategy(coloringStrategy)); }