blob: 41f5f8491d76b37fb5fcd3f2293e292c01557f05 [file] [log] [blame]
Courtney Goeltzenleuchterb7f50502014-08-12 14:09:50 -06001#ifndef XGLGPU_H
2#define XGLGPU_H
3
4#include "test_common.h"
5
6#include <xgl.h>
7
8#define MAX_GPUS 8
9
10#define MAX_QUEUE_TYPES 5
11
12class XglGpu
13{
14public:
15 XglGpu(XGL_UINT id, XGL_PHYSICAL_GPU gpuObj);
16 void init_gpu();
17 void init_extensions();
Courtney Goeltzenleuchterb7f50502014-08-12 14:09:50 -060018 void init_formats();
Courtney Goeltzenleuchter42c144a2014-10-03 18:05:10 -060019 bool extension_exist(const char *ext_name);
Courtney Goeltzenleuchterb7f50502014-08-12 14:09:50 -060020
Courtney Goeltzenleuchtercc9da542014-08-12 14:12:22 -060021 // Do we want to hide/abstract this data?
22// private:
Courtney Goeltzenleuchterb7f50502014-08-12 14:09:50 -060023 XGL_UINT id;
24 XGL_PHYSICAL_GPU gpuObj;
25
26 XGL_PHYSICAL_GPU_PROPERTIES props;
27 XGL_PHYSICAL_GPU_PERFORMANCE perf;
28
29 XGL_UINT queue_count;
30 XGL_PHYSICAL_GPU_QUEUE_PROPERTIES *queue_props;
31 XGL_DEVICE_QUEUE_CREATE_INFO *queue_reqs;
32
33 XGL_PHYSICAL_GPU_MEMORY_PROPERTIES memory_props;
34
35 XGL_UINT extension_count;
36 const XGL_CHAR **extensions;
37
Courtney Goeltzenleuchtercc5eb3a2014-08-19 18:35:50 -060038 XGL_QUEUE m_queue;
Courtney Goeltzenleuchterb7f50502014-08-12 14:09:50 -060039
40 XGL_UINT heap_count;
41 XGL_MEMORY_HEAP_PROPERTIES *heap_props;
42 XGL_QUEUE queues[MAX_QUEUE_TYPES];
43
44 XGL_FORMAT_PROPERTIES format_props[XGL_MAX_CH_FMT][XGL_MAX_NUM_FMT];
45
46};
47
48#endif // XGLGPU_H