debugger handles
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
#include "init/gryphn_init.h"
|
||||
#include <core/gryphn_platform_functions.h>
|
||||
#include "core/debugger/gryphn_debugger.h"
|
||||
#include "core/instance/gryphn_instance.h"
|
||||
|
||||
gnReturnCode gnCreateInstance(gnInstanceHandle* instanceHandlePtr, struct gnInstanceInfo_t info) {
|
||||
*instanceHandlePtr = malloc(sizeof(struct gnInstance_t));
|
||||
@@ -42,4 +43,5 @@ void gnDestroyInstance(gnInstanceHandle instance) {
|
||||
|
||||
void gnInstanceReleaseDebugger(gnInstanceHandle instance) {
|
||||
instance->debugger = NULL;
|
||||
free(instance);
|
||||
}
|
||||
|
@@ -5,7 +5,7 @@
|
||||
struct gnPlatformInstance_t;
|
||||
struct gnFunctions_t;
|
||||
struct gnDynamicLibrary_t;
|
||||
struct gnDebugger_t;
|
||||
typedef struct gnDebugger_t* gnDebuggerHandle;
|
||||
|
||||
typedef struct gnInstanceInfo_t {
|
||||
gnString applicationName;
|
||||
@@ -17,6 +17,7 @@ typedef struct gnInstanceInfo_t {
|
||||
gnRenderingAPI renderingAPI;
|
||||
} gnInstanceInfo;
|
||||
|
||||
#ifdef GN_REVEAL_IMPL
|
||||
struct gnInstance_t {
|
||||
struct gnPlatformInstance_t* instance;
|
||||
gnBool valid,
|
||||
@@ -29,12 +30,13 @@ struct gnInstance_t {
|
||||
struct gnDeviceFunctions_t* deviceFunctions;
|
||||
struct gnCommandFunctions_t* commandFunctions;
|
||||
|
||||
struct gnDebugger_t* debugger;
|
||||
} gnInstance_t;
|
||||
|
||||
gnDebuggerHandle debugger;
|
||||
};
|
||||
#endif
|
||||
typedef struct gnInstance_t* gnInstanceHandle;
|
||||
typedef struct gnInstance_t* gnInstance;
|
||||
|
||||
gnReturnCode gnCreateInstance(gnInstanceHandle* instance, struct gnInstanceInfo_t info);
|
||||
void gnInstanceAttachDebugger(gnInstanceHandle istance, struct gnDebugger_t* debugger);
|
||||
void gnInstanceAttachDebugger(gnInstanceHandle istance, gnDebuggerHandle debugger);
|
||||
void gnInstanceReleaseDebugger(gnInstanceHandle instance);
|
||||
void gnDestroyInstance(gnInstanceHandle instance);
|
||||
|
Reference in New Issue
Block a user