internal static bool LgLcdUpdateBitmapMonochrome(int device, byte[] pixels, LcdPriority priority, LcdUpdateMode updateMode) { Debug.Assert(pixels != null && pixels.Length == BmpMonoWidth * BmpMonoHeight * BmpMonoBpp / 8); LgLcdBitmapMonochrome bitmap = new LgLcdBitmapMonochrome(pixels); int priorityAndUpdate = (int)priority | (int)updateMode; int result = IntPtr.Size == 8 ? LgLcdUpdateBitmap64(device, bitmap, priorityAndUpdate) : LgLcdUpdateBitmap32(device, bitmap, priorityAndUpdate); if (result != ErrorSuccess) { if (updateMode == LcdUpdateMode.SyncCompleteWithinFrame && result == ErrorAccessDenied) { return(false); } throw new Win32Exception(result); } return(true); }
private static extern int LgLcdUpdateBitmap64(int device, LgLcdBitmapMonochrome bitmap, int priorityAndUpdate);