do some more C stuff
This commit is contained in:
@@ -44,6 +44,7 @@ typedef struct gnFunctions_t {
|
||||
void (*_gnDestroyWindowSurface)(struct gnWindowSurface_t* windowSurface);
|
||||
} gnFunctions;
|
||||
|
||||
#include "core/presentation_queue/gryphn_presentation_queue.h"
|
||||
typedef struct gnDeviceFunctions_t {
|
||||
|
||||
gnReturnCode (*_gnCreatePresentationQueue)(gnPresentationQueue* presentationQueue, const gnOutputDevice* device, struct gnPresentationQueueInfo_t presentationInfo);
|
||||
} gnDeviceFunctions;
|
||||
|
@@ -68,5 +68,5 @@ void gnLoadFunctions(struct gnDynamicLibrary_t* lib, struct gnFunctions_t* funct
|
||||
}
|
||||
|
||||
void gnLoadDeviceFunctions(struct gnDynamicLibrary_t* lib, struct gnDeviceFunctions_t* functions) {
|
||||
|
||||
gnLoadDLLFunction(lib, functions->_gnCreatePresentationQueue, "gnCreatePresentationQueueFn");
|
||||
}
|
||||
|
@@ -1,9 +0,0 @@
|
||||
#pragma once
|
||||
#include "../output_device/gryphn_physical_output_device.h"
|
||||
|
||||
struct gnDevicePresentationDetails {
|
||||
public:
|
||||
int MinimumImageCount, MaximumImageCount;
|
||||
};
|
||||
|
||||
inline gnDevicePresentationDetails (*gnGetDevicePresentationDetails)(const gnPhysicalOutputDevice& physicalOutputDevice);
|
@@ -1,7 +0,0 @@
|
||||
#pragma once
|
||||
#include <gryphn/gryphn_utils.h>
|
||||
|
||||
typedef struct gnPresentationDetails_t {
|
||||
gnUInt ImageCount;
|
||||
gnUInt2 ImageSize;
|
||||
} gnPresentationDetails;
|
@@ -1,4 +1,9 @@
|
||||
#include "gryphn_presentation_queue.h"
|
||||
#include "core/gryphn_platform_functions.h"
|
||||
|
||||
gnReturnCode gnCreatePresentationQueue(gnPresentationQueue* presentationQueue, const gnOutputDevice* device, struct gnPresentationQueueInfo_t presentationInfo){
|
||||
return device->deviceFunctions->_gnCreatePresentationQueue(presentationQueue, device, presentationInfo);
|
||||
}
|
||||
|
||||
// gnTexture* gnGetPresentationQueueImage(gnPresentationQueue& presentationQueue, int index) {
|
||||
// // if (index < gnListLength(presentationQueue.images))
|
||||
|
@@ -1,12 +1,16 @@
|
||||
#pragma once
|
||||
#include <gryphn/gryphn_utils.h>
|
||||
#include "gryphn_presentation_details.h"
|
||||
#include "core/output_device/gryphn_output_device.h"
|
||||
// #include "core/sync_objects/gryphn_sync_semaphore.h"
|
||||
#include "gryphn_present_queue_state.h"
|
||||
// #include "core/sync_objects/gryphn_sync_semaphore.h"
|
||||
// #include "core/textures/gryphn_texture.h"
|
||||
// #include "gryphn_device_presentation_details.h"
|
||||
|
||||
typedef struct gnPresentationQueueInfo_t {
|
||||
gnUInt ImageCount;
|
||||
gnUInt2 ImageSize;
|
||||
} gnPresentationQueueInfo;
|
||||
|
||||
struct gnPlatformPresentationQueue_t;
|
||||
|
||||
typedef struct gnPresentationQueue_t {
|
||||
@@ -18,6 +22,8 @@ typedef struct gnPresentationQueue_t {
|
||||
|
||||
// gnTexture* gnGetPresentationQueueImage(gnPresentationQueue& presentationQueue, int index);
|
||||
|
||||
gnReturnCode gnCreatePresentationQueue(gnPresentationQueue* presentationQueue, const gnOutputDevice* device, struct gnPresentationQueueInfo_t presentationInfo);
|
||||
|
||||
// inline gnReturnCode (*gnCreatePresentationQueue)(gnPresentationQueue* presentationQueue, const gnOutputDevice& device, gnPresentationDetails& details);
|
||||
// inline void (*gnDestroyPresentationQueue)(gnPresentationQueue& queue);
|
||||
// inline gnImageFormat (*_gnPresentationQueueGetImageFormat)(gnPresentationQueue& presentationQueue);
|
||||
|
Reference in New Issue
Block a user