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

218
4kgfx/Crinkler/main.asm Normal file
View File

@@ -0,0 +1,218 @@
; Listing generated by Microsoft (R) Optimizing Compiler Version 16.00.40219.01
TITLE E:\Private\Frank\Code\blu-flame.org\4kgfx\main.cpp
.686P
.XMM
include listing.inc
.model flat
INCLUDELIB MSVCRT
INCLUDELIB OLDNAMES
CONST SEGMENT
_pfd DW 00H
DW 01H
DD 021H
DB 00H
DB 020H
DB 00H
DB 00H
DB 00H
DB 00H
DB 00H
DB 00H
DB 00H
DB 00H
DB 00H
DB 00H
DB 00H
DB 00H
DB 08H
ORG $+17
_attribs DD 02091H
DD 03H
DD 02092H
DD 03H
DD 02094H
DD 02H
DD 00H
CONST ENDS
screenSettings SEGMENT
_screenSettings DB 00H
ORG $+31
DW 00H
DW 00H
DW 07cH
DW 00H
DD 01c0000H
DW 00H
ORG $+14
DW 00H
DW 00H
DW 00H
DW 00H
DW 00H
DB 00H
ORG $+31
DW 00H
DD 020H
DD 0500H
DD 02d0H
DD 00H
DD 00H
screenSettings ENDS
PUBLIC ??_C@_0BL@PDDHMPGF@wglCreateContextAttribsARB?$AA@ ; `string'
PUBLIC ??_C@_06GGHJAEBN@static?$AA@ ; `string'
PUBLIC _main
EXTRN __imp__ExitProcess@4:PROC
EXTRN __imp__GetAsyncKeyState@4:PROC
EXTRN __imp__SwapBuffers@4:PROC
EXTRN ?Render@Mesh@@QAEXXZ:PROC ; Mesh::Render
EXTRN __imp__wglGetProcAddress@4:PROC
EXTRN __imp__wglMakeCurrent@8:PROC
EXTRN __imp__wglCreateContext@4:PROC
EXTRN __imp__SetPixelFormat@12:PROC
EXTRN __imp__ChoosePixelFormat@8:PROC
EXTRN __imp__GetDC@4:PROC
EXTRN __imp__CreateWindowExA@48:PROC
EXTRN __imp__ShowCursor@4:PROC
EXTRN __imp__ChangeDisplaySettingsA@8:PROC
; COMDAT ??_C@_0BL@PDDHMPGF@wglCreateContextAttribsARB?$AA@
; File e:\private\frank\code\blu-flame.org\4kgfx\main.cpp
CONST SEGMENT
??_C@_0BL@PDDHMPGF@wglCreateContextAttribsARB?$AA@ DB 'wglCreateContextAt'
DB 'tribsARB', 00H ; `string'
CONST ENDS
; COMDAT ??_C@_06GGHJAEBN@static?$AA@
CONST SEGMENT
??_C@_06GGHJAEBN@static?$AA@ DB 'static', 00H ; `string'
; Function compile flags: /Ogspy
CONST ENDS
func_main SEGMENT
_main PROC
; 8 : {
push ebx
push esi
push edi
; 9 : #ifndef _DEBUG
; 10 : ChangeDisplaySettingsA(&screenSettings, CDS_FULLSCREEN);
push 4
push OFFSET _screenSettings
call DWORD PTR __imp__ChangeDisplaySettingsA@8
; 11 : ShowCursor(0);
xor edi, edi
push edi
call DWORD PTR __imp__ShowCursor@4
; 12 : #endif
; 13 : HDC hDC=GetDC(CreateWindowExA(0, "static", 0,WS_VISIBLE|WS_POPUP|WS_CLIPSIBLINGS|WS_CLIPCHILDREN,0,0,XRES,YRES,0,0,0,0));
push edi
push edi
push edi
push edi
push 720 ; 000002d0H
push 1280 ; 00000500H
push edi
push edi
push -1778384896 ; 96000000H
push edi
push OFFSET ??_C@_06GGHJAEBN@static?$AA@
push edi
call DWORD PTR __imp__CreateWindowExA@48
push eax
call DWORD PTR __imp__GetDC@4
mov esi, eax
; 14 : SetPixelFormat(hDC, ChoosePixelFormat(hDC, &pfd), &pfd);
mov eax, OFFSET _pfd
push eax
push eax
push esi
call DWORD PTR __imp__ChoosePixelFormat@8
push eax
push esi
call DWORD PTR __imp__SetPixelFormat@12
; 15 : wglMakeCurrent(hDC, wglCreateContext(hDC));
push esi
call DWORD PTR __imp__wglCreateContext@4
mov ebx, DWORD PTR __imp__wglMakeCurrent@8
push eax
push esi
call ebx
; 16 : wglMakeCurrent(hDC, ((PFNWGLCREATECONTEXTATTRIBSARBPROC)wglGetProcAddress("wglCreateContextAttribsARB"))(hDC, 0, attribs));
push OFFSET _attribs
push edi
push esi
push OFFSET ??_C@_0BL@PDDHMPGF@wglCreateContextAttribsARB?$AA@
call DWORD PTR __imp__wglGetProcAddress@4
call eax
push eax
push esi
call ebx
; 17 :
; 18 : #ifdef _DEBUG
; 19 : ((PFNGLDEBUGMESSAGECALLBACKAMDPROC)wglGetProcAddress("glDebugMessageCallbackAMD"))(glDebugOutputAMD, 0);
; 20 : #endif
; 21 :
; 22 : cube.Render();
mov ecx, OFFSET _cube
call ?Render@Mesh@@QAEXXZ ; Mesh::Render
; 23 : SwapBuffers(hDC);
push esi
call DWORD PTR __imp__SwapBuffers@4
$LL2@main:
; 24 :
; 25 : while (!GetAsyncKeyState(27));
push 27 ; 0000001bH
call DWORD PTR __imp__GetAsyncKeyState@4
test ax, ax
je SHORT $LL2@main
; 26 : ExitProcess(0);
push edi
call DWORD PTR __imp__ExitProcess@4
pop edi
pop esi
pop ebx
$LN7@main:
$LN6@main:
_main ENDP
func_main ENDS
EXTRN ??0Mesh@@QAE@XZ:PROC ; Mesh::Mesh
; Function compile flags: /Ogspy
; COMDAT ??__Ecube@@YAXXZ
compile SEGMENT
??__Ecube@@YAXXZ PROC ; `dynamic initializer for 'cube'', COMDAT
; 4 : static Mesh cube;
mov ecx, OFFSET _cube
jmp ??0Mesh@@QAE@XZ ; Mesh::Mesh
??__Ecube@@YAXXZ ENDP ; `dynamic initializer for 'cube''
compile ENDS
_BSS SEGMENT
_cube DB 0488040H DUP (?)
_BSS ENDS
CRT$XCU SEGMENT
_cube$initializer$ DD FLAT:??__Ecube@@YAXXZ
CRT$XCU ENDS
END