port from perforce

This commit is contained in:
2026-04-18 22:31:51 +02:00
commit 8d0ab5b7cc
8409 changed files with 3972376 additions and 0 deletions

27
4kgfx/main.cpp Normal file
View File

@@ -0,0 +1,27 @@
#include "stdafx.h"
#pragma data_seg(".cube")
static Mesh cube;
#pragma code_seg(".func_main")
void __cdecl main(void)
{
#ifndef _DEBUG
ChangeDisplaySettingsA(&screenSettings, CDS_FULLSCREEN);
ShowCursor(0);
#endif
HDC hDC=GetDC(CreateWindowExA(0, "static", 0,WS_VISIBLE|WS_POPUP|WS_CLIPSIBLINGS|WS_CLIPCHILDREN,0,0,XRES,YRES,0,0,0,0));
SetPixelFormat(hDC, ChoosePixelFormat(hDC, &pfd), &pfd);
wglMakeCurrent(hDC, wglCreateContext(hDC));
wglMakeCurrent(hDC, ((PFNWGLCREATECONTEXTATTRIBSARBPROC)wglGetProcAddress("wglCreateContextAttribsARB"))(hDC, 0, attribs));
#ifdef _DEBUG
((PFNGLDEBUGMESSAGECALLBACKAMDPROC)wglGetProcAddress("glDebugMessageCallbackAMD"))(glDebugOutputAMD, 0);
#endif
cube.Render();
SwapBuffers(hDC);
while (!GetAsyncKeyState(27));
ExitProcess(0);
}