summaryrefslogtreecommitdiff
path: root/include/user/paf/graphics.h
diff options
context:
space:
mode:
authorGrapheneCt2021-04-17 12:13:59 -0400
committerReiko Asakura2021-04-17 14:32:37 -0400
commit9c2c72f154499a5083cba60974722fb5b971730c (patch)
treef8b3cef185a4bb2c6b23fb8a0a0d377df0f9982b /include/user/paf/graphics.h
parentAdd kernel/npdrm.h (diff)
downloadvds-libraries-9c2c72f154499a5083cba60974722fb5b971730c.tar.gz
Update ScePaf NIDs and headers
Diffstat (limited to '')
-rw-r--r--include/user/paf/graphics.h107
1 files changed, 106 insertions, 1 deletions
diff --git a/include/user/paf/graphics.h b/include/user/paf/graphics.h
index 33889ee..101a94a 100644
--- a/include/user/paf/graphics.h
+++ b/include/user/paf/graphics.h
@@ -5,11 +5,116 @@
#ifndef _VDSUITE_USER_PAF_GRAPHICS_H
#define _VDSUITE_USER_PAF_GRAPHICS_H
+#include <kernel.h>
+#include <gxm.h>
#include <scetypes.h>
+#include <paf/misc.h>
namespace paf {
+
namespace graphics {
+ class MemoryPool
+ {
+ public:
+
+ class InitParam
+ {
+ public:
+
+ ScePVoid pMemory;
+ SceSize size;
+ char *pName;
+ paf::Allocator::Opt *pAllocatorOpt;
+ ScePVoid pUnkAllocatorOpt;
+ SceUInt32 memoryType;
+ };
+
+ MemoryPool(InitParam *pInitParam);
+
+ MemoryPool(ScePVoid pMemory, SceSize size, const char *pName, paf::Allocator::Opt *pAllocatorOpt = SCE_NULL, SceUInt32 memoryType = 0);
+
+ virtual ~MemoryPool();
+
+ virtual int unkf1();
+ virtual int unkf2();
+ virtual int unkf3();
+
+ enum MemoryType
+ {
+ MemoryType_UserNC,
+ MemoryType_CDRAM,
+ MemoryType_Shared,
+ };
+
+ enum MemoryTypeSpecial
+ {
+ MemoryTypeSpecial_Unused,
+ MemoryTypeSpecial_Unk0xCF08060,
+ MemoryTypeSpecial_Phycont
+ };
+
+ enum GpuMapType
+ {
+ GpuMapType_Normal,
+ GpuMapType_VertexUsse,
+ GpuMapType_FragmentUsse,
+ GpuMapType_NoMap,
+ };
+
+ class MemBlockOptParam
+ {
+ public:
+
+ MemoryTypeSpecial memoryTypeSpecial;
+ SceKernelAllocMemBlockOpt *memBlockOpt;
+ GpuMapType gpuMapType;
+ SceUInt32 mapAttribs;
+ SceUInt32 usseOffset;
+ SceUInt32 unused;
+ };
+
+ static ScePVoid AllocMemBlock(MemoryType memoryType, SceSize size, const char *pName, ScePVoid pOptParam = SCE_NULL);
+
+ static SceVoid FreeMemBlock(MemoryType memoryType, ScePVoid pMemory);
+
+ static MemoryPool *GetDefaultMemoryPool();
+
+ private:
+
+ SceUChar8 m_work[0x48];
+
+ };
+
+ class Surface
+ {
+ public:
+
+ Surface(MemoryPool *pMemPool, SceUInt32 width, SceUInt32 height, SceUInt32 format, SceUInt32 orderType, SceInt32 a7, SceUInt32 numLevel, SceInt32 a9);
+
+ virtual ~Surface();
+
+ virtual int unkf1();
+ virtual int unkf2();
+ virtual int unkf3();
+ virtual int unkf4();
+ virtual int unkf5();
+ virtual int unkf6();
+ virtual int unkf7();
+ virtual int unkf8();
+ virtual int unkf9();
+ virtual int unkf10();
+
+ void* operator new(size_t size);
+
+ void operator delete(void*);
+
+ private:
+
+ SceUChar8 m_work[0x44];
+
+ };
+
class Texture
{
public:
@@ -18,7 +123,7 @@ namespace paf {
~Texture() { };
-
+ Surface *texSurface;
private: