| 1 | #pragma once |
| 2 | // Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. |
| 3 | |
| 4 | |
| 5 | #define ExitOnGdipFailureSource(d, g, x, s, ...) { x = GdipHresultFromStatus(g); if (FAILED(x)) { Dutil_RootFailure(__FILE__, __LINE__, x); ExitTraceSource(d, x, s, __VA_ARGS__); goto LExit; } } |
| 6 | #define ExitOnGdipFailure(g, x, s, ...) ExitOnGdipFailureSource(DUTIL_SOURCE_DEFAULT, g, x, s, __VA_ARGS__) |
| 7 | |
| 8 | #ifdef __cplusplus |
| 9 | extern "C" { |
| 10 | #endif |
| 11 | |
| 12 | HRESULT DAPI GdipInitialize( |
| 13 | __in const Gdiplus::GdiplusStartupInput* pInput, |
| 14 | __out ULONG_PTR* pToken, |
| 15 | __out_opt Gdiplus::GdiplusStartupOutput *pOutput |
| 16 | ); |
| 17 | |
| 18 | void DAPI GdipUninitialize( |
| 19 | __in ULONG_PTR token |
| 20 | ); |
| 21 | |
| 22 | HRESULT DAPI GdipBitmapFromResource( |
| 23 | __in_opt HINSTANCE hinst, |
| 24 | __in_z LPCSTR szId, |
| 25 | __out Gdiplus::Bitmap **ppBitmap |
| 26 | ); |
| 27 | |
| 28 | HRESULT DAPI GdipBitmapFromFile( |
| 29 | __in_z LPCWSTR wzFileName, |
| 30 | __out Gdiplus::Bitmap **ppBitmap |
| 31 | ); |
| 32 | |
| 33 | HRESULT DAPI GdipBitmapToGdiBitmap( |
| 34 | __in Gdiplus::Bitmap* pBitmap, |
| 35 | __out HBITMAP* phBitmap |
| 36 | ); |
| 37 | |
| 38 | HRESULT DAPI GdipHresultFromStatus( |
| 39 | __in Gdiplus::Status gs |
| 40 | ); |
| 41 | |
| 42 | #ifdef __cplusplus |
| 43 | } |
| 44 | #endif |