public unsafe static uint GetPaletteEntries(HPALETTE hpal, Span <PALETTEENTRY> entries) { fixed(PALETTEENTRY *entry = &MemoryMarshal.GetReference(entries)) { return(GetPaletteEntries(hpal, 0, (uint)entries.Length, entry)); } }
public PaletteHandle(HPALETTE handle, bool ownsHandle = true) { Debug.Assert(handle.IsInvalid || handle.Value == ((IntPtr)(-1)) || Imports.GetObjectType(handle) == ObjectType.Palette || Imports.GetObjectType(handle) == 0); HPALETTE = handle; _ownsHandle = ownsHandle; }
public SelectPaletteScope(HDC hdc, HPALETTE hpalette, bool forceBackground, bool realizePalette) { HDC = hdc; HPalette = SelectPalette(hdc, hpalette, forceBackground.ToBOOL()); if (!HPalette.IsNull && realizePalette) { RealizePalette((IntPtr)hdc); } }
public HRESULT CreateBitmapFromHBITMAP(HBITMAP hBitmap, HPALETTE hPalette, WICBitmapAlphaChannelOption options, IWICBitmap **ppIBitmap) { return(((delegate * unmanaged <IWICComponentFactory *, HBITMAP, HPALETTE, WICBitmapAlphaChannelOption, IWICBitmap **, int>)(lpVtbl[21]))((IWICComponentFactory *)Unsafe.AsPointer(ref this), hBitmap, hPalette, options, ppIBitmap)); }
public static extern HPALETTE SelectPalette(HDC hdc, HPALETTE hPal, BOOL bForceBkgd);
private unsafe static extern uint GetPaletteEntries(HPALETTE hpal, uint iStart, uint nEntries, PALETTEENTRY *lppe);
public static extern HPALETTE SelectPalette(HDC hdc, HPALETTE hPal, [MarshalAs(UnmanagedType.Bool)] bool bForceBkgd);
public static extern bool ResizePalette(HPALETTE hpal, uint n);
public static extern uint GetPaletteEntries(HPALETTE hpal, uint iStart, uint cEntries, [Out, MarshalAs(UnmanagedType.LPArray, SizeParamIndex = 2)] PALETTEENTRY[] pPalEntries);
public static extern uint GetNearestPaletteIndex(HPALETTE hpal, COLORREF crColor);
public static extern bool AnimatePalette(HPALETTE hPal, uint iStartIndex, uint cEntries, [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex = 2)] PALETTEENTRY[] ppe);