Update C headers to be C++

This commit is contained in:
2024-04-07 10:46:35 -05:00
parent 6702e60864
commit 3ef946ad4b
58 changed files with 153 additions and 225 deletions

View File

@@ -1,5 +1,5 @@
#pragma once
#include "../../stddef.h"
#include "../../stddef.hpp"
namespace JabyEngine {
template<typename T>

View File

@@ -1,5 +1,5 @@
#pragma once
#include "../jabyengine_defines.h"
#include "../jabyengine_defines.hpp"
#include "types.hpp"
namespace JabyEngine {

View File

@@ -1,5 +1,5 @@
#pragma once
#include "../../stdint.h"
#include "../../stdint.hpp"
namespace JabyEngine {
static constexpr int8_t operator""_i8(unsigned long long int value) {

View File

@@ -1,5 +1,5 @@
#pragma once
#include "../../stddef.h"
#include "../../stddef.hpp"
#include "array_range.hpp"
#include "types.hpp"

View File

@@ -1,6 +1,6 @@
#pragma once
#include "types.hpp"
#include <stddef.h>
#include <stddef.hpp>
namespace JabyEngine {
template<typename T>

View File

@@ -1,5 +1,5 @@
#pragma once
#include "../../stdint.h"
#include "../../stdint.hpp"
namespace JabyEngine {
uint16_t unaligned_lhu(const uint8_t* adr) {

View File

@@ -1,7 +1,7 @@
#pragma once
#include "../Auxiliary/bits.hpp"
#include "../GPU/gpu_types.hpp"
#include "../jabyengine_defines.h"
#include "../jabyengine_defines.hpp"
namespace JabyEngine {
#pragma pack(push, 1)

View File

@@ -1,6 +1,6 @@
#pragma once
#include "../Auxiliary/bits.hpp"
#include "../jabyengine_defines.h"
#include "../jabyengine_defines.hpp"
namespace JabyEngine {
namespace GPU {

View File

@@ -1,5 +1,5 @@
#pragma once
#include "../jabyengine_defines.h"
#include "../jabyengine_defines.hpp"
namespace JabyEngine {
namespace Periphery {

View File

@@ -1,7 +1,6 @@
#pragma once
#include "ioport.hpp"
#include "../../GPU/gpu_types.hpp"
#include <stdio.h>
namespace JabyEngine {
namespace GPU_IO {

View File

@@ -1,5 +1,5 @@
#pragma once
#include "../jabyengine_defines.h"
#include "../jabyengine_defines.hpp"
/*
R0 zr Constant Zero

View File

@@ -1,7 +1,7 @@
#ifndef __JABYENGINE_FRAME_TIME_HELPER_HPP__
#define __JABYENGINE_FRAME_TIME_HELPER_HPP__
#include <PSX/GPU/gpu.hpp>
#include <limits.h>
#include <limits.hpp>
namespace JabyEngine {
static constexpr double ms_per_frame = 1000.0/static_cast<double>(GPU::Display::frames_per_sec);

View File

@@ -1,7 +1,7 @@
#ifndef __JABYENGINE_FRAME_TIMER_HPP__
#define __JABYENGINE_FRAME_TIMER_HPP__
#include "frame_time_helper.hpp"
#include <stdint.h>
#include <stdint.hpp>
namespace JabyEngine {
class MasterTime {

View File

@@ -1,6 +1,6 @@
#ifndef __JABYENGINE_HIGH_RES_TIMER_HPP__
#define __JABYENGINE_HIGH_RES_TIMER_HPP__
#include "../jabyengine_defines.h"
#include "../jabyengine_defines.hpp"
#include <PSX/System/IOPorts/interrupt_io.hpp>
#include <PSX/System/IOPorts/timer_io.hpp>

View File

@@ -1,5 +1,5 @@
#pragma once
#include "jabyengine_defines.h"
#include "jabyengine_defines.hpp"
namespace JabyEngine {
typedef void (*MainRoutine)();

View File

@@ -1,6 +1,5 @@
#ifndef __JABYENGINE_DEFINES__H__
#define __JABYENGINE_DEFINES__H__
#include "../stddef.h"
#pragma once
#include "../stddef.hpp"
#define __used __attribute__((used))
#define __no_align __attribute__((packed))
@@ -22,5 +21,4 @@
#define __constexpr
#define START_C_FUNCTIONS
#define END_C_FUNCTIONS
#endif
#endif //!__JABYENGINE_DEFINES__H__
#endif