get all the commands to work
This commit is contained in:
@@ -5,3 +5,6 @@
|
||||
typedef struct gnPlatformCommandPool_t {
|
||||
id<MTLCommandQueue> commandQueue;
|
||||
} gnPlatformCommandPool;
|
||||
|
||||
gnReturnCode createMetalCommandPool(gnCommandPool commandPool, gnDevice device, gnCommandPoolInfo info);
|
||||
void destroyMetalCommandPool(gnCommandPool commandPool);
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
#include "metal_command_pool.h"
|
||||
#include "devices/metal_output_devices.h"
|
||||
|
||||
gnReturnCode gnCreateCommandPoolFn(struct gnCommandPool_t* commandPool, struct gnOutputDevice_t* device, gnCommandPoolInfo info) {
|
||||
gnReturnCode createMetalCommandPool(gnCommandPool commandPool, gnDevice device, gnCommandPoolInfo info) {
|
||||
commandPool->commandPool = malloc(sizeof(struct gnPlatformCommandPool_t));
|
||||
commandPool->commandPool->commandQueue = [device->outputDevice->device newCommandQueue];
|
||||
|
||||
return GN_SUCCESS;
|
||||
}
|
||||
|
||||
void gnDestroyCommandPoolFn(struct gnCommandPool_t* commandPool) {
|
||||
void destroyMetalCommandPool(gnCommandPool commandPool) {
|
||||
[commandPool->commandPool->commandQueue release];
|
||||
free(commandPool->commandPool);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user