rename to projects (DOES NOT COMPILE)

This commit is contained in:
Gregory Wells
2025-06-24 12:04:16 -04:00
parent 7a80d0fd61
commit d66f470a52
148 changed files with 2 additions and 4 deletions

View File

@@ -0,0 +1,12 @@
#pragma once
#include "core/command/command_buffer/gryphn_command_buffer.h"
#include "core/pipelines/graphics_pipeline/gryphn_graphics_pipeline.h"
#import <Metal/MTLCommandBuffer.h>
#import <Metal/MTLCommandEncoder.h>
typedef struct gnPlatformCommandBuffer_t {
id<MTLCommandBuffer> commandBuffer;
id<MTLCommandEncoder> encoder;
struct gnGraphicsPipeline_t* boundGraphcisPipeline;
gnBufferHandle indexBuffer;
} gnPlatformCommandBuffer;

View File

@@ -0,0 +1,24 @@
#include "metal_command_buffer.h"
#include "core/commands/command_pool/metal_command_pool.h"
#import <Metal/Metal.h>
gnReturnCode gnCommandPoolAllocateCommandBuffersFn(gnCommandBufferHandle* commandBuffers, uint32_t count, struct gnCommandPool_t* pool) {
for (int i = 0; i < count; i++) {
commandBuffers[i]->commandBuffer = malloc(sizeof(gnPlatformCommandBuffer));
}
return GN_SUCCESS;
}
void gnResetCommandBufferFn(struct gnCommandBuffer_t *commandBuffer) {
// do nothing
}
gnReturnCode gnBeginCommandBufferFn(struct gnCommandBuffer_t* commandBuffer) {
commandBuffer->commandBuffer->boundGraphcisPipeline = NULL;
commandBuffer->commandBuffer->commandBuffer = [commandBuffer->commandPool->commandPool->commandQueue commandBuffer];
return GN_SUCCESS;
}
gnReturnCode gnEndCommandBufferFn(struct gnCommandBuffer_t* commandBuffer) {
// [commandBuffer->commandBuffer->commandBuffer commit];
return GN_SUCCESS;
}