ReactOS 0.4.17-dev-357-ga8f14ff
dib.h
Go to the documentation of this file.
1/*
2 * PROJECT: PAINT for ReactOS
3 * LICENSE: LGPL-2.0-or-later (https://spdx.org/licenses/LGPL-2.0-or-later)
4 * PURPOSE: Some DIB related functions
5 * COPYRIGHT: Copyright 2015 Benedikt Freisen <b.freisen@gmx.net>
6 */
7
8#pragma once
9
12HBITMAP CreateMonoBitmap(int width, int height, BOOL bWhite);
14HBITMAP CachedBufferDIB(HBITMAP hbm, int minimalWidth, int minimalHeight);
16
18HBITMAP CopyDIBImage(HBITMAP hbm, INT cx = 0, INT cy = 0, INT stretchMode = STRETCH_HALFTONE);
19
22
24
26
27void SetFileInfo(LPCWSTR name, LPWIN32_FIND_DATAW pFound, BOOL isAFile);
28
31
32HBITMAP Rotate90DegreeBlt(HDC hDC1, INT cx, INT cy, BOOL bRight, BOOL bMono);
33
34HBITMAP SkewDIB(HDC hDC1, HBITMAP hbm, INT nDegree, BOOL bVertical, BOOL bMono = FALSE);
35
36float PpcmFromDpi(float dpi);
37
38#define ROUND(x) (INT)((x) + 0.5)
39
42HBITMAP BitmapFromHEMF(HENHMETAFILE hEMF);
43HBITMAP getSubImage(HBITMAP hbmWhole, const RECT& rcPartial);
44void putSubImage(HBITMAP hbmWhole, const RECT& rcPartial, HBITMAP hbmPart);
void putSubImage(HBITMAP hbmWhole, const RECT &rcPartial, HBITMAP hbmPart)
Definition: dib.cpp:456
HBITMAP CreateDIBWithProperties(int width, int height)
Definition: dib.cpp:32
void SetFileInfo(LPCWSTR name, LPWIN32_FIND_DATAW pFound, BOOL isAFile)
Definition: dib.cpp:210
HBITMAP SkewDIB(HDC hDC1, HBITMAP hbm, INT nDegree, BOOL bVertical, BOOL bMono=FALSE)
Definition: dib.cpp:379
HBITMAP InitializeImage(LPCWSTR name, LPWIN32_FIND_DATAW pFound, BOOL isFile)
Definition: dib.cpp:253
HGLOBAL BitmapToClipboardDIB(HBITMAP hBitmap)
Definition: dib.cpp:475
HBITMAP BitmapFromHEMF(HENHMETAFILE hEMF)
Definition: dib.cpp:585
HBITMAP getSubImage(HBITMAP hbmWhole, const RECT &rcPartial)
Definition: dib.cpp:437
HBITMAP CopyDIBImage(HBITMAP hbm, INT cx=0, INT cy=0, INT stretchMode=STRETCH_HALFTONE)
Definition: dib.cpp:113
HBITMAP CachedBufferDIB(HBITMAP hbm, int minimalWidth, int minimalHeight)
Definition: dib.cpp:142
int GetDIBWidth(HBITMAP hbm)
Definition: dib.cpp:163
HBITMAP BitmapFromClipboardDIB(HGLOBAL hGlobal)
Definition: dib.cpp:538
HBITMAP Rotate90DegreeBlt(HDC hDC1, INT cx, INT cy, BOOL bRight, BOOL bMono)
Definition: dib.cpp:340
HBITMAP ConvertToBlackAndWhite(HBITMAP hbm)
Definition: dib.cpp:659
int GetDIBHeight(HBITMAP hbm)
Definition: dib.cpp:171
HBITMAP DoLoadImageFile(HWND hwnd, LPCWSTR name, BOOL fIsMainFile)
Definition: dib.cpp:284
HBITMAP CopyMonoImage(HBITMAP hbm, INT cx=0, INT cy=0, INT stretchMode=STRETCH_HALFTONE)
Definition: dib.cpp:87
float PpcmFromDpi(float dpi)
Definition: dib.cpp:25
BOOL SaveDIBToFile(HBITMAP hBitmap, LPCWSTR FileName, BOOL fIsMainFile, REFGUID guidFileType=GUID_NULL)
Definition: dib.cpp:178
HBITMAP CreateMonoBitmap(int width, int height, BOOL bWhite)
Definition: dib.cpp:45
HBITMAP SetBitmapAndInfo(HBITMAP hBitmap, LPCWSTR name, LPWIN32_FIND_DATAW pFound, BOOL isFile)
Definition: dib.cpp:272
BOOL IsBitmapBlackAndWhite(HBITMAP hbm)
Definition: dib.cpp:608
HBITMAP CreateColorDIB(int width, int height, COLORREF rgb)
Definition: dib.cpp:65
#define FALSE
Definition: types.h:117
static HBITMAP hBitmap
Definition: timezone.c:26
unsigned int BOOL
Definition: ntddk_ex.h:94
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
GLint GLint GLsizei width
Definition: gl.h:1546
#define GUID_NULL
Definition: ks.h:106
static HBITMAP
Definition: button.c:44
static HDC
Definition: imagelist.c:88
_Out_opt_ int _Out_opt_ int * cy
Definition: commctrl.h:586
_Out_opt_ int * cx
Definition: commctrl.h:585
_In_ HBITMAP hbm
Definition: ntgdi.h:2776
Definition: scsiwmi.h:51
Definition: name.c:39
const uint16_t * LPCWSTR
Definition: typedefs.h:57
int32_t INT
Definition: typedefs.h:58
#define dpi
Definition: sysparams.c:23
_In_ ULONG _In_ ULONG rgb
Definition: winddi.h:3521
_In_ LONG _In_ HWND hwnd
Definition: winddi.h:4023
DWORD COLORREF
Definition: windef.h:100
#define STRETCH_HALFTONE
Definition: wingdi.h:959