ReactOS  0.4.13-dev-73-gcfe54aa
d3d9_cursor.c File Reference
#include "d3d9_cursor.h"
#include <debug.h>
#include <d3d9.h>
#include "d3d9_private.h"
#include "adapter.h"
#include "d3d9_device.h"
#include "d3d9_swapchain.h"
#include "d3d9_helpers.h"
Include dependency graph for d3d9_cursor.c:

Go to the source code of this file.

Functions

D3D9CursorCreateD3D9Cursor (struct _Direct3DDevice9_INT *pBaseDevice, struct _Direct3DSwapChain9_INT *pSwapChain)
 

Function Documentation

◆ CreateD3D9Cursor()

D3D9Cursor* CreateD3D9Cursor ( struct _Direct3DDevice9_INT pBaseDevice,
struct _Direct3DSwapChain9_INT pSwapChain 
)

Definition at line 18 of file d3d9_cursor.c.

19 {
20  D3D9Cursor* pCursor;
21 
22  if (FAILED(AlignedAlloc((LPVOID*)&pCursor, sizeof(D3D9Cursor))))
23  {
24  DPRINT1("Failed to allocate D3D9Cursor");
25  return NULL;
26  }
27 
28  pCursor->pBaseDevice = pBaseDevice;
29  pCursor->pSwapChain = pSwapChain;
30  pCursor->dwWidth = pSwapChain->dwWidth / 2;
31  pCursor->dwHeight = pSwapChain->dwHeight / 2;
32 
33  return pCursor;
34 }
smooth NULL
Definition: ftsmooth.c:416
HRESULT AlignedAlloc(IN OUT LPVOID *ppObject, IN SIZE_T dwSize)
Definition: d3d9_helpers.c:95
#define DPRINT1
Definition: precomp.h:8

Referenced by Direct3DSwapChain9_Init().