Harlinn.Windows 0.1
Loading...
Searching...
No Matches
Harlinn::Windows::Graphics::Factory Class Reference

Creates Direct2D resources. More...

#include <HWGraphics.h>

Inheritance diagram for Harlinn::Windows::Graphics::Factory:
[legend]
Collaboration diagram for Harlinn::Windows::Graphics::Factory:
[legend]

Public Types

typedef Unknown Base
 
- Public Types inherited from Harlinn::Common::Core::Unknown
typedef IUnknown InterfaceType
 

Public Member Functions

 Factory (D2D1_FACTORY_TYPE factoryType)
 Creates a factory object that can be used to create Direct2D resources.
 
void ReloadSystemMetrics () const
 Forces the factory to refresh any system defaults that it might have changed since factory creation.
 
void CreateRectangleGeometry (const D2D1_RECT_F *rectangle, ID2D1RectangleGeometry **rectangleGeometry) const
 Creates an ID2D1RectangleGeometry.
 
void CreateRectangleGeometry (const D2D1_RECT_F &rectangle, ID2D1RectangleGeometry **rectangleGeometry) const
 
RectangleGeometry CreateRectangleGeometry (const D2D1_RECT_F *rectangle) const
 
RectangleGeometry CreateRectangleGeometry (const D2D1_RECT_F &rectangle) const
 
RectangleGeometry CreateRectangleGeometry (const D2D1_POINT_2F *position, const D2D1_SIZE_F *size) const
 
RectangleGeometry CreateRectangleGeometry (const D2D1_POINT_2F &position, const D2D1_SIZE_F &size) const
 
RectangleGeometry CreateRectangleGeometry (FLOAT left, FLOAT top, FLOAT right, FLOAT bottom) const
 
void CreateRoundedRectangleGeometry (const D2D1_ROUNDED_RECT *roundedRectangle, ID2D1RoundedRectangleGeometry **roundedRectangleGeometry) const
 Creates an ID2D1RoundedRectangleGeometry.
 
void CreateRoundedRectangleGeometry (const D2D1_ROUNDED_RECT &roundedRectangle, ID2D1RoundedRectangleGeometry **roundedRectangleGeometry) const
 
RoundedRectangleGeometry CreateRoundedRectangleGeometry (const D2D1_ROUNDED_RECT *roundedRectangle) const
 
RoundedRectangleGeometry CreateRoundedRectangleGeometry (const D2D1_ROUNDED_RECT &roundedRectangle) const
 
RoundedRectangleGeometry CreateRoundedRectangleGeometry (const D2D1_RECT_F *rectangle, FLOAT radiusX, FLOAT readiusY) const
 
RoundedRectangleGeometry CreateRoundedRectangleGeometry (const D2D1_RECT_F &rectangle, FLOAT radiusX, FLOAT readiusY) const
 
RoundedRectangleGeometry CreateRoundedRectangleGeometry (const D2D1_POINT_2F *position, const D2D1_SIZE_F *size, FLOAT radiusX, FLOAT readiusY) const
 
RoundedRectangleGeometry CreateRoundedRectangleGeometry (const D2D1_POINT_2F &position, const D2D1_SIZE_F &size, FLOAT radiusX, FLOAT readiusY) const
 
RoundedRectangleGeometry CreateRoundedRectangleGeometry (FLOAT left, FLOAT top, FLOAT right, FLOAT bottom, FLOAT radiusX, FLOAT readiusY) const
 
void CreateEllipseGeometry (const D2D1_ELLIPSE *ellipse, ID2D1EllipseGeometry **ellipseGeometry) const
 Creates an ID2D1EllipseGeometry.
 
void CreateEllipseGeometry (const D2D1_ELLIPSE &ellipse, ID2D1EllipseGeometry **ellipseGeometry) const
 
EllipseGeometry CreateEllipseGeometry (const D2D1_ELLIPSE *ellipse) const
 
EllipseGeometry CreateEllipseGeometry (const D2D1_ELLIPSE &ellipse) const
 
EllipseGeometry CreateEllipseGeometry (const D2D1_POINT_2F *centerPoint, FLOAT radiusX, FLOAT radiusY) const
 
EllipseGeometry CreateEllipseGeometry (const D2D1_POINT_2F &centerPoint, FLOAT radiusX, FLOAT radiusY) const
 
EllipseGeometry CreateEllipseGeometry (FLOAT centerX, FLOAT centerY, FLOAT radiusX, FLOAT radiusY) const
 
void CreateGeometryGroup (D2D1_FILL_MODE fillMode, ID2D1Geometry **geometries, UINT32 geometriesCount, ID2D1GeometryGroup **geometryGroup) const
 Creates an ID2D1GeometryGroup, which is an object that holds other geometries.
 
void CreateGeometryGroup (D2D1_FILL_MODE fillMode, const Geometry *geometries, UINT32 geometriesCount, ID2D1GeometryGroup **geometryGroup) const
 
GeometryGroup CreateGeometryGroup (D2D1_FILL_MODE fillMode, ID2D1Geometry **geometries, UINT32 geometriesCount) const
 
GeometryGroup CreateGeometryGroup (D2D1_FILL_MODE fillMode, const Geometry *geometries, UINT32 geometriesCount) const
 
void CreateTransformedGeometry (ID2D1Geometry *sourceGeometry, const D2D1_MATRIX_3X2_F *transform, ID2D1TransformedGeometry **transformedGeometry) const
 Transforms the specified geometry and stores the result as an ID2D1TransformedGeometry object.
 
void CreateTransformedGeometry (ID2D1Geometry *sourceGeometry, const D2D1_MATRIX_3X2_F &transform, ID2D1TransformedGeometry **transformedGeometry) const
 
void CreateTransformedGeometry (const Geometry &sourceGeometry, const D2D1_MATRIX_3X2_F *transform, ID2D1TransformedGeometry **transformedGeometry) const
 
void CreateTransformedGeometry (const Geometry &sourceGeometry, const D2D1_MATRIX_3X2_F &transform, ID2D1TransformedGeometry **transformedGeometry) const
 
TransformedGeometry CreateTransformedGeometry (ID2D1Geometry *sourceGeometry, const D2D1_MATRIX_3X2_F *transform) const
 
TransformedGeometry CreateTransformedGeometry (ID2D1Geometry *sourceGeometry, const D2D1_MATRIX_3X2_F &transform) const
 
TransformedGeometry CreateTransformedGeometry (const Geometry &sourceGeometry, const D2D1_MATRIX_3X2_F *transform) const
 
TransformedGeometry CreateTransformedGeometry (const Geometry &sourceGeometry, const D2D1_MATRIX_3X2_F &transform) const
 
void CreatePathGeometry (ID2D1PathGeometry **pathGeometry) const
 Creates an empty ID2D1PathGeometry.
 
PathGeometry CreatePathGeometry () const
 
void CreateStrokeStyle (const D2D1_STROKE_STYLE_PROPERTIES *strokeStyleProperties, const FLOAT *dashes, UINT32 dashesCount, ID2D1StrokeStyle **strokeStyle) const
 Creates an ID2D1StrokeStyle that describes start cap, dash pattern, and other features of a stroke.
 
void CreateStrokeStyle (const D2D1_STROKE_STYLE_PROPERTIES &strokeStyleProperties, const FLOAT *dashes, UINT32 dashesCount, ID2D1StrokeStyle **strokeStyle) const
 
StrokeStyle CreateStrokeStyle (const D2D1_STROKE_STYLE_PROPERTIES *strokeStyleProperties, const FLOAT *dashes=nullptr, UINT32 dashesCount=0) const
 
StrokeStyle CreateStrokeStyle (const D2D1_STROKE_STYLE_PROPERTIES &strokeStyleProperties, const FLOAT *dashes=nullptr, UINT32 dashesCount=0) const
 
void CreateDrawingStateBlock (const D2D1_DRAWING_STATE_DESCRIPTION *drawingStateDescription, IDWriteRenderingParams *textRenderingParams, ID2D1DrawingStateBlock **drawingStateBlock) const
 Creates an ID2D1DrawingStateBlock that can be used with the SaveDrawingState and RestoreDrawingState methods of a render target.
 
void CreateDrawingStateBlock (const D2D1_DRAWING_STATE_DESCRIPTION &drawingStateDescription, IDWriteRenderingParams *textRenderingParams, ID2D1DrawingStateBlock **drawingStateBlock) const
 
void CreateDrawingStateBlock (const D2D1_DRAWING_STATE_DESCRIPTION *drawingStateDescription, const DirectWrite::RenderingParams &textRenderingParams, ID2D1DrawingStateBlock **drawingStateBlock) const
 
void CreateDrawingStateBlock (const D2D1_DRAWING_STATE_DESCRIPTION &drawingStateDescription, const DirectWrite::RenderingParams &textRenderingParams, ID2D1DrawingStateBlock **drawingStateBlock) const
 
DrawingStateBlock CreateDrawingStateBlock (const D2D1_DRAWING_STATE_DESCRIPTION *drawingStateDescription=nullptr, IDWriteRenderingParams *textRenderingParams=nullptr) const
 
DrawingStateBlock CreateDrawingStateBlock (const D2D1_DRAWING_STATE_DESCRIPTION &drawingStateDescription, IDWriteRenderingParams *textRenderingParams=nullptr) const
 
DrawingStateBlock CreateDrawingStateBlock (const D2D1_DRAWING_STATE_DESCRIPTION *drawingStateDescription, const DirectWrite::RenderingParams &textRenderingParams) const
 
DrawingStateBlock CreateDrawingStateBlock (const D2D1_DRAWING_STATE_DESCRIPTION &drawingStateDescription, const DirectWrite::RenderingParams &textRenderingParams) const
 
void CreateWicBitmapRenderTarget (IWICBitmap *target, const D2D1_RENDER_TARGET_PROPERTIES *renderTargetProperties, ID2D1RenderTarget **renderTarget) const
 Creates a render target that renders to a Microsoft Windows Imaging Component (WIC) bitmap.
 
void CreateWicBitmapRenderTarget (IWICBitmap *target, const D2D1_RENDER_TARGET_PROPERTIES &renderTargetProperties, ID2D1RenderTarget **renderTarget) const
 
RenderTarget CreateWicBitmapRenderTarget (IWICBitmap *target, const D2D1_RENDER_TARGET_PROPERTIES *renderTargetProperties) const
 
RenderTarget CreateWicBitmapRenderTarget (IWICBitmap *target, const D2D1_RENDER_TARGET_PROPERTIES &renderTargetProperties) const
 
void CreateHwndRenderTarget (const D2D1_RENDER_TARGET_PROPERTIES *renderTargetProperties, const D2D1_HWND_RENDER_TARGET_PROPERTIES *hwndRenderTargetProperties, ID2D1HwndRenderTarget **hwndRenderTarget) const
 Creates an ID2D1HwndRenderTarget, a render target that renders to a window.
 
void CreateHwndRenderTarget (const D2D1_RENDER_TARGET_PROPERTIES &renderTargetProperties, const D2D1_HWND_RENDER_TARGET_PROPERTIES &hwndRenderTargetProperties, ID2D1HwndRenderTarget **hwndRenderTarget) const
 
ControlRenderTarget CreateHwndRenderTarget (const D2D1_RENDER_TARGET_PROPERTIES *renderTargetProperties, const D2D1_HWND_RENDER_TARGET_PROPERTIES *hwndRenderTargetProperties) const
 
ControlRenderTarget CreateHwndRenderTarget (const D2D1_RENDER_TARGET_PROPERTIES &renderTargetProperties, const D2D1_HWND_RENDER_TARGET_PROPERTIES &hwndRenderTargetProperties) const
 
HW_EXPORT ControlRenderTarget CreateHwndRenderTarget (Control &control) const
 
HW_EXPORT ControlRenderTarget CreateHwndRenderTarget (HWND hwnd) const
 
HW_EXPORT ControlRenderTarget CreateControlRenderTarget (Control &control) const
 
HW_EXPORT ControlRenderTarget CreateControlRenderTarget (HWND hwnd) const
 
void CreateDxgiSurfaceRenderTarget (IDXGISurface *dxgiSurface, const D2D1_RENDER_TARGET_PROPERTIES *renderTargetProperties, ID2D1RenderTarget **renderTarget) const
 Creates a render target that draws to a DirectX Graphics Infrastructure (DXGI) surface.
 
void CreateDxgiSurfaceRenderTarget (IDXGISurface *dxgiSurface, const D2D1_RENDER_TARGET_PROPERTIES &renderTargetProperties, ID2D1RenderTarget **renderTarget) const
 
template<typename T >
requires std::is_base_of_v< DXGI::Surface, T>
void CreateDxgiSurfaceRenderTarget (const T &dxgiSurface, const D2D1_RENDER_TARGET_PROPERTIES *renderTargetProperties, ID2D1RenderTarget **renderTarget) const
 
template<typename T >
requires std::is_base_of_v< DXGI::Surface, T>
void CreateDxgiSurfaceRenderTarget (const T &dxgiSurface, const D2D1_RENDER_TARGET_PROPERTIES &renderTargetProperties, ID2D1RenderTarget **renderTarget) const
 
RenderTarget CreateDxgiSurfaceRenderTarget (IDXGISurface *dxgiSurface, const D2D1_RENDER_TARGET_PROPERTIES *renderTargetProperties) const
 
RenderTarget CreateDxgiSurfaceRenderTarget (IDXGISurface *dxgiSurface, const D2D1_RENDER_TARGET_PROPERTIES &renderTargetProperties) const
 
template<typename T >
requires std::is_base_of_v< DXGI::Surface, T>
RenderTarget CreateDxgiSurfaceRenderTarget (const T &dxgiSurface, const D2D1_RENDER_TARGET_PROPERTIES *renderTargetProperties) const
 
template<typename T >
requires std::is_base_of_v< DXGI::Surface, T>
RenderTarget CreateDxgiSurfaceRenderTarget (const T &dxgiSurface, const D2D1_RENDER_TARGET_PROPERTIES &renderTargetProperties) const
 
void CreateDCRenderTarget (const D2D1_RENDER_TARGET_PROPERTIES *renderTargetProperties, ID2D1DCRenderTarget **dcRenderTarget) const
 Creates a render target that draws to a Windows Graphics Device Interface (GDI) device context.
 
void CreateDCRenderTarget (const D2D1_RENDER_TARGET_PROPERTIES &renderTargetProperties, ID2D1DCRenderTarget **dcRenderTarget) const
 
DeviceContextRenderTarget CreateDCRenderTarget (const D2D1_RENDER_TARGET_PROPERTIES *renderTargetProperties) const
 
DeviceContextRenderTarget CreateDCRenderTarget (const D2D1_RENDER_TARGET_PROPERTIES &renderTargetProperties) const
 
- Public Member Functions inherited from Harlinn::Common::Core::Unknown
constexpr Unknown () noexcept
 
 Unknown (IUnknown *unknown, bool addref=false) noexcept
 
 Unknown (REFIID iid, const Unknown &unknown, bool throwIfNoInterface=true)
 
 Unknown (const Unknown &other) noexcept
 
 Unknown (Unknown &&other) noexcept
 
 ~Unknown () noexcept
 
constexpr operator bool () const noexcept
 
Unknownoperator= (const Unknown &other) noexcept
 
Unknownoperator= (Unknown &&other) noexcept
 
void swap (Unknown &other) noexcept
 
void ResetPtr (IUnknown *other=nullptr, bool addRef=false) noexcept
 
Unknownoperator= (nullptr_t)
 
IUnknown * Detach ()
 
template<typename T >
requires std::is_base_of_v<Unknown, T >
T As () const
 
template<typename T >
requires std::is_base_of_v<Unknown, T>
bool Is () const noexcept
 
template<typename T >
requires std::is_base_of_v<IUnknown, T>
ComPtr< TAs () const
 
template<typename T >
requires std::is_base_of_v<IUnknown, T>
bool Is () const noexcept
 This function can be used to detect if an object supports a particular COM interface derived from IUnknown.
 
template<typename T = IUnknown>
TGetInterfacePointer () const noexcept
 
bool QueryInterface (REFIID riid, void **itf) const
 Queries a COM object for a pointer to one of its interface; identifying the interface by a reference to its interface identifier (IID). If the COM object implements the interface, then it returns a pointer to that interface after calling IUnknown::AddRef on it.
 
template<typename T >
requires std::is_base_of_v<IUnknown, T>
bool QueryInterface (T **itf) const
 
constexpr bool operator== (const Unknown &other) const noexcept
 
constexpr bool operator!= (const Unknown &other) const noexcept
 
constexpr bool operator== (const IUnknown *other) const noexcept
 
constexpr bool operator!= (const IUnknown *other) const noexcept
 

Additional Inherited Members

- Static Public Member Functions inherited from Harlinn::Common::Core::Unknown
template<typename T >
requires std::is_base_of_v<Unknown, T>
static T CoCreateInstanceFromClassId (const CLSID &clsid, DWORD classContext=CLSCTX_INPROC_SERVER)
 
template<typename T >
requires std::is_base_of_v<Unknown, T>
static T CoCreateInstanceFromClassId (const wchar_t *clsid, DWORD classContext=CLSCTX_INPROC_SERVER)
 
template<typename T >
requires std::is_base_of_v<Unknown, T>
static T CoCreateInstanceFromClassId (const WideString &clsid, DWORD classContext=CLSCTX_INPROC_SERVER)
 
template<typename T >
requires std::is_base_of_v<Unknown, T>
static T CoCreateInstanceFromProgId (const wchar_t *progId, DWORD classContext=CLSCTX_INPROC_SERVER)
 
template<typename T >
requires std::is_base_of_v<Unknown, T>
static T CoCreateInstanceFromProgId (const WideString &progId, DWORD classContext=CLSCTX_INPROC_SERVER)
 
template<typename T >
requires std::is_base_of_v<Unknown, T>
static T CoCreateInstanceFromDll (const ModuleHandle &dll, const CLSID &clsid)
 
- Protected Attributes inherited from Harlinn::Common::Core::Unknown
IUnknown * unknown_
 

Detailed Description

Creates Direct2D resources.

Member Typedef Documentation

◆ Base

Constructor & Destructor Documentation

◆ Factory()

Harlinn::Windows::Graphics::Factory::Factory ( D2D1_FACTORY_TYPE factoryType)
inline

Creates a factory object that can be used to create Direct2D resources.

Member Function Documentation

◆ CreateControlRenderTarget() [1/2]

ControlRenderTarget Harlinn::Windows::Graphics::Factory::CreateControlRenderTarget ( Control & control) const

◆ CreateControlRenderTarget() [2/2]

ControlRenderTarget Harlinn::Windows::Graphics::Factory::CreateControlRenderTarget ( HWND hwnd) const

◆ CreateDCRenderTarget() [1/4]

DeviceContextRenderTarget Harlinn::Windows::Graphics::Factory::CreateDCRenderTarget ( const D2D1_RENDER_TARGET_PROPERTIES & renderTargetProperties) const
inline

◆ CreateDCRenderTarget() [2/4]

void Harlinn::Windows::Graphics::Factory::CreateDCRenderTarget ( const D2D1_RENDER_TARGET_PROPERTIES & renderTargetProperties,
ID2D1DCRenderTarget ** dcRenderTarget ) const
inline

◆ CreateDCRenderTarget() [3/4]

DeviceContextRenderTarget Harlinn::Windows::Graphics::Factory::CreateDCRenderTarget ( const D2D1_RENDER_TARGET_PROPERTIES * renderTargetProperties) const
inline

◆ CreateDCRenderTarget() [4/4]

void Harlinn::Windows::Graphics::Factory::CreateDCRenderTarget ( const D2D1_RENDER_TARGET_PROPERTIES * renderTargetProperties,
ID2D1DCRenderTarget ** dcRenderTarget ) const
inline

Creates a render target that draws to a Windows Graphics Device Interface (GDI) device context.

Parameters
renderTargetPropertiesThe rendering mode, pixel format, remoting options, DPI information, and the minimum DirectX support required for hardware rendering. To enable the device context (DC) render target to work with GDI, set the DXGI format to DXGI_FORMAT_B8G8R8A8_UNORM and the alpha mode to D2D1_ALPHA_MODE_PREMULTIPLIED or D2D1_ALPHA_MODE_IGNORE.
dcRenderTargetWhen this method returns, dcRenderTarget contains the address of the pointer to the ID2D1DCRenderTarget created by the method.

◆ CreateDrawingStateBlock() [1/8]

DrawingStateBlock Harlinn::Windows::Graphics::Factory::CreateDrawingStateBlock ( const D2D1_DRAWING_STATE_DESCRIPTION & drawingStateDescription,
const DirectWrite::RenderingParams & textRenderingParams ) const
inline

◆ CreateDrawingStateBlock() [2/8]

void Harlinn::Windows::Graphics::Factory::CreateDrawingStateBlock ( const D2D1_DRAWING_STATE_DESCRIPTION & drawingStateDescription,
const DirectWrite::RenderingParams & textRenderingParams,
ID2D1DrawingStateBlock ** drawingStateBlock ) const
inline

◆ CreateDrawingStateBlock() [3/8]

void Harlinn::Windows::Graphics::Factory::CreateDrawingStateBlock ( const D2D1_DRAWING_STATE_DESCRIPTION & drawingStateDescription,
IDWriteRenderingParams * textRenderingParams,
ID2D1DrawingStateBlock ** drawingStateBlock ) const
inline

◆ CreateDrawingStateBlock() [4/8]

DrawingStateBlock Harlinn::Windows::Graphics::Factory::CreateDrawingStateBlock ( const D2D1_DRAWING_STATE_DESCRIPTION & drawingStateDescription,
IDWriteRenderingParams * textRenderingParams = nullptr ) const
inline

◆ CreateDrawingStateBlock() [5/8]

DrawingStateBlock Harlinn::Windows::Graphics::Factory::CreateDrawingStateBlock ( const D2D1_DRAWING_STATE_DESCRIPTION * drawingStateDescription,
const DirectWrite::RenderingParams & textRenderingParams ) const
inline

◆ CreateDrawingStateBlock() [6/8]

void Harlinn::Windows::Graphics::Factory::CreateDrawingStateBlock ( const D2D1_DRAWING_STATE_DESCRIPTION * drawingStateDescription,
const DirectWrite::RenderingParams & textRenderingParams,
ID2D1DrawingStateBlock ** drawingStateBlock ) const
inline

◆ CreateDrawingStateBlock() [7/8]

void Harlinn::Windows::Graphics::Factory::CreateDrawingStateBlock ( const D2D1_DRAWING_STATE_DESCRIPTION * drawingStateDescription,
IDWriteRenderingParams * textRenderingParams,
ID2D1DrawingStateBlock ** drawingStateBlock ) const
inline

Creates an ID2D1DrawingStateBlock that can be used with the SaveDrawingState and RestoreDrawingState methods of a render target.

Parameters
drawingStateDescriptionA structure that contains anti-aliasing, transform, and tags information.
textRenderingParamsOptional text parameters that indicate how text should be rendered.
drawingStateBlockWhen this method returns, contains the address of a pointer to the new drawing state block created by this method.

◆ CreateDrawingStateBlock() [8/8]

DrawingStateBlock Harlinn::Windows::Graphics::Factory::CreateDrawingStateBlock ( const D2D1_DRAWING_STATE_DESCRIPTION * drawingStateDescription = nullptr,
IDWriteRenderingParams * textRenderingParams = nullptr ) const
inline

◆ CreateDxgiSurfaceRenderTarget() [1/8]

template<typename T >
requires std::is_base_of_v< DXGI::Surface, T>
RenderTarget Harlinn::Windows::Graphics::Factory::CreateDxgiSurfaceRenderTarget ( const T & dxgiSurface,
const D2D1_RENDER_TARGET_PROPERTIES & renderTargetProperties ) const
inline

◆ CreateDxgiSurfaceRenderTarget() [2/8]

template<typename T >
requires std::is_base_of_v< DXGI::Surface, T>
void Harlinn::Windows::Graphics::Factory::CreateDxgiSurfaceRenderTarget ( const T & dxgiSurface,
const D2D1_RENDER_TARGET_PROPERTIES & renderTargetProperties,
ID2D1RenderTarget ** renderTarget ) const
inline

◆ CreateDxgiSurfaceRenderTarget() [3/8]

template<typename T >
requires std::is_base_of_v< DXGI::Surface, T>
RenderTarget Harlinn::Windows::Graphics::Factory::CreateDxgiSurfaceRenderTarget ( const T & dxgiSurface,
const D2D1_RENDER_TARGET_PROPERTIES * renderTargetProperties ) const
inline

◆ CreateDxgiSurfaceRenderTarget() [4/8]

template<typename T >
requires std::is_base_of_v< DXGI::Surface, T>
void Harlinn::Windows::Graphics::Factory::CreateDxgiSurfaceRenderTarget ( const T & dxgiSurface,
const D2D1_RENDER_TARGET_PROPERTIES * renderTargetProperties,
ID2D1RenderTarget ** renderTarget ) const
inline

◆ CreateDxgiSurfaceRenderTarget() [5/8]

RenderTarget Harlinn::Windows::Graphics::Factory::CreateDxgiSurfaceRenderTarget ( IDXGISurface * dxgiSurface,
const D2D1_RENDER_TARGET_PROPERTIES & renderTargetProperties ) const
inline

◆ CreateDxgiSurfaceRenderTarget() [6/8]

void Harlinn::Windows::Graphics::Factory::CreateDxgiSurfaceRenderTarget ( IDXGISurface * dxgiSurface,
const D2D1_RENDER_TARGET_PROPERTIES & renderTargetProperties,
ID2D1RenderTarget ** renderTarget ) const
inline

◆ CreateDxgiSurfaceRenderTarget() [7/8]

RenderTarget Harlinn::Windows::Graphics::Factory::CreateDxgiSurfaceRenderTarget ( IDXGISurface * dxgiSurface,
const D2D1_RENDER_TARGET_PROPERTIES * renderTargetProperties ) const
inline

◆ CreateDxgiSurfaceRenderTarget() [8/8]

void Harlinn::Windows::Graphics::Factory::CreateDxgiSurfaceRenderTarget ( IDXGISurface * dxgiSurface,
const D2D1_RENDER_TARGET_PROPERTIES * renderTargetProperties,
ID2D1RenderTarget ** renderTarget ) const
inline

Creates a render target that draws to a DirectX Graphics Infrastructure (DXGI) surface.

Parameters
dxgiSurfaceThe IDXGISurface to which the render target will draw.
renderTargetPropertiesThe rendering mode, pixel format, remoting options, DPI information, and the minimum DirectX support required for hardware rendering.
renderTargetWhen this method returns, contains the address of the pointer to the ID2D1RenderTarget object created by this method.

To write to a Direct3D surface, you obtain an IDXGISurface and pass it to the CreateDxgiSurfaceRenderTarget method to create a DXGI surface render target; you can then use the DXGI surface render target to draw 2-D content to the DXGI surface.

A DXGI surface render target is a type of ID2D1RenderTarget. Like other Direct2D render targets, you can use it to create resources and issue drawing commands.

The DXGI surface render target and the DXGI surface must use the same DXGI format. If you specify the DXGI_FORMAT_UNKOWN format when you create the render target, it will automatically use the surface's format.

The DXGI surface render target does not perform DXGI surface synchronization.

For more information about creating and using DXGI surface render targets, see the Direct2D and Direct3D Interoperability Overview.

To work with Direct2D, the Direct3D device that provides the IDXGISurface must be created with the D3D10_CREATE_DEVICE_BGRA_SUPPORT flag.

When you create a render target and hardware acceleration is available, you allocate resources on the computer's GPU. By creating a render target once and retaining it as long as possible, you gain performance benefits. Your application should create render targets once and hold onto them for the life of the application or until the render target's EndDraw method returns the D2DERR_RECREATE_TARGET error. When you receive this error, you need to recreate the render target (and any resources it created).

This library will throw a Harlinn::Common::Core::Exception when it encounters a D2DERR_RECREATE_TARGET error. Call GetHRESULT( ) on the exception object to determine if a D2DERR_RECREATE_TARGET error occurred.

◆ CreateEllipseGeometry() [1/7]

EllipseGeometry Harlinn::Windows::Graphics::Factory::CreateEllipseGeometry ( const D2D1_ELLIPSE & ellipse) const
inline

◆ CreateEllipseGeometry() [2/7]

void Harlinn::Windows::Graphics::Factory::CreateEllipseGeometry ( const D2D1_ELLIPSE & ellipse,
ID2D1EllipseGeometry ** ellipseGeometry ) const
inline

◆ CreateEllipseGeometry() [3/7]

EllipseGeometry Harlinn::Windows::Graphics::Factory::CreateEllipseGeometry ( const D2D1_ELLIPSE * ellipse) const
inline

◆ CreateEllipseGeometry() [4/7]

void Harlinn::Windows::Graphics::Factory::CreateEllipseGeometry ( const D2D1_ELLIPSE * ellipse,
ID2D1EllipseGeometry ** ellipseGeometry ) const
inline

Creates an ID2D1EllipseGeometry.

Parameters
ellipseA value that describes the center point, x-radius, and y-radius of the ellipse geometry.
ellipseGeometryWhen this method returns, contains the address of the pointer to the ellipse geometry created by this method.

◆ CreateEllipseGeometry() [5/7]

EllipseGeometry Harlinn::Windows::Graphics::Factory::CreateEllipseGeometry ( const D2D1_POINT_2F & centerPoint,
FLOAT radiusX,
FLOAT radiusY ) const
inline

◆ CreateEllipseGeometry() [6/7]

EllipseGeometry Harlinn::Windows::Graphics::Factory::CreateEllipseGeometry ( const D2D1_POINT_2F * centerPoint,
FLOAT radiusX,
FLOAT radiusY ) const
inline

◆ CreateEllipseGeometry() [7/7]

EllipseGeometry Harlinn::Windows::Graphics::Factory::CreateEllipseGeometry ( FLOAT centerX,
FLOAT centerY,
FLOAT radiusX,
FLOAT radiusY ) const
inline

◆ CreateGeometryGroup() [1/4]

GeometryGroup Harlinn::Windows::Graphics::Factory::CreateGeometryGroup ( D2D1_FILL_MODE fillMode,
const Geometry * geometries,
UINT32 geometriesCount ) const
inline

◆ CreateGeometryGroup() [2/4]

void Harlinn::Windows::Graphics::Factory::CreateGeometryGroup ( D2D1_FILL_MODE fillMode,
const Geometry * geometries,
UINT32 geometriesCount,
ID2D1GeometryGroup ** geometryGroup ) const
inline

◆ CreateGeometryGroup() [3/4]

GeometryGroup Harlinn::Windows::Graphics::Factory::CreateGeometryGroup ( D2D1_FILL_MODE fillMode,
ID2D1Geometry ** geometries,
UINT32 geometriesCount ) const
inline

◆ CreateGeometryGroup() [4/4]

void Harlinn::Windows::Graphics::Factory::CreateGeometryGroup ( D2D1_FILL_MODE fillMode,
ID2D1Geometry ** geometries,
UINT32 geometriesCount,
ID2D1GeometryGroup ** geometryGroup ) const
inline

Creates an ID2D1GeometryGroup, which is an object that holds other geometries.

Parameters
fillModeA value that specifies the rule that a composite shape uses to determine whether a given point is part of the geometry.
geometriesAn array containing the geometry objects to add to the geometry group. The number of elements in this array is indicated by the geometriesCount parameter.
geometriesCountThe number of elements in geometries.
geometryGroupWhen this method returns, contains the address of a pointer to the geometry group created by this method.

Geometry groups are a convenient way to group several geometries simultaneously so all figures of several distinct geometries are concatenated into one. To create a ID2D1GeometryGroup object, call the CreateGeometryGroup method on the ID2D1Factory object, passing in the fillMode with possible values of D2D1_FILL_MODE_ALTERNATE (alternate) and D2D1_FILL_MODE_WINDING, an array of geometry objects to add to the geometry group, and the number of elements in this array.

◆ CreateHwndRenderTarget() [1/6]

ControlRenderTarget Harlinn::Windows::Graphics::Factory::CreateHwndRenderTarget ( const D2D1_RENDER_TARGET_PROPERTIES & renderTargetProperties,
const D2D1_HWND_RENDER_TARGET_PROPERTIES & hwndRenderTargetProperties ) const
inline

◆ CreateHwndRenderTarget() [2/6]

void Harlinn::Windows::Graphics::Factory::CreateHwndRenderTarget ( const D2D1_RENDER_TARGET_PROPERTIES & renderTargetProperties,
const D2D1_HWND_RENDER_TARGET_PROPERTIES & hwndRenderTargetProperties,
ID2D1HwndRenderTarget ** hwndRenderTarget ) const
inline

◆ CreateHwndRenderTarget() [3/6]

ControlRenderTarget Harlinn::Windows::Graphics::Factory::CreateHwndRenderTarget ( const D2D1_RENDER_TARGET_PROPERTIES * renderTargetProperties,
const D2D1_HWND_RENDER_TARGET_PROPERTIES * hwndRenderTargetProperties ) const
inline

◆ CreateHwndRenderTarget() [4/6]

void Harlinn::Windows::Graphics::Factory::CreateHwndRenderTarget ( const D2D1_RENDER_TARGET_PROPERTIES * renderTargetProperties,
const D2D1_HWND_RENDER_TARGET_PROPERTIES * hwndRenderTargetProperties,
ID2D1HwndRenderTarget ** hwndRenderTarget ) const
inline

Creates an ID2D1HwndRenderTarget, a render target that renders to a window.

Parameters
renderTargetPropertiesThe rendering mode, pixel format, remoting options, DPI information, and the minimum DirectX support required for hardware rendering.
hwndRenderTargetPropertiesThe window handle, initial size (in pixels), and present options.
hwndRenderTargetWhen this method returns, contains the address of the pointer to the ID2D1HwndRenderTarget object created by this method.

When you create a render target and hardware acceleration is available, you allocate resources on the computer's GPU. By creating a render target once and retaining it as long as possible, you gain performance benefits. Your application should create render targets once and hold onto them for the life of the application or until the D2DERR_RECREATE_TARGET error is received. When you receive this error, you need to recreate the render target (and any resources it created).

This library will throw a Harlinn::Common::Core::Exception when it encounters a D2DERR_RECREATE_TARGET error. Call GetHRESULT( ) on the exception object to determine if a D2DERR_RECREATE_TARGET error occurred.

◆ CreateHwndRenderTarget() [5/6]

ControlRenderTarget Harlinn::Windows::Graphics::Factory::CreateHwndRenderTarget ( Control & control) const

◆ CreateHwndRenderTarget() [6/6]

ControlRenderTarget Harlinn::Windows::Graphics::Factory::CreateHwndRenderTarget ( HWND hwnd) const

◆ CreatePathGeometry() [1/2]

PathGeometry Harlinn::Windows::Graphics::Factory::CreatePathGeometry ( ) const
inline

◆ CreatePathGeometry() [2/2]

void Harlinn::Windows::Graphics::Factory::CreatePathGeometry ( ID2D1PathGeometry ** pathGeometry) const
inline

Creates an empty ID2D1PathGeometry.

Parameters
pathGeometryWhen this method returns, contains the address to a pointer to the path geometry created by this method.

◆ CreateRectangleGeometry() [1/7]

RectangleGeometry Harlinn::Windows::Graphics::Factory::CreateRectangleGeometry ( const D2D1_POINT_2F & position,
const D2D1_SIZE_F & size ) const
inline

◆ CreateRectangleGeometry() [2/7]

RectangleGeometry Harlinn::Windows::Graphics::Factory::CreateRectangleGeometry ( const D2D1_POINT_2F * position,
const D2D1_SIZE_F * size ) const
inline

◆ CreateRectangleGeometry() [3/7]

RectangleGeometry Harlinn::Windows::Graphics::Factory::CreateRectangleGeometry ( const D2D1_RECT_F & rectangle) const
inline

◆ CreateRectangleGeometry() [4/7]

void Harlinn::Windows::Graphics::Factory::CreateRectangleGeometry ( const D2D1_RECT_F & rectangle,
ID2D1RectangleGeometry ** rectangleGeometry ) const
inline

◆ CreateRectangleGeometry() [5/7]

RectangleGeometry Harlinn::Windows::Graphics::Factory::CreateRectangleGeometry ( const D2D1_RECT_F * rectangle) const
inline

◆ CreateRectangleGeometry() [6/7]

void Harlinn::Windows::Graphics::Factory::CreateRectangleGeometry ( const D2D1_RECT_F * rectangle,
ID2D1RectangleGeometry ** rectangleGeometry ) const
inline

Creates an ID2D1RectangleGeometry.

Parameters
rectangleThe coordinates of the rectangle geometry.
rectangleGeometryWhen this method returns, contains the address of the pointer to the rectangle geometry created by this function.

◆ CreateRectangleGeometry() [7/7]

RectangleGeometry Harlinn::Windows::Graphics::Factory::CreateRectangleGeometry ( FLOAT left,
FLOAT top,
FLOAT right,
FLOAT bottom ) const
inline

◆ CreateRoundedRectangleGeometry() [1/9]

RoundedRectangleGeometry Harlinn::Windows::Graphics::Factory::CreateRoundedRectangleGeometry ( const D2D1_POINT_2F & position,
const D2D1_SIZE_F & size,
FLOAT radiusX,
FLOAT readiusY ) const
inline

◆ CreateRoundedRectangleGeometry() [2/9]

RoundedRectangleGeometry Harlinn::Windows::Graphics::Factory::CreateRoundedRectangleGeometry ( const D2D1_POINT_2F * position,
const D2D1_SIZE_F * size,
FLOAT radiusX,
FLOAT readiusY ) const
inline

◆ CreateRoundedRectangleGeometry() [3/9]

RoundedRectangleGeometry Harlinn::Windows::Graphics::Factory::CreateRoundedRectangleGeometry ( const D2D1_RECT_F & rectangle,
FLOAT radiusX,
FLOAT readiusY ) const
inline

◆ CreateRoundedRectangleGeometry() [4/9]

RoundedRectangleGeometry Harlinn::Windows::Graphics::Factory::CreateRoundedRectangleGeometry ( const D2D1_RECT_F * rectangle,
FLOAT radiusX,
FLOAT readiusY ) const
inline

◆ CreateRoundedRectangleGeometry() [5/9]

RoundedRectangleGeometry Harlinn::Windows::Graphics::Factory::CreateRoundedRectangleGeometry ( const D2D1_ROUNDED_RECT & roundedRectangle) const
inline

◆ CreateRoundedRectangleGeometry() [6/9]

void Harlinn::Windows::Graphics::Factory::CreateRoundedRectangleGeometry ( const D2D1_ROUNDED_RECT & roundedRectangle,
ID2D1RoundedRectangleGeometry ** roundedRectangleGeometry ) const
inline

◆ CreateRoundedRectangleGeometry() [7/9]

RoundedRectangleGeometry Harlinn::Windows::Graphics::Factory::CreateRoundedRectangleGeometry ( const D2D1_ROUNDED_RECT * roundedRectangle) const
inline

◆ CreateRoundedRectangleGeometry() [8/9]

void Harlinn::Windows::Graphics::Factory::CreateRoundedRectangleGeometry ( const D2D1_ROUNDED_RECT * roundedRectangle,
ID2D1RoundedRectangleGeometry ** roundedRectangleGeometry ) const
inline

Creates an ID2D1RoundedRectangleGeometry.

Parameters
roundedRectangleThe coordinates and corner radii of the rounded rectangle geometry.
roundedRectangleGeometryWhen this method returns, contains the address of the pointer to the rounded rectangle geometry created by this method.

◆ CreateRoundedRectangleGeometry() [9/9]

RoundedRectangleGeometry Harlinn::Windows::Graphics::Factory::CreateRoundedRectangleGeometry ( FLOAT left,
FLOAT top,
FLOAT right,
FLOAT bottom,
FLOAT radiusX,
FLOAT readiusY ) const
inline

◆ CreateStrokeStyle() [1/4]

void Harlinn::Windows::Graphics::Factory::CreateStrokeStyle ( const D2D1_STROKE_STYLE_PROPERTIES & strokeStyleProperties,
const FLOAT * dashes,
UINT32 dashesCount,
ID2D1StrokeStyle ** strokeStyle ) const
inline

◆ CreateStrokeStyle() [2/4]

StrokeStyle Harlinn::Windows::Graphics::Factory::CreateStrokeStyle ( const D2D1_STROKE_STYLE_PROPERTIES & strokeStyleProperties,
const FLOAT * dashes = nullptr,
UINT32 dashesCount = 0 ) const
inline

◆ CreateStrokeStyle() [3/4]

void Harlinn::Windows::Graphics::Factory::CreateStrokeStyle ( const D2D1_STROKE_STYLE_PROPERTIES * strokeStyleProperties,
const FLOAT * dashes,
UINT32 dashesCount,
ID2D1StrokeStyle ** strokeStyle ) const
inline

Creates an ID2D1StrokeStyle that describes start cap, dash pattern, and other features of a stroke.

Parameters
strokeStylePropertiesA structure that describes the stroke's line cap, dash offset, and other details of a stroke.
dashesAn array whose elements are set to the length of each dash and space in the dash pattern. The first element sets the length of a dash, the second element sets the length of a space, the third element sets the length of a dash, and so on. The length of each dash and space in the dash pattern is the product of the element value in the array and the stroke width.
dashesCountThe number of elements in the dashes array.
strokeStyleWhen this method returns, contains the address of the pointer to the stroke style created by this method.

◆ CreateStrokeStyle() [4/4]

StrokeStyle Harlinn::Windows::Graphics::Factory::CreateStrokeStyle ( const D2D1_STROKE_STYLE_PROPERTIES * strokeStyleProperties,
const FLOAT * dashes = nullptr,
UINT32 dashesCount = 0 ) const
inline

◆ CreateTransformedGeometry() [1/8]

TransformedGeometry Harlinn::Windows::Graphics::Factory::CreateTransformedGeometry ( const Geometry & sourceGeometry,
const D2D1_MATRIX_3X2_F & transform ) const
inline

◆ CreateTransformedGeometry() [2/8]

void Harlinn::Windows::Graphics::Factory::CreateTransformedGeometry ( const Geometry & sourceGeometry,
const D2D1_MATRIX_3X2_F & transform,
ID2D1TransformedGeometry ** transformedGeometry ) const
inline

◆ CreateTransformedGeometry() [3/8]

TransformedGeometry Harlinn::Windows::Graphics::Factory::CreateTransformedGeometry ( const Geometry & sourceGeometry,
const D2D1_MATRIX_3X2_F * transform ) const
inline

◆ CreateTransformedGeometry() [4/8]

void Harlinn::Windows::Graphics::Factory::CreateTransformedGeometry ( const Geometry & sourceGeometry,
const D2D1_MATRIX_3X2_F * transform,
ID2D1TransformedGeometry ** transformedGeometry ) const
inline

◆ CreateTransformedGeometry() [5/8]

TransformedGeometry Harlinn::Windows::Graphics::Factory::CreateTransformedGeometry ( ID2D1Geometry * sourceGeometry,
const D2D1_MATRIX_3X2_F & transform ) const
inline

◆ CreateTransformedGeometry() [6/8]

void Harlinn::Windows::Graphics::Factory::CreateTransformedGeometry ( ID2D1Geometry * sourceGeometry,
const D2D1_MATRIX_3X2_F & transform,
ID2D1TransformedGeometry ** transformedGeometry ) const
inline

◆ CreateTransformedGeometry() [7/8]

TransformedGeometry Harlinn::Windows::Graphics::Factory::CreateTransformedGeometry ( ID2D1Geometry * sourceGeometry,
const D2D1_MATRIX_3X2_F * transform ) const
inline

◆ CreateTransformedGeometry() [8/8]

void Harlinn::Windows::Graphics::Factory::CreateTransformedGeometry ( ID2D1Geometry * sourceGeometry,
const D2D1_MATRIX_3X2_F * transform,
ID2D1TransformedGeometry ** transformedGeometry ) const
inline

Transforms the specified geometry and stores the result as an ID2D1TransformedGeometry object.

Parameters
sourceGeometryThe geometry to transform.
transformThe transformation to apply.
transformedGeometryWhen this method returns, contains the address of the pointer to the new transformed geometry object. The transformed geometry stores the result of transforming sourceGeometry by transform.

Like other resources, a transformed geometry inherits the resource space and threading policy of the factory that created it. This object is immutable.

When stroking a transformed geometry with the DrawGeometry method, the stroke width is not affected by the transform applied to the geometry. The stroke width is only affected by the world transform.

◆ CreateWicBitmapRenderTarget() [1/4]

RenderTarget Harlinn::Windows::Graphics::Factory::CreateWicBitmapRenderTarget ( IWICBitmap * target,
const D2D1_RENDER_TARGET_PROPERTIES & renderTargetProperties ) const
inline

◆ CreateWicBitmapRenderTarget() [2/4]

void Harlinn::Windows::Graphics::Factory::CreateWicBitmapRenderTarget ( IWICBitmap * target,
const D2D1_RENDER_TARGET_PROPERTIES & renderTargetProperties,
ID2D1RenderTarget ** renderTarget ) const
inline

◆ CreateWicBitmapRenderTarget() [3/4]

RenderTarget Harlinn::Windows::Graphics::Factory::CreateWicBitmapRenderTarget ( IWICBitmap * target,
const D2D1_RENDER_TARGET_PROPERTIES * renderTargetProperties ) const
inline

◆ CreateWicBitmapRenderTarget() [4/4]

void Harlinn::Windows::Graphics::Factory::CreateWicBitmapRenderTarget ( IWICBitmap * target,
const D2D1_RENDER_TARGET_PROPERTIES * renderTargetProperties,
ID2D1RenderTarget ** renderTarget ) const
inline

Creates a render target that renders to a Microsoft Windows Imaging Component (WIC) bitmap.

Parameters
targetThe bitmap that receives the rendering output of the render target.
renderTargetPropertiesThe rendering mode, pixel format, remoting options, DPI information, and the minimum DirectX support required for hardware rendering.
renderTargetWhen this method returns, contains the address of the pointer to the ID2D1RenderTarget object created by this method.

You must use D2D1_FEATURE_LEVEL_DEFAULT for the minLevel member of the renderTargetProperties parameter with this method.

Your application should create render targets once and hold onto them for the life of the application or until the D2DERR_RECREATE_TARGET error is received. When you receive this error, you need to recreate the render target (and any resources it created).

This library will throw a Harlinn::Common::Core::Exception when it encounters a D2DERR_RECREATE_TARGET error. Call GetHRESULT( ) on the exception object to determine if a D2DERR_RECREATE_TARGET error occurred.

◆ ReloadSystemMetrics()

void Harlinn::Windows::Graphics::Factory::ReloadSystemMetrics ( ) const
inline

Forces the factory to refresh any system defaults that it might have changed since factory creation.


The documentation for this class was generated from the following files: