1
//-------------------------------------------------------------------------------------------------
2
// <copyright file="gdiputil.h" company="Microsoft">
3
// Copyright (c) Microsoft Corporation. All rights reserved.
5
// The use and distribution terms for this software are covered by the
6
// Common Public License 1.0 (http://opensource.org/licenses/cpl1.0.php)
7
// which can be found in the file CPL.TXT at the root of this distribution.
8
// By using this software in any fashion, you are agreeing to be bound by
9
// the terms of this license.
11
// You must not remove this notice, or any other, from this software.
15
// GDI+ helper functions.
17
//-------------------------------------------------------------------------------------------------
21
#define ExitOnGdipFailure(g, x, s) { x = GdipHresultFromStatus(g); if (FAILED(x)) { Dutil_RootFailure(__FILE__, __LINE__, x); ExitTrace(x, s); goto LExit; } }
22
#define ExitOnGdipFailure1(g, x, f, s) { x = GdipHresultFromStatus(g); if (FAILED(x)) { Dutil_RootFailure(__FILE__, __LINE__, x); ExitTrace1(x, f, s); goto LExit; } }
23
#define ExitOnGdipFailure2(g, x, f, s, t) { x = GdipHresultFromStatus(g); if (FAILED(x)) { Dutil_RootFailure(__FILE__, __LINE__, x); ExitTrace2(x, f, s, t); goto LExit; } }
29
HRESULT DAPI GdipBitmapFromResource(
30
__in_opt HINSTANCE hinst,
32
__out Gdiplus::Bitmap **ppBitmap
35
HRESULT DAPI GdipBitmapFromFile(
36
__in_z LPCWSTR wzFileName,
37
__out Gdiplus::Bitmap **ppBitmap
40
HRESULT DAPI GdipHresultFromStatus(
41
__in Gdiplus::Status gs