forked from KolibriOS/kolibrios
tinygl.obj: add some functions,
load_img.inc: delete old file load_lib git-svn-id: svn://kolibrios.org@8442 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
@@ -651,6 +651,21 @@ enum {
|
||||
GL_ALL_ATTRIB_BITS = 0x000fffff
|
||||
};
|
||||
|
||||
/* some types */
|
||||
|
||||
typedef int GLenum;
|
||||
typedef void GLvoid;
|
||||
typedef unsigned char GLboolean;
|
||||
typedef signed char GLbyte; /* 1-byte signed */
|
||||
typedef short int GLshort; /* 2-byte signed */
|
||||
typedef long int GLint; /* 4-byte signed */
|
||||
typedef unsigned char GLubyte; /* 1-byte unsigned */
|
||||
typedef unsigned short int GLushort; /* 2-byte unsigned */
|
||||
typedef unsigned long int GLuint; /* 4-byte unsigned */
|
||||
typedef float GLfloat; /* single precision float */
|
||||
typedef double GLdouble; /* double precision float */
|
||||
typedef int GLsizei;
|
||||
|
||||
struct ZBuffer
|
||||
{
|
||||
long int xsize, ysize;
|
||||
@@ -701,34 +716,34 @@ void (__stdcall* glVertex4d)(double x, double y, double z, double w) = (void (__
|
||||
void (__stdcall* glVertex4fv)(float* v) = (void (__stdcall*)(float*))&"glVertex4fv";
|
||||
void (__stdcall* glVertex4dv)(double* v) = (void (__stdcall*)(double*))&"glVertex4dv";
|
||||
void (__stdcall* glColor3f)(float r, float g, float b) = (void (__stdcall*)(float, float, float))&"glColor3f";
|
||||
//void (__stdcall* glColor3d)(...) = (void (__stdcall*)(...))&"glColor3d";
|
||||
//void (__stdcall* glColor3fv)(...) = (void (__stdcall*)(...))&"glColor3fv";
|
||||
//void (__stdcall* glColor3dv)(...) = (void (__stdcall*)(...))&"glColor3dv";
|
||||
void (__stdcall* glColor3d)(double r, double g, double b) = (void (__stdcall*)(double, double, double))&"glColor3d";
|
||||
void (__stdcall* glColor3fv)(float* v) = (void (__stdcall*)(float*))&"glColor3fv";
|
||||
void (__stdcall* glColor3dv)(double* v) = (void (__stdcall*)(double*))&"glColor3dv";
|
||||
void (__stdcall* glColor3ub)(unsigned char r, unsigned char g, unsigned char b) = (void (__stdcall*)(unsigned char, unsigned char, unsigned char))&"glColor3ub";
|
||||
//void (__stdcall* glColor4f)(...) = (void (__stdcall*)(...))&"glColor4f";
|
||||
//void (__stdcall* glColor4d)(...) = (void (__stdcall*)(...))&"glColor4d";
|
||||
//void (__stdcall* glColor4fv)(...) = (void (__stdcall*)(...))&"glColor4fv";
|
||||
//void (__stdcall* glColor4dv)(...) = (void (__stdcall*)(...))&"glColor4dv";
|
||||
void (__stdcall* glColor4f)(float r, float g, float b, float a) = (void (__stdcall*)(float, float, float, float))&"glColor4f";
|
||||
void (__stdcall* glColor4d)(double r, double g, double b, double a) = (void (__stdcall*)(double, double, double, double))&"glColor4d";
|
||||
void (__stdcall* glColor4fv)(float* v) = (void (__stdcall*)(float*))&"glColor4fv";
|
||||
void (__stdcall* glColor4dv)(double* v) = (void (__stdcall*)(double*))&"glColor4dv";
|
||||
void (__stdcall* glNormal3f)(float x, float y, float z) = (void (__stdcall*)(float, float, float))&"glNormal3f";
|
||||
//void (__stdcall* glNormal3d)(...) = (void (__stdcall*)(...))&"glNormal3d";
|
||||
//void (__stdcall* glNormal3fv)(...) = (void (__stdcall*)(...))&"glNormal3fv";
|
||||
//void (__stdcall* glNormal3dv)(...) = (void (__stdcall*)(...))&"glNormal3dv";
|
||||
//void (__stdcall* glTexCoord1f)(...) = (void (__stdcall*)(...))&"glTexCoord1f";
|
||||
//void (__stdcall* glTexCoord1d)(...) = (void (__stdcall*)(...))&"glTexCoord1d";
|
||||
//void (__stdcall* glTexCoord1fv)(...) = (void (__stdcall*)(...))&"glTexCoord1fv";
|
||||
//void (__stdcall* glTexCoord1dv)(...) = (void (__stdcall*)(...))&"glTexCoord1dv";
|
||||
void (__stdcall* glNormal3d)(double x, double y, double z) = (void (__stdcall*)(double, double, double))&"glNormal3d";
|
||||
void (__stdcall* glNormal3fv)(float* v) = (void (__stdcall*)(float*))&"glNormal3fv";
|
||||
void (__stdcall* glNormal3dv)(double* v) = (void (__stdcall*)(double*))&"glNormal3dv";
|
||||
void (__stdcall* glTexCoord1f)(float s) = (void (__stdcall*)(float))&"glTexCoord1f";
|
||||
void (__stdcall* glTexCoord1d)(double s) = (void (__stdcall*)(double))&"glTexCoord1d";
|
||||
void (__stdcall* glTexCoord1fv)(float* v) = (void (__stdcall*)(float*))&"glTexCoord1fv";
|
||||
void (__stdcall* glTexCoord1dv)(double* v) = (void (__stdcall*)(double*))&"glTexCoord1dv";
|
||||
void (__stdcall* glTexCoord2f)(float s, float t) = (void (__stdcall*)(float, float))&"glTexCoord2f";
|
||||
//void (__stdcall* glTexCoord2d)(...) = (void (__stdcall*)(...))&"glTexCoord2d";
|
||||
void (__stdcall* glTexCoord2d)(double s, double t) = (void (__stdcall*)(double, double))&"glTexCoord2d";
|
||||
void (__stdcall* glTexCoord2fv)(float* v) = (void (__stdcall*)(float*))&"glTexCoord2fv";
|
||||
//void (__stdcall* glTexCoord2dv)(...) = (void (__stdcall*)(...))&"glTexCoord2dv";
|
||||
//void (__stdcall* glTexCoord3f)(...) = (void (__stdcall*)(...))&"glTexCoord3f";
|
||||
//void (__stdcall* glTexCoord3d)(...) = (void (__stdcall*)(...))&"glTexCoord3d";
|
||||
//void (__stdcall* glTexCoord3fv)(...) = (void (__stdcall*)(...))&"glTexCoord3fv";
|
||||
//void (__stdcall* glTexCoord3dv)(...) = (void (__stdcall*)(...))&"glTexCoord3dv";
|
||||
void (__stdcall* glTexCoord2dv)(double* v) = (void (__stdcall*)(double*))&"glTexCoord2dv";
|
||||
void (__stdcall* glTexCoord3f)(float s, float t, float r) = (void (__stdcall*)(float, float, float))&"glTexCoord3f";
|
||||
void (__stdcall* glTexCoord3d)(double s, double t, double r) = (void (__stdcall*)(double, double, double))&"glTexCoord3d";
|
||||
void (__stdcall* glTexCoord3fv)(float* v) = (void (__stdcall*)(float*))&"glTexCoord3fv";
|
||||
void (__stdcall* glTexCoord3dv)(double* v) = (void (__stdcall*)(double*))&"glTexCoord3dv";
|
||||
void (__stdcall* glTexCoord4f)(float s, float t, float r, float q) = (void (__stdcall*)(float, float, float, float))&"glTexCoord4f";
|
||||
//void (__stdcall* glTexCoord4d)(...) = (void (__stdcall*)(...))&"glTexCoord4d";
|
||||
//void (__stdcall* glTexCoord4fv)(...) = (void (__stdcall*)(...))&"glTexCoord4fv";
|
||||
//void (__stdcall* glTexCoord4dv)(...) = (void (__stdcall*)(...))&"glTexCoord4dv";
|
||||
void (__stdcall* glTexCoord4d)(double s, double t, double r, double q) = (void (__stdcall*)(double, double, double, double))&"glTexCoord4d";
|
||||
void (__stdcall* glTexCoord4fv)(float* v) = (void (__stdcall*)(float*))&"glTexCoord4fv";
|
||||
void (__stdcall* glTexCoord4dv)(double* v) = (void (__stdcall*)(double*))&"glTexCoord4dv";
|
||||
void (__stdcall* glEdgeFlag)(int flag) = (void (__stdcall*)(int))&"glEdgeFlag";
|
||||
void (__stdcall* glMatrixMode)(int mode) = (void (__stdcall*)(int))&"glMatrixMode";
|
||||
void (__stdcall* glLoadMatrixf)(const float* m) = (void (__stdcall*)(const float*))&"glLoadMatrixf";
|
||||
@@ -761,28 +776,28 @@ void (__stdcall* glBindTexture)(int target, int texture) = (void (__stdcall*)(in
|
||||
void (__stdcall* glTexImage2D)(int target, int level, int components, int width, int height, int border, int format, int type, void *pixels) = (void (__stdcall*)(int, int, int, int, int, int, int, int, void*))&"glTexImage2D";
|
||||
void (__stdcall* glTexEnvi)(int target, int pname, int param) = (void (__stdcall*)(int, int, int))&"glTexEnvi";
|
||||
void (__stdcall* glTexParameteri)(int target, int pname, int param) = (void (__stdcall*)(int, int, int))&"glTexParameteri";
|
||||
//void (__stdcall* glPixelStorei)(...) = (void (__stdcall*)(...))&"glPixelStorei";
|
||||
void (__stdcall* glPixelStorei)(int pname, int param) = (void (__stdcall*)(int, int))&"glPixelStorei";
|
||||
void (__stdcall* glMaterialfv)(int mode, int type, float* v) = (void (__stdcall*)(int, int, float*))&"glMaterialfv";
|
||||
void (__stdcall* glMaterialf)(int mode, int type, float v) = (void (__stdcall*)(int, int, float))&"glMaterialf";
|
||||
void (__stdcall* glColorMaterial)(int mode, int type) = (void (__stdcall*)(int, int))&"glColorMaterial";
|
||||
void (__stdcall* glLightfv)(int light, int type, float* v) = (void (__stdcall*)(int, int, float*))&"glLightfv";
|
||||
//void (__stdcall* glLightf)(...) = (void (__stdcall*)(...))&"glLightf";
|
||||
//void (__stdcall* glLightModeli)(...) = (void (__stdcall*)(...))&"glLightModeli";
|
||||
void (__stdcall* glLightf)(int light, int type, float v) = (void (__stdcall*)(int, int, float))&"glLightf";
|
||||
void (__stdcall* glLightModeli)(int pname, int param) = (void (__stdcall*)(int, int))&"glLightModeli";
|
||||
void (__stdcall* glLightModelfv)(int pname, float* param) = (void (__stdcall*)(int, float*))&"glLightModelfv";
|
||||
//void (__stdcall* glFlush)(...) = (void (__stdcall*)(...))&"glFlush";
|
||||
//void (__stdcall* glHint)(...) = (void (__stdcall*)(...))&"glHint";
|
||||
//void (__stdcall* glGetIntegerv)(...) = (void (__stdcall*)(...))&"glGetIntegerv";
|
||||
void (__stdcall* glFlush)() = (void (__stdcall*)())&"glFlush";
|
||||
void (__stdcall* glHint)(int target, int mode) = (void (__stdcall*)(int, int))&"glHint";
|
||||
void (__stdcall* glGetIntegerv)(int pname, int *params) = (void (__stdcall*)(int, int*))&"glGetIntegerv";
|
||||
//void (__stdcall* glGetFloatv)(...) = (void (__stdcall*)(...))&"glGetFloatv";
|
||||
//void (__stdcall* glFrontFace)(...) = (void (__stdcall*)(...))&"glFrontFace";
|
||||
//void (__stdcall* glEnableClientState)(...) = (void (__stdcall*)(...))&"glEnableClientState";
|
||||
//void (__stdcall* glDisableClientState)(...) = (void (__stdcall*)(...))&"glDisableClientState";
|
||||
//void (__stdcall* glArrayElement)(...) = (void (__stdcall*)(...))&"glArrayElement";
|
||||
//void (__stdcall* glDrawArrays)(...) = (void (__stdcall*)(...))&"glDrawArrays";
|
||||
//void (__stdcall* glDrawElements)(...) = (void (__stdcall*)(...))&"glDrawElements";
|
||||
//void (__stdcall* glVertexPointer)(...) = (void (__stdcall*)(...))&"glVertexPointer";
|
||||
//void (__stdcall* glColorPointer)(...) = (void (__stdcall*)(...))&"glColorPointer";
|
||||
//void (__stdcall* glNormalPointer)(...) = (void (__stdcall*)(...))&"glNormalPointer";
|
||||
//void (__stdcall* glTexCoordPointer)(...) = (void (__stdcall*)(...))&"glTexCoordPointer";
|
||||
void (__stdcall* glFrontFace)(int mode) = (void (__stdcall*)(int))&"glFrontFace";
|
||||
void (__stdcall* glEnableClientState)(GLenum array) = (void (__stdcall*)(GLenum))&"glEnableClientState";
|
||||
void (__stdcall* glDisableClientState)(GLenum array) = (void (__stdcall*)(GLenum))&"glDisableClientState";
|
||||
void (__stdcall* glArrayElement)(GLint index) = (void (__stdcall*)(GLint))&"glArrayElement";
|
||||
void (__stdcall* glDrawArrays)(GLenum mode, GLint first, GLsizei count) = (void (__stdcall*)(GLenum, GLint, GLsizei))&"glDrawArrays";
|
||||
void (__stdcall* glDrawElements)(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices) = (void (__stdcall*)(GLenum, GLsizei, GLenum, const GLvoid*))&"glDrawElements";
|
||||
void (__stdcall* glVertexPointer)(GLint size, GLenum type, GLsizei stride, const GLvoid* pointer) = (void (__stdcall*)(GLint, GLenum, GLsizei, const GLvoid*))&"glVertexPointer";
|
||||
void (__stdcall* glColorPointer)(GLint size, GLenum type, GLsizei stride, const GLvoid* pointer) = (void (__stdcall*)(GLint, GLenum, GLsizei, const GLvoid*))&"glColorPointer";
|
||||
void (__stdcall* glNormalPointer)(GLenum type, GLsizei stride, const GLvoid* pointer) = (void (__stdcall*)(GLenum, GLsizei, const GLvoid*))&"glNormalPointer";
|
||||
void (__stdcall* glTexCoordPointer)(GLint size, GLenum type, GLsizei stride, const GLvoid* pointer) = (void (__stdcall*)(GLint, GLenum, GLsizei, const GLvoid*))&"glTexCoordPointer";
|
||||
//void (__stdcall* glPolygonOffset)(...) = (void (__stdcall*)(...))&"glPolygonOffset";
|
||||
//void (__stdcall* glOrtho)(...) = (void (__stdcall*)(...))&"glOrtho";
|
||||
//void (__stdcall* glDebug)(...) = (void (__stdcall*)(...))&"glDebug";
|
||||
|
@@ -142,6 +142,19 @@ glNormal3f: ;x, y, z
|
||||
pop eax
|
||||
ret 16 ;=sizeof(dd)*4
|
||||
|
||||
align 4
|
||||
proc glNormal3d, x:qword, y:qword, z:qword
|
||||
add esp,-12
|
||||
fld qword[z]
|
||||
fstp dword[esp+8]
|
||||
fld qword[y]
|
||||
fstp dword[esp+4]
|
||||
fld qword[x]
|
||||
fstp dword[esp]
|
||||
call glNormal3f
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glNormal3fv uses eax, v:dword
|
||||
mov eax,[v]
|
||||
@@ -149,6 +162,20 @@ proc glNormal3fv uses eax, v:dword
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glNormal3dv uses eax, v:dword
|
||||
mov eax,[v]
|
||||
add esp,-12
|
||||
fld qword[eax+16]
|
||||
fstp dword[esp+8]
|
||||
fld qword[eax+8]
|
||||
fstp dword[esp+4]
|
||||
fld qword[eax]
|
||||
fstp dword[esp]
|
||||
call glNormal3f
|
||||
ret
|
||||
endp
|
||||
|
||||
; glColor
|
||||
|
||||
align 4
|
||||
@@ -179,6 +206,21 @@ endl
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glColor4d, r:qword, g:qword, b:qword, a:qword
|
||||
add esp,-16
|
||||
fld qword[a]
|
||||
fstp dword[esp+12]
|
||||
fld qword[b]
|
||||
fstp dword[esp+8]
|
||||
fld qword[g]
|
||||
fstp dword[esp+4]
|
||||
fld qword[r]
|
||||
fstp dword[esp]
|
||||
call glColor4f
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glColor4fv uses eax ebx, v:dword
|
||||
mov eax,[v]
|
||||
@@ -192,6 +234,20 @@ proc glColor3f, r:dword, g:dword, b:dword
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glColor3d, r:qword, g:qword, b:qword
|
||||
push 1.0
|
||||
add esp,-12
|
||||
fld qword[b]
|
||||
fstp dword[esp+8]
|
||||
fld qword[g]
|
||||
fstp dword[esp+4]
|
||||
fld qword[r]
|
||||
fstp dword[esp]
|
||||
call glColor4f
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glColor3fv uses eax, v:dword
|
||||
mov eax,[v]
|
||||
@@ -199,6 +255,21 @@ proc glColor3fv uses eax, v:dword
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glColor3dv uses eax, v:dword
|
||||
mov eax,[v]
|
||||
push 1.0
|
||||
add esp,-12
|
||||
fld qword[eax+16]
|
||||
fstp dword[esp+8]
|
||||
fld qword[eax+8]
|
||||
fstp dword[esp+4]
|
||||
fld qword[eax]
|
||||
fstp dword[esp]
|
||||
call glColor4f
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
fl_255 dd 255.0
|
||||
|
||||
@@ -230,6 +301,22 @@ proc glColor3ub uses eax, r:dword, g:dword, b:dword
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glColor4dv uses eax, v:dword
|
||||
mov eax,[v]
|
||||
add esp,-16
|
||||
fld qword[eax+24]
|
||||
fstp dword[esp+12]
|
||||
fld qword[eax+16]
|
||||
fstp dword[esp+8]
|
||||
fld qword[eax+8]
|
||||
fstp dword[esp+4]
|
||||
fld qword[eax]
|
||||
fstp dword[esp]
|
||||
call glColor4f
|
||||
ret
|
||||
endp
|
||||
|
||||
; TexCoord
|
||||
|
||||
align 4
|
||||
@@ -242,12 +329,78 @@ glTexCoord4f: ;s, t, r, q
|
||||
pop eax
|
||||
ret 20 ;=sizeof(dd)*5
|
||||
|
||||
align 4
|
||||
proc glTexCoord4d, s:qword, t:qword, r:qword, q:qword
|
||||
add esp,-16
|
||||
fld qword[q]
|
||||
fstp dword[esp+12]
|
||||
fld qword[r]
|
||||
fstp dword[esp+8]
|
||||
fld qword[t]
|
||||
fstp dword[esp+4]
|
||||
fld qword[s]
|
||||
fstp dword[esp]
|
||||
call glTexCoord4f
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord1f, s:dword
|
||||
stdcall glTexCoord4f,[s],0.0,0.0,1.0
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord1d, s:qword
|
||||
push 1.0
|
||||
push 0.0
|
||||
push 0.0
|
||||
add esp,-4
|
||||
fld qword[s]
|
||||
fstp dword[esp]
|
||||
call glTexCoord4f
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord1fv uses eax, v:dword
|
||||
mov eax,[v]
|
||||
stdcall glTexCoord4f,[eax],0.0,0.0,1.0
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord1dv uses eax, v:dword
|
||||
mov eax,[v]
|
||||
push 1.0
|
||||
push 0.0
|
||||
push 0.0
|
||||
add esp,-4
|
||||
fld qword[eax]
|
||||
fstp dword[esp]
|
||||
call glTexCoord4f
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord2f, s:dword, t:dword
|
||||
stdcall glTexCoord4f,[s],[t],0.0,1.0
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord2d, s:qword, t:qword
|
||||
push 1.0
|
||||
push 0.0
|
||||
add esp,-8
|
||||
fld qword[t]
|
||||
fstp dword[esp+4]
|
||||
fld qword[s]
|
||||
fstp dword[esp]
|
||||
call glTexCoord4f
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord2fv uses eax, v:dword
|
||||
mov eax,[v]
|
||||
@@ -255,6 +408,85 @@ proc glTexCoord2fv uses eax, v:dword
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord2dv uses eax, v:dword
|
||||
mov eax,[v]
|
||||
push 1.0
|
||||
push 0.0
|
||||
add esp,-8
|
||||
fld qword[eax+8]
|
||||
fstp dword[esp+4]
|
||||
fld qword[eax]
|
||||
fstp dword[esp]
|
||||
call glTexCoord4f
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord3f, s:dword, t:dword, r:dword
|
||||
stdcall glTexCoord4f,[s],[t],[r],1.0
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord3d, s:qword, t:qword, r:qword
|
||||
push 1.0
|
||||
add esp,-12
|
||||
fld qword[r]
|
||||
fstp dword[esp+8]
|
||||
fld qword[t]
|
||||
fstp dword[esp+4]
|
||||
fld qword[s]
|
||||
fstp dword[esp]
|
||||
call glTexCoord4f
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord3fv uses eax, v:dword
|
||||
mov eax,[v]
|
||||
stdcall glTexCoord4f,[eax],[eax+4],[eax+8],1.0
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord3dv uses eax, v:dword
|
||||
mov eax,[v]
|
||||
push 1.0
|
||||
add esp,-12
|
||||
fld qword[eax+16]
|
||||
fstp dword[esp+8]
|
||||
fld qword[eax+8]
|
||||
fstp dword[esp+4]
|
||||
fld qword[eax]
|
||||
fstp dword[esp]
|
||||
call glTexCoord4f
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord4fv uses eax, v:dword
|
||||
mov eax,[v]
|
||||
stdcall glTexCoord4f,[eax],[eax+4],[eax+8],[eax+12]
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc glTexCoord4dv uses eax, v:dword
|
||||
mov eax,[v]
|
||||
add esp,-16
|
||||
fld qword[eax+24]
|
||||
fstp dword[esp+12]
|
||||
fld qword[eax+16]
|
||||
fstp dword[esp+8]
|
||||
fld qword[eax+8]
|
||||
fstp dword[esp+4]
|
||||
fld qword[eax]
|
||||
fstp dword[esp]
|
||||
call glTexCoord4f
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
glEdgeFlag: ;flag
|
||||
push dword[esp] ;копируем адрес возврата
|
||||
@@ -883,7 +1115,7 @@ glHint: ;target, mode
|
||||
|
||||
align 4
|
||||
proc glDebug uses eax, mode:dword
|
||||
stdcall gl_get_context ;после вызова функции в eax указатель на GLContext
|
||||
call gl_get_context ;после вызова функции в eax указатель на GLContext
|
||||
push dword[mode]
|
||||
pop dword[eax+GLContext.print_flag]
|
||||
ret
|
||||
|
45
programs/develop/libraries/TinyGL/asm_fork/get.asm
Normal file
45
programs/develop/libraries/TinyGL/asm_fork/get.asm
Normal file
@@ -0,0 +1,45 @@
|
||||
align 4
|
||||
proc glGetIntegerv uses eax edi, pname:dword, params:dword
|
||||
mov eax,[pname]
|
||||
mov edi,[params]
|
||||
cmp eax,GL_VIEWPORT
|
||||
jne @f
|
||||
push esi
|
||||
call gl_get_context
|
||||
lea esi,[eax+GLContext.viewport]
|
||||
movsd ;m2m dword[edi],dword[eax+GLContext.viewport.xmin]
|
||||
movsd ;copy .ymin
|
||||
movsd ;copy .xsize
|
||||
movsd ;copy .ysize
|
||||
pop esi
|
||||
jmp .endf
|
||||
@@:
|
||||
cmp eax,GL_MAX_MODELVIEW_STACK_DEPTH
|
||||
jne @f
|
||||
mov dword[edi],MAX_MODELVIEW_STACK_DEPTH
|
||||
jmp .endf
|
||||
@@:
|
||||
cmp eax,GL_MAX_PROJECTION_STACK_DEPTH
|
||||
jne @f
|
||||
mov dword[edi],MAX_PROJECTION_STACK_DEPTH
|
||||
jmp .endf
|
||||
@@:
|
||||
cmp eax,GL_MAX_LIGHTS
|
||||
jne @f
|
||||
mov dword[edi],MAX_LIGHTS
|
||||
jmp .endf
|
||||
@@:
|
||||
cmp eax,GL_MAX_TEXTURE_SIZE
|
||||
jne @f
|
||||
mov dword[edi],4096
|
||||
jmp .endf
|
||||
@@:
|
||||
cmp eax,GL_MAX_TEXTURE_STACK_DEPTH
|
||||
jne @f
|
||||
mov dword[edi],MAX_TEXTURE_STACK_DEPTH
|
||||
jmp .endf
|
||||
@@:
|
||||
stdcall dbg_print,sz_kosglMakeCurrent,err_glGet
|
||||
.endf:
|
||||
ret
|
||||
endp
|
@@ -21,7 +21,7 @@ include 'misc.asm'
|
||||
include 'clear.asm'
|
||||
include 'light.asm'
|
||||
include 'select.asm'
|
||||
;include 'get.asm'
|
||||
include 'get.asm'
|
||||
;include 'error.asm'
|
||||
include 'zbuffer.asm'
|
||||
include 'zline.asm'
|
||||
@@ -52,14 +52,17 @@ m_6 db '(6)',13,10,0
|
||||
m_7 db '(7)',13,10,0
|
||||
m_8 db '(8)',13,10,0
|
||||
m_9 db '(9)',13,10,0
|
||||
f_fill_tr_nl db ' lines',0
|
||||
f_zbz db ' ZB_line_z',0
|
||||
f_zb db ' ZB_line',0
|
||||
|
||||
buf_param rb 80
|
||||
|
||||
align 4
|
||||
proc str_n_cat uses eax ecx edi esi, str1:dword, str2:dword, n_len:dword
|
||||
mov esi,dword[str2]
|
||||
mov ecx,dword[n_len]
|
||||
mov edi,dword[str1]
|
||||
mov esi,[str2]
|
||||
mov ecx,[n_len]
|
||||
mov edi,[str1]
|
||||
stdcall str_len,edi
|
||||
add edi,eax
|
||||
cld
|
||||
@@ -105,26 +108,6 @@ align 4
|
||||
end if
|
||||
|
||||
; ***
|
||||
glColor3d: ;(double ,double ,double)
|
||||
glColor3dv: ;(double *)
|
||||
glColor4d: ;(double ,double ,double, double )
|
||||
glColor4dv: ;(double *)
|
||||
glNormal3d: ;(double ,double ,double)
|
||||
glNormal3dv: ;(double *)
|
||||
glTexCoord1f: ;(float)
|
||||
glTexCoord1d: ;(double)
|
||||
glTexCoord1fv: ;(float *)
|
||||
glTexCoord1dv: ;(double *)
|
||||
glTexCoord2d: ;(double ,double)
|
||||
glTexCoord2dv: ;(double *)
|
||||
glTexCoord3f: ;(float ,float ,float)
|
||||
glTexCoord3d: ;(double ,double ,double)
|
||||
glTexCoord3fv: ;(float *)
|
||||
glTexCoord3dv: ;(double *)
|
||||
glTexCoord4d: ;(double ,double ,double, double )
|
||||
glTexCoord4fv: ;(float *)
|
||||
glTexCoord4dv: ;(double *)
|
||||
glGetIntegerv: ;(int pname,int *params)
|
||||
glGetFloatv: ;(int pname, float *v)
|
||||
|
||||
align 4
|
||||
@@ -139,13 +122,7 @@ err_6 db 'unsupported option',13,10,0
|
||||
err_7 db 'assert(target == GL_TEXTURE_2D && texture >= 0)',13,10,0
|
||||
err_8 db 'combinaison of parameters not handled',13,10,0
|
||||
err_9 db 'GL_INVALID_ENUM',13,10,0
|
||||
f_zbz db ' ZB_line_z',0
|
||||
f_zb db ' ZB_line',0
|
||||
f_find_l db 'find_list',0
|
||||
f_alloc_l db 'alloc_list',0
|
||||
f_fill_tr db 'ZB_fillTriangle...',0
|
||||
f_fill_tr_nl db ' lines',0
|
||||
f_fill_tr_nll db ' len',0
|
||||
err_glGet db 'glGet: option not implemented',0
|
||||
|
||||
align 4
|
||||
proc dbg_print, fun:dword, mes:dword
|
||||
|
@@ -26,7 +26,7 @@
|
||||
|
||||
; <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>祭<EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD>室<EFBFBD><EFBFBD><EFBFBD><EFBFBD> 䠩<EFBFBD><EFBFBD><EFBFBD>:
|
||||
include 'dll.inc'
|
||||
include 'develop/libraries/box_lib/load_lib.mac'
|
||||
;include 'load_lib.mac'
|
||||
include 'develop/libraries/libs-dev/libio/libio.inc'
|
||||
|
||||
align 4
|
||||
|
@@ -1,7 +1,5 @@
|
||||
if not exist bin mkdir bin
|
||||
@copy *.vox bin\*.vox
|
||||
if not exist bin\buf2d.obj @fasm.exe -m 16384 ..\..\..\develop\libraries\buf2d\trunk\buf2d.asm bin\buf2d.obj
|
||||
@kpack bin\buf2d.obj
|
||||
@fasm.exe -m 16384 voxel_editor.asm bin\voxel_editor.kex
|
||||
@kpack bin\voxel_editor.kex
|
||||
pause
|
@@ -3,15 +3,16 @@ use32
|
||||
db 'MENUET01' ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>. <20>ᯮ<EFBFBD><E1AFAE>塞<EFBFBD><EFA5AC><EFBFBD> 䠩<><E4A0A9> <20>ᥣ<EFBFBD><E1A5A3> 8 <20><><EFBFBD><EFBFBD>
|
||||
dd 1, start, i_end, mem, stacktop, openfile_path, sys_path
|
||||
|
||||
include '../../../../programs/macros.inc'
|
||||
include '../../../../programs/proc32.inc'
|
||||
include '../../../../programs/KOSfuncs.inc'
|
||||
include '../../../../programs/load_img.inc'
|
||||
include '../../../macros.inc'
|
||||
include '../../../proc32.inc'
|
||||
include '../../../KOSfuncs.inc'
|
||||
include '../../../load_img.inc'
|
||||
include '../../../load_lib.mac'
|
||||
include 'vox_draw.inc'
|
||||
include 'vox_rotate.inc'
|
||||
include 'str.inc'
|
||||
|
||||
@use_library_mem mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
|
||||
@use_library mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
|
||||
caption db 'Voxel editor 22.03.18',0 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
|
||||
IMAGE_TOOLBAR_ICON_SIZE equ 16*16*3
|
||||
@@ -1730,39 +1731,21 @@ db 'VOX',0
|
||||
db 0
|
||||
|
||||
|
||||
|
||||
head_f_i:
|
||||
head_f_l db '<27><><EFBFBD>⥬<EFBFBD><E2A5AC><EFBFBD> <20>訡<EFBFBD><E8A8A1>',0
|
||||
|
||||
system_dir_0 db '/sys/lib/'
|
||||
lib_name_0 db 'proc_lib.obj',0
|
||||
err_message_found_lib_0 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'proc_lib.obj',39,0
|
||||
err_message_import_0 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'proc_lib.obj',39,0
|
||||
|
||||
system_dir_1 db '/sys/lib/'
|
||||
lib_name_1 db 'libimg.obj',0
|
||||
err_message_found_lib_1 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libimg.obj',39,0
|
||||
err_message_import_1 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libimg.obj',39,0
|
||||
|
||||
system_dir_2 db '/sys/lib/'
|
||||
lib_name_2 db 'buf2d.obj',0
|
||||
err_msg_found_lib_2 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'buf2d.obj',39,0
|
||||
err_msg_import_2 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'buf2d',39,0
|
||||
|
||||
system_dir_3 db '/sys/lib/'
|
||||
lib_name_3 db 'libini.obj',0
|
||||
err_msg_found_lib_3 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libini.obj',39,0
|
||||
err_msg_import_3 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libini',39,0
|
||||
|
||||
|
||||
l_libs_start:
|
||||
lib_0 l_libs lib_name_0, sys_path, file_name, system_dir_0,\
|
||||
err_message_found_lib_0, head_f_l, proclib_import,err_message_import_0, head_f_i
|
||||
lib_1 l_libs lib_name_1, sys_path, file_name, system_dir_1,\
|
||||
err_message_found_lib_1, head_f_l, import_libimg, err_message_import_1, head_f_i
|
||||
lib_2 l_libs lib_name_2, sys_path, library_path, system_dir_2,\
|
||||
err_msg_found_lib_2,head_f_l,import_buf2d,err_msg_import_2,head_f_i
|
||||
lib_3 l_libs lib_name_3, sys_path, library_path, system_dir_3,\
|
||||
err_msg_found_lib_3,head_f_l,import_libini,err_msg_import_3,head_f_i
|
||||
lib_0 l_libs lib_name_0, file_name, system_dir_0, import_proclib
|
||||
lib_1 l_libs lib_name_1, file_name, system_dir_1, import_libimg
|
||||
lib_2 l_libs lib_name_2, file_name, system_dir_2, import_buf2d
|
||||
lib_3 l_libs lib_name_3, file_name, system_dir_3, import_libini
|
||||
l_libs_end:
|
||||
|
||||
align 4
|
||||
@@ -1813,7 +1796,7 @@ import_libimg:
|
||||
aimg_draw db 'img_draw',0
|
||||
|
||||
align 4
|
||||
proclib_import: ;<3B><><EFBFBD>ᠭ<EFBFBD><E1A0AD> <20><>ᯮ<EFBFBD><E1AFAE><EFBFBD><EFBFBD>㥬<EFBFBD><E3A5AC> <20>㭪権
|
||||
import_proclib:
|
||||
OpenDialog_Init dd aOpenDialog_Init
|
||||
OpenDialog_Start dd aOpenDialog_Start
|
||||
dd 0,0
|
||||
@@ -1913,12 +1896,6 @@ dd 0,0
|
||||
aini_get_int db 'ini_get_int',0
|
||||
aini_get_color db 'ini_get_color',0
|
||||
|
||||
mouse_dd dd 0x0
|
||||
sc system_colors
|
||||
|
||||
align 16
|
||||
procinfo process_information
|
||||
|
||||
;<3B><><EFBFBD><EFBFBD><EFBFBD> <20>᭮<EFBFBD><E1ADAE><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>ࠦ<EFBFBD><E0A0A6><EFBFBD><EFBFBD>
|
||||
align 4
|
||||
buf_0: dd 0 ;㪠<><E3AAA0>⥫<EFBFBD> <20><> <20>a<EFBFBD><61><EFBFBD> <20><><EFBFBD><EFBFBD>ࠦ<EFBFBD><E0A0A6><EFBFBD><EFBFBD>
|
||||
@@ -1958,8 +1935,6 @@ buf_r_z:
|
||||
rb BUF_STRUCT_SIZE
|
||||
|
||||
align 4
|
||||
cursor_pointer dd 0 ;㪠<><E3AAA0>⥫<EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
buf_curs: ;<3B><><EFBFBD><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD><EFBFBD>ࠬ<EFBFBD>
|
||||
.data: dd 0 ;㪠<><E3AAA0>⥫<EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>ࠦ<EFBFBD><E0A0A6><EFBFBD><EFBFBD>
|
||||
dw 0 ;+4 left
|
||||
@@ -2011,15 +1986,17 @@ buf_vox_g2:
|
||||
|
||||
align 16
|
||||
i_end:
|
||||
procinfo process_information
|
||||
sc system_colors
|
||||
mouse_dd dd ?
|
||||
cursor_pointer dd ? ;㪠<><E3AAA0>⥫<EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
wnd_s_pos: ;<3B><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>⮢<EFBFBD><E2AEA2> <20><><EFBFBD><EFBFBD>樨 <20><><EFBFBD><EFBFBD>
|
||||
rq 0
|
||||
rb 4096
|
||||
align 16
|
||||
stacktop:
|
||||
sys_path rb 1024
|
||||
file_name:
|
||||
rb 1024 ;4096
|
||||
library_path rb 1024
|
||||
file_name rb 2048 ;4096
|
||||
plugin_path rb 1024 ;4096
|
||||
openfile_path rb 4096
|
||||
filename_area rb 256
|
||||
|
@@ -3,10 +3,11 @@ use32
|
||||
db 'MENUET01' ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>. <20>ᯮ<EFBFBD><E1AFAE>塞<EFBFBD><EFA5AC><EFBFBD> 䠩<><E4A0A9> <20>ᥣ<EFBFBD><E1A5A3> 8 <20><><EFBFBD><EFBFBD>
|
||||
dd 1,start,i_end,mem,stacktop,openfile_path,sys_path
|
||||
|
||||
include '../../../../programs/macros.inc'
|
||||
include '../../../../programs/proc32.inc'
|
||||
include '../../../../programs/KOSfuncs.inc'
|
||||
include '../../../../programs/load_img.inc'
|
||||
include '../../../macros.inc'
|
||||
include '../../../proc32.inc'
|
||||
include '../../../KOSfuncs.inc'
|
||||
include '../../../load_img.inc'
|
||||
include '../../../load_lib.mac'
|
||||
include '../trunk/str.inc'
|
||||
include 'lang.inc'
|
||||
|
||||
@@ -15,7 +16,7 @@ vox_offs_data equ 12
|
||||
txt_buf rb 8
|
||||
include '../trunk/vox_rotate.inc'
|
||||
|
||||
@use_library_mem mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
|
||||
@use_library mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
|
||||
if lang eq ru
|
||||
caption db '<27><><EFBFBD><EFBFBD><EFBFBD>⥫<EFBFBD> <20><><EFBFBD>ᥫ<EFBFBD><E1A5AB> 04.05.20',0 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
else
|
||||
@@ -32,7 +33,6 @@ buf2d_size_lt equ dword[edi+4] ;
|
||||
buf2d_color equ dword[edi+16] ;梥<> 䮭<> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
buf2d_bits equ byte[edi+20] ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⢮ <20><><EFBFBD> <20> 1-<2D> <20><>窥 <20><><EFBFBD><EFBFBD>ࠦ<EFBFBD><E0A0A6><EFBFBD><EFBFBD>
|
||||
|
||||
run_file_70 FileInfoBlock
|
||||
vox_obj_size dd 0 ;ࠧ<><E0A0A7><EFBFBD> <20><><EFBFBD>ᥫ쭮<E1A5AB><ECADAE> <20><>ꥪ<EFBFBD><EAA5AA> (<28><><EFBFBD> <20>७<E1AAAE><E0A5AD> <20><>⠢<EFBFBD><E2A0A2>)
|
||||
txt_space db ' ',0
|
||||
if lang eq ru
|
||||
@@ -1278,40 +1278,12 @@ lib_name_2 db 'buf2d.obj',0
|
||||
system_dir_3 db '/sys/lib/'
|
||||
lib_name_3 db 'msgbox.obj',0
|
||||
|
||||
align 4
|
||||
head_f_i:
|
||||
if lang eq ru
|
||||
head_f_l db '"<22><><EFBFBD>⥬<EFBFBD><E2A5AC><EFBFBD> <20>訡<EFBFBD><E8A8A1>',0
|
||||
err_message_found_lib_0 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_import_0 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_found_lib_1 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libimg.obj',39,'" -tE',0
|
||||
err_message_import_1 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libimg.obj',39,'" -tE',0
|
||||
err_msg_found_lib_2 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'buf2d.obj',39,'" -tE',0
|
||||
err_msg_import_2 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'buf2d',39,'" -tE',0
|
||||
err_msg_found_lib_3 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'msgbox.obj',39,'" -tE',0
|
||||
err_msg_import_3 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'msgbox',39,'" -tE',0
|
||||
else
|
||||
head_f_l db '"System error',0
|
||||
err_message_found_lib_0 db 'Sorry I cannot found library ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_import_0 db 'Error on load import library ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_found_lib_1 db 'Sorry I cannot found library ',39,'libimg.obj',39,'" -tE',0
|
||||
err_message_import_1 db 'Error on load import library ',39,'libimg.obj',39,'" -tE',0
|
||||
err_msg_found_lib_2 db 'Sorry I cannot found library ',39,'buf2d.obj',39,'" -tE',0
|
||||
err_msg_import_2 db 'Error on load import library ',39,'buf2d',39,'" -tE',0
|
||||
err_msg_found_lib_3 db 'Sorry I cannot found library ',39,'msgbox.obj',39,'" -tE',0
|
||||
err_msg_import_3 db 'Error on load import library ',39,'msgbox',39,'" -tE',0
|
||||
end if
|
||||
|
||||
align 4
|
||||
l_libs_start:
|
||||
lib_0 l_libs lib_name_0, sys_path, file_name, system_dir_0,\
|
||||
err_message_found_lib_0, head_f_l, proclib_import,err_message_import_0, head_f_i
|
||||
lib_1 l_libs lib_name_1, sys_path, file_name, system_dir_1,\
|
||||
err_message_found_lib_1, head_f_l, import_libimg, err_message_import_1, head_f_i
|
||||
lib_2 l_libs lib_name_2, sys_path, library_path, system_dir_2,\
|
||||
err_msg_found_lib_2,head_f_l,import_buf2d,err_msg_import_2,head_f_i
|
||||
lib_3 l_libs lib_name_3, sys_path, library_path, system_dir_3,\
|
||||
err_msg_found_lib_3,head_f_l,import_msgbox_lib,err_msg_import_3,head_f_i
|
||||
lib_0 l_libs lib_name_0, file_name, system_dir_0, import_proclib
|
||||
lib_1 l_libs lib_name_1, file_name, system_dir_1, import_libimg
|
||||
lib_2 l_libs lib_name_2, file_name, system_dir_2, import_buf2d
|
||||
lib_3 l_libs lib_name_3, file_name, system_dir_3, import_msgbox_lib
|
||||
l_libs_end:
|
||||
|
||||
align 4
|
||||
@@ -1362,7 +1334,7 @@ import_libimg:
|
||||
aimg_draw db 'img_draw',0
|
||||
|
||||
align 4
|
||||
proclib_import: ;<3B><><EFBFBD>ᠭ<EFBFBD><E1A0AD> <20><>ᯮ<EFBFBD><E1AFAE><EFBFBD><EFBFBD>㥬<EFBFBD><E3A5AC> <20>㭪権
|
||||
import_proclib:
|
||||
OpenDialog_Init dd aOpenDialog_Init
|
||||
OpenDialog_Start dd aOpenDialog_Start
|
||||
dd 0,0
|
||||
@@ -1455,13 +1427,6 @@ dd 0,0
|
||||
; amb_reinit db 'mb_reinit',0
|
||||
; amb_setfunctions db 'mb_setfunctions',0
|
||||
|
||||
mouse_dd dd 0
|
||||
sc system_colors
|
||||
last_time dd 0
|
||||
|
||||
align 16
|
||||
procinfo process_information
|
||||
|
||||
align 4
|
||||
buf_0: dd 0
|
||||
dw 5 ;+4 left
|
||||
@@ -1562,14 +1527,17 @@ buf_vox:
|
||||
|
||||
align 16
|
||||
i_end:
|
||||
procinfo process_information
|
||||
sc system_colors
|
||||
run_file_70 FileInfoBlock
|
||||
mouse_dd dd ?
|
||||
last_time dd ?
|
||||
rb 2048
|
||||
thread:
|
||||
rb 2048
|
||||
stacktop:
|
||||
sys_path rb 1024
|
||||
file_name:
|
||||
rb 1024 ;4096
|
||||
library_path rb 1024
|
||||
file_name rb 2048 ;4096
|
||||
plugin_path rb 4096
|
||||
openfile_path rb 4096
|
||||
filename_area rb 256
|
||||
|
@@ -3,24 +3,23 @@ use32
|
||||
db 'MENUET01' ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>. <20>ᯮ<EFBFBD><E1AFAE>塞<EFBFBD><EFA5AC><EFBFBD> 䠩<><E4A0A9> <20>ᥣ<EFBFBD><E1A5A3> 8 <20><><EFBFBD><EFBFBD>
|
||||
dd 1, start, i_end, mem, stacktop, openfile_path, sys_path
|
||||
|
||||
include '../../../../programs/macros.inc'
|
||||
include '../../../../programs/proc32.inc'
|
||||
include '../../../../programs/KOSfuncs.inc'
|
||||
include '../../../../programs/load_img.inc'
|
||||
include '../../../macros.inc'
|
||||
include '../../../proc32.inc'
|
||||
include '../../../KOSfuncs.inc'
|
||||
include '../../../load_img.inc'
|
||||
include '../../../load_lib.mac'
|
||||
include '../trunk/vox_draw.inc'
|
||||
include '../trunk/vox_rotate.inc'
|
||||
include '../trunk/str.inc'
|
||||
include 'lang.inc'
|
||||
|
||||
@use_library_mem mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
|
||||
@use_library mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
|
||||
if lang eq ru
|
||||
caption db '<27><>६<EFBFBD>饭<EFBFBD><E9A5AD> <20><><EFBFBD>ᥫ<EFBFBD><E1A5AB> 04.05.20',0 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
else
|
||||
caption db 'Voxel mover 04.05.20',0
|
||||
end if
|
||||
|
||||
run_file_70 FileInfoBlock
|
||||
|
||||
IMAGE_TOOLBAR_ICON_SIZE equ 16*16*3
|
||||
image_data_toolbar dd 0
|
||||
|
||||
@@ -61,7 +60,7 @@ align 4
|
||||
start:
|
||||
load_libraries l_libs_start,l_libs_end
|
||||
;<3B><EFBFBD>ઠ <20><> <>쪮 㤠筮 <20><><EFBFBD>㧨<EFBFBD><E3A7A8><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD>
|
||||
mov ebp,lib_2
|
||||
mov ebp,lib0
|
||||
cmp dword [ebp+ll_struc_size-4],0
|
||||
jz @f
|
||||
mcall SF_TERMINATE_PROCESS
|
||||
@@ -1333,39 +1332,11 @@ lib_name_2 db 'buf2d.obj',0
|
||||
system_dir_3 db '/sys/lib/'
|
||||
lib_name_3 db 'libini.obj',0
|
||||
|
||||
align 4
|
||||
head_f_i:
|
||||
if lang eq ru
|
||||
head_f_l db '"<22><><EFBFBD>⥬<EFBFBD><E2A5AC><EFBFBD> <20>訡<EFBFBD><E8A8A1>',0
|
||||
err_message_found_lib_0 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_import_0 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_found_lib_1 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libimg.obj',39,'" -tE',0
|
||||
err_message_import_1 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libimg.obj',39,'" -tE',0
|
||||
err_msg_found_lib_2 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'buf2d.obj',39,'" -tE',0
|
||||
err_msg_import_2 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'buf2d',39,'" -tE',0
|
||||
err_msg_found_lib_3 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libini.obj',39,'" -tE',0
|
||||
err_msg_import_3 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libini',39,'" -tE',0
|
||||
else
|
||||
head_f_l db '"System error',0
|
||||
err_message_found_lib_0 db 'Sorry I cannot found library ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_import_0 db 'Error on load import library ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_found_lib_1 db 'Sorry I cannot found library ',39,'libimg.obj',39,'" -tE',0
|
||||
err_message_import_1 db 'Error on load import library ',39,'libimg.obj',39,'" -tE',0
|
||||
err_msg_found_lib_2 db 'Sorry I cannot found library ',39,'buf2d.obj',39,'" -tE',0
|
||||
err_msg_import_2 db 'Error on load import library ',39,'buf2d',39,'" -tE',0
|
||||
err_msg_found_lib_3 db 'Sorry I cannot found library ',39,'libini.obj',39,'" -tE',0
|
||||
err_msg_import_3 db 'Error on load import library ',39,'libini',39,'" -tE',0
|
||||
end if
|
||||
|
||||
l_libs_start:
|
||||
lib0 l_libs lib_name_0, sys_path, file_name, system_dir_0,\
|
||||
err_message_found_lib_0, head_f_l, proclib_import,err_message_import_0, head_f_i
|
||||
lib1 l_libs lib_name_1, sys_path, file_name, system_dir_1,\
|
||||
err_message_found_lib_1, head_f_l, import_libimg, err_message_import_1, head_f_i
|
||||
lib_2 l_libs lib_name_2, sys_path, library_path, system_dir_2,\
|
||||
err_msg_found_lib_2,head_f_l,import_buf2d,err_msg_import_2,head_f_i
|
||||
lib_3 l_libs lib_name_3, sys_path, library_path, system_dir_3,\
|
||||
err_msg_found_lib_3,head_f_l,import_libini,err_msg_import_3,head_f_i
|
||||
lib0 l_libs lib_name_0, file_name, system_dir_0, import_proclib
|
||||
lib1 l_libs lib_name_1, file_name, system_dir_1, import_libimg
|
||||
lib2 l_libs lib_name_2, file_name, system_dir_2, import_buf2d
|
||||
lib3 l_libs lib_name_3, file_name, system_dir_3, import_libini
|
||||
l_libs_end:
|
||||
|
||||
align 4
|
||||
@@ -1416,7 +1387,7 @@ import_libimg:
|
||||
aimg_draw db 'img_draw',0
|
||||
|
||||
align 4
|
||||
proclib_import: ;<3B><><EFBFBD>ᠭ<EFBFBD><E1A0AD> <20><>ᯮ<EFBFBD><E1AFAE><EFBFBD><EFBFBD>㥬<EFBFBD><E3A5AC> <20>㭪権
|
||||
import_proclib:
|
||||
OpenDialog_Init dd aOpenDialog_Init
|
||||
OpenDialog_Start dd aOpenDialog_Start
|
||||
dd 0,0
|
||||
@@ -1510,12 +1481,6 @@ dd 0,0
|
||||
aini_get_int db 'ini_get_int',0
|
||||
aini_get_color db 'ini_get_color',0
|
||||
|
||||
mouse_dd dd 0
|
||||
sc system_colors
|
||||
|
||||
align 16
|
||||
procinfo process_information
|
||||
|
||||
;<3B><><EFBFBD><EFBFBD><EFBFBD> <20>᭮<EFBFBD><E1ADAE><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>ࠦ<EFBFBD><E0A0A6><EFBFBD><EFBFBD>
|
||||
align 4
|
||||
buf_0: dd 0 ;㪠<><E3AAA0>⥫<EFBFBD> <20><> <20>a<EFBFBD><61><EFBFBD> <20><><EFBFBD><EFBFBD>ࠦ<EFBFBD><E0A0A6><EFBFBD><EFBFBD>
|
||||
@@ -1576,14 +1541,16 @@ buf_vox:
|
||||
|
||||
align 16
|
||||
i_end:
|
||||
procinfo process_information
|
||||
sc system_colors
|
||||
run_file_70 FileInfoBlock
|
||||
mouse_dd dd ?
|
||||
wnd_s_pos: ;<3B><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>⮢<EFBFBD><E2AEA2> <20><><EFBFBD><EFBFBD>樨 <20><><EFBFBD><EFBFBD>
|
||||
rq 0
|
||||
rb 4096 ;2048
|
||||
stacktop:
|
||||
sys_path rb 1024
|
||||
file_name:
|
||||
rb 1024 ;4096
|
||||
library_path rb 1024
|
||||
file_name rb 2048 ;4096
|
||||
plugin_path rb 1024 ;4096
|
||||
openfile_path rb 1024 ;4096
|
||||
filename_area rb 256
|
||||
|
@@ -7,13 +7,14 @@ include '../../../macros.inc'
|
||||
include '../../../proc32.inc'
|
||||
include '../../../KOSfuncs.inc'
|
||||
include '../../../load_img.inc'
|
||||
include '../../../load_lib.mac'
|
||||
include '../../../develop/libraries/TinyGL/asm_fork/opengl_const.inc'
|
||||
include '../../../develop/libraries/TinyGL/asm_fork/zbuffer.inc'
|
||||
include 'vox_3d.inc'
|
||||
include '../trunk/str.inc'
|
||||
include 'lang.inc'
|
||||
|
||||
@use_library_mem mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
|
||||
@use_library mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
|
||||
if lang eq ru
|
||||
caption db '<27><><EFBFBD>ᬮ<EFBFBD><E1ACAE> <20><><EFBFBD>ᥫ<EFBFBD><E1A5AB> 11.11.20',0 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
else
|
||||
@@ -27,7 +28,6 @@ end if
|
||||
|
||||
IMAGE_TOOLBAR_ICON_SIZE equ 16*16*3
|
||||
IMAGE_TOOLBAR_SIZE equ IMAGE_TOOLBAR_ICON_SIZE*10
|
||||
image_data_toolbar dd 0
|
||||
|
||||
align 4
|
||||
start:
|
||||
@@ -850,7 +850,6 @@ db 'TXT',0
|
||||
db 0
|
||||
|
||||
|
||||
|
||||
system_dir_0 db '/sys/lib/'
|
||||
lib_name_0 db 'proc_lib.obj',0
|
||||
system_dir_1 db '/sys/lib/'
|
||||
@@ -860,39 +859,11 @@ lib_name_2 db 'buf2d.obj',0
|
||||
system_dir_3 db '/sys/lib/'
|
||||
lib_name_3 db 'tinygl.obj',0
|
||||
|
||||
align 4
|
||||
head_f_i:
|
||||
if lang eq ru
|
||||
head_f_l db '"<22><><EFBFBD>⥬<EFBFBD><E2A5AC><EFBFBD> <20>訡<EFBFBD><E8A8A1>',0
|
||||
err_message_found_lib_0 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_import_0 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_found_lib_1 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libimg.obj',39,'" -tE',0
|
||||
err_message_import_1 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libimg.obj',39,'" -tE',0
|
||||
err_msg_found_lib_2 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'buf2d.obj',39,'" -tE',0
|
||||
err_msg_import_2 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'buf2d',39,'" -tE',0
|
||||
err_msg_found_lib_3 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'tinygl.obj',39,'" -tE',0
|
||||
err_msg_import_3 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'tinygl',39,'" -tE',0
|
||||
else
|
||||
head_f_l db '"System error',0
|
||||
err_message_found_lib_0 db 'Sorry I cannot found library ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_import_0 db 'Error on load import library ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_found_lib_1 db 'Sorry I cannot found library ',39,'libimg.obj',39,'" -tE',0
|
||||
err_message_import_1 db 'Error on load import library ',39,'libimg.obj',39,'" -tE',0
|
||||
err_msg_found_lib_2 db 'Sorry I cannot found library ',39,'buf2d.obj',39,'" -tE',0
|
||||
err_msg_import_2 db 'Error on load import library ',39,'buf2d',39,'" -tE',0
|
||||
err_msg_found_lib_3 db 'Sorry I cannot found library ',39,'tinygl.obj',39,'" -tE',0
|
||||
err_msg_import_3 db 'Error on load import library ',39,'tinygl',39,'" -tE',0
|
||||
end if
|
||||
|
||||
l_libs_start:
|
||||
lib_0 l_libs lib_name_0, sys_path, file_name, system_dir_0,\
|
||||
err_message_found_lib_0, head_f_l, proclib_import,err_message_import_0, head_f_i
|
||||
lib_1 l_libs lib_name_1, sys_path, file_name, system_dir_1,\
|
||||
err_message_found_lib_1, head_f_l, import_libimg, err_message_import_1, head_f_i
|
||||
lib_2 l_libs lib_name_2, sys_path, library_path, system_dir_2,\
|
||||
err_msg_found_lib_2,head_f_l,import_buf2d,err_msg_import_2,head_f_i
|
||||
lib_3 l_libs lib_name_3, sys_path, library_path, system_dir_3,\
|
||||
err_msg_found_lib_3,head_f_l,import_lib_tinygl,err_msg_import_3,head_f_i
|
||||
lib_0 l_libs lib_name_0, file_name, system_dir_0, import_proclib
|
||||
lib_1 l_libs lib_name_1, file_name, system_dir_1, import_libimg
|
||||
lib_2 l_libs lib_name_2, file_name, system_dir_2, import_buf2d
|
||||
lib_3 l_libs lib_name_3, file_name, system_dir_3, import_tinygl
|
||||
l_libs_end:
|
||||
|
||||
align 4
|
||||
@@ -945,7 +916,7 @@ import_libimg:
|
||||
; aimg_convert db 'img_convert',0
|
||||
|
||||
align 4
|
||||
proclib_import: ;<3B><><EFBFBD>ᠭ<EFBFBD><E1A0AD> <20><>ᯮ<EFBFBD><E1AFAE><EFBFBD><EFBFBD>㥬<EFBFBD><E3A5AC> <20>㭪権
|
||||
import_proclib:
|
||||
OpenDialog_Init dd aOpenDialog_Init
|
||||
OpenDialog_Start dd aOpenDialog_Start
|
||||
dd 0,0
|
||||
@@ -1006,7 +977,7 @@ import_buf2d:
|
||||
|
||||
;--------------------------------------------------
|
||||
align 4
|
||||
import_lib_tinygl:
|
||||
import_tinygl:
|
||||
|
||||
macro E_LIB n
|
||||
{
|
||||
@@ -1065,14 +1036,14 @@ lmodel_ambient dd 0.3, 0.3, 0.3, 1.0 ;
|
||||
align 16
|
||||
i_end:
|
||||
ctx1 rb 28 ;sizeof.TinyGLContext = 28
|
||||
mouse_drag dd 0 ;०<><E0A5A6> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>業<EFBFBD> <20><> <20><>६<EFBFBD>饭<EFBFBD><E9A5AD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
mouse_x dd 0
|
||||
mouse_y dd 0
|
||||
image_data_toolbar dd ?
|
||||
mouse_drag dd ? ;०<><E0A5A6> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>業<EFBFBD> <20><> <20><>६<EFBFBD>饭<EFBFBD><E9A5AD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
mouse_x dd ?
|
||||
mouse_y dd ?
|
||||
rb 4096
|
||||
stacktop:
|
||||
sys_path rb 1024
|
||||
file_name rb 2048
|
||||
library_path rb 1024
|
||||
plugin_path rb 4096
|
||||
openfile_path rb 4096
|
||||
filename_area rb 256
|
||||
|
@@ -876,11 +876,31 @@ import libini, \
|
||||
ini.get_str, 'ini_get_str', \
|
||||
ini.get_int, 'ini_get_int'
|
||||
|
||||
param_user: db 'anonymous',0
|
||||
rb 60
|
||||
|
||||
param_server_addr db 'kolibrios.org'
|
||||
rb 1024
|
||||
|
||||
align 4
|
||||
i_end:
|
||||
|
||||
; uninitialised data
|
||||
|
||||
run_file_70 FileInfoBlock ; required for libimg
|
||||
|
||||
new_dir_buf rb 64
|
||||
folder_data rb 32+32*304
|
||||
|
||||
remote_list_buf rb 1024
|
||||
file_name rb 4096 ; required for libimg
|
||||
conv_tabl rb 128
|
||||
ed_buffer rb 100
|
||||
tedit_buffer rb 1024
|
||||
el_focus dd ?
|
||||
;-----------------------
|
||||
|
||||
procinfo process_information
|
||||
|
||||
interface_addr rd 1
|
||||
|
||||
status db ?
|
||||
@@ -915,10 +935,10 @@ filestruct:
|
||||
filestruct2:
|
||||
.subfn dd ?
|
||||
.offset dd ?
|
||||
dd 0
|
||||
dd ?
|
||||
.size dd ?
|
||||
.ptr dd ?
|
||||
db 0
|
||||
db ?
|
||||
.name dd ?
|
||||
|
||||
folder_buf rb 40
|
||||
@@ -934,14 +954,8 @@ path rb 1024
|
||||
|
||||
initial_login rb 1
|
||||
|
||||
param_user: db 'anonymous',0
|
||||
rb 60
|
||||
|
||||
param_password rb 1024
|
||||
|
||||
param_server_addr db 'kolibrios.org'
|
||||
rb 1024
|
||||
|
||||
param_path rb 1024
|
||||
param_port rb 6
|
||||
|
||||
|
@@ -1,9 +1,9 @@
|
||||
include '../../load_img.inc'
|
||||
include '../../develop/libraries/libs-dev/libimg/libimg.inc'
|
||||
include '../../develop/libraries/box_lib/trunk/box_lib.mac'
|
||||
include '../../develop/libraries/box_lib/load_lib.mac'
|
||||
include '../../load_lib.mac'
|
||||
|
||||
@use_library_mem mem.Alloc, mem.Free, mem.ReAlloc, dll.Load
|
||||
@use_library
|
||||
|
||||
icon_tl_sys dd 0
|
||||
icon_tl_nod dd 0
|
||||
@@ -1182,24 +1182,11 @@ import libimg, \
|
||||
img_draw , 'img_draw'
|
||||
|
||||
|
||||
run_file_70 FileInfoBlock ; required for libimg
|
||||
|
||||
auto_list db 1 ; to run LIST immediately after CWD
|
||||
filter rb 512
|
||||
root_dir db '/tmp0/1'
|
||||
rb 505
|
||||
new_dir_buf rb 64
|
||||
folder_data rb 32+32*304
|
||||
node_entry db '1111'
|
||||
rb 512
|
||||
node_entry2 db '1111'
|
||||
rb 512
|
||||
remote_list_buf rb 1024
|
||||
file_name rb 4096 ; required for libimg
|
||||
conv_tabl rb 128
|
||||
ed_buffer rb 100
|
||||
tedit_buffer rb 1024
|
||||
el_focus dd 0
|
||||
;-----------------------
|
||||
|
||||
procinfo process_information
|
@@ -1,5 +1,5 @@
|
||||
;CNC CONTROL
|
||||
;Igor Afanasyev (aka IgorA) and Sergey Efremenkov (aka theonlymirage), 2018
|
||||
;Igor Afanasyev (aka IgorA) and Sergey Efremenkov (aka theonlymirage), 2020
|
||||
|
||||
;02.10.18 - Only prototype UI
|
||||
;08.10.18 - Add ComboBox (Button + KMenu), small text
|
||||
@@ -14,6 +14,7 @@ include '../../macros.inc'
|
||||
include '../../proc32.inc'
|
||||
include '../../KOSfuncs.inc'
|
||||
include '../../load_img.inc'
|
||||
include '../../load_lib.mac'
|
||||
include '../../develop/libraries/libs-dev/libimg/libimg.inc'
|
||||
include '../../develop/libraries/box_lib/trunk/box_lib.mac'
|
||||
include 'lang.inc'
|
||||
@@ -24,8 +25,8 @@ KMENUITEM_NORMAL equ 0
|
||||
KMENUITEM_SUBMENU equ 1
|
||||
KMENUITEM_SEPARATOR equ 2
|
||||
|
||||
@use_library_mem mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
|
||||
caption db 'CNC Control 22.05.19',0 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
@use_library mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
|
||||
caption db 'CNC Control 18.12.20',0 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
|
||||
run_file_70 FileInfoBlock
|
||||
|
||||
@@ -384,22 +385,17 @@ pushad
|
||||
|
||||
;delete port button, if it exist
|
||||
mov edx, 0x80000008
|
||||
mcall 8
|
||||
mcall SF_DEFINE_BUTTON
|
||||
;draw button PORT
|
||||
buttonPortX = 433
|
||||
buttonPortY = 27 ;50
|
||||
buttonPortTextXoffset = 5
|
||||
mov ebx, buttonPortX*65536 + 95 ;X + Width
|
||||
mov ecx, buttonPortY*65536 + 20 ;Y + Height
|
||||
mov edx, 0x00000008 ;button id
|
||||
mov esi, 0x00AABBCC ;color button
|
||||
mcall 8
|
||||
mcall SF_DEFINE_BUTTON, buttonPortX*65536 + 95, buttonPortY*65536 + 20, 8
|
||||
;draw text for button PORT
|
||||
mov ebx, (buttonPortX+buttonPortTextXoffset) * 65536 + (buttonPortY+6) ;(x, y)
|
||||
mov ecx, 0xFFFFFF
|
||||
mov edx, sz_PortMenu
|
||||
mov esi, 11
|
||||
mcall 4
|
||||
mcall SF_DRAW_TEXT,, 0xFFFFFF, sz_PortMenu
|
||||
;stdcall [kmainmenu_draw], [main_menu]
|
||||
;mov word[coord.x], 0
|
||||
;mov word[coord.y], 0
|
||||
@@ -448,7 +444,7 @@ button:
|
||||
cmp ah, 8
|
||||
jne @f
|
||||
push eax ebx ecx
|
||||
mcall 9, pi, -1 ;get window coord
|
||||
mcall SF_THREAD_INFO, pi, -1 ;get window coord
|
||||
|
||||
mov eax, dword[pi+34]
|
||||
add eax, buttonPortX + 5
|
||||
@@ -676,8 +672,8 @@ proc conv_str_to_int uses ebx ecx esi, buf:dword
|
||||
inc esi
|
||||
jmp .cycle_16
|
||||
@@:
|
||||
cmp ecx,0 ;<3B> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥫쭮<E2A5AB>
|
||||
jne @f
|
||||
or ecx,ecx ;<3B> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥫쭮<E2A5AB>
|
||||
jnz @f
|
||||
sub ecx,eax
|
||||
mov eax,ecx
|
||||
@@:
|
||||
@@ -752,45 +748,13 @@ lib_name_3 db 'box_lib.obj',0
|
||||
system_dir_4 db '/sys/lib/'
|
||||
lib_name_4 db 'kmenu.obj',0
|
||||
|
||||
head_f_i:
|
||||
if lang eq ru
|
||||
head_f_l db '"<22><><EFBFBD>⥬<EFBFBD><E2A5AC><EFBFBD> <20>訡<EFBFBD><E8A8A1>',0
|
||||
err_message_found_lib_0 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_import_0 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'proc_lib.obj',39,'" -tW',0
|
||||
err_message_found_lib_1 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libimg.obj',39,'" -tE',0
|
||||
err_message_import_1 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'libimg.obj',39,'" -tW',0
|
||||
err_msg_found_lib_2 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'buf2d.obj',39,'" -tE',0
|
||||
err_msg_import_2 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'buf2d',39,'" -tW',0
|
||||
err_msg_found_lib_3 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'box_lib.obj',39,'" -tE',0
|
||||
err_msg_import_3 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'box_lib',39,'" -tW',0
|
||||
err_msg_found_lib_4 db '<27><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'kmenu.obj',39,'" -tE',0
|
||||
err_msg_import_4 db '<27>訡<EFBFBD><E8A8A1> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥪<EFBFBD> ',39,'kmenu',39,'" -tW',0
|
||||
else
|
||||
head_f_l db '"System error',0
|
||||
err_message_found_lib_0 db 'Sorry I cannot found library ',39,'proc_lib.obj',39,'" -tE',0
|
||||
err_message_import_0 db 'Error on load import library ',39,'proc_lib.obj',39,'" -tW',0
|
||||
err_message_found_lib_1 db 'Sorry I cannot found library ',39,'libimg.obj',39,'" -tE',0
|
||||
err_message_import_1 db 'Error on load import library ',39,'libimg.obj',39,'" -tW',0
|
||||
err_msg_found_lib_2 db 'Sorry I cannot found library ',39,'buf2d.obj',39,'" -tE',0
|
||||
err_msg_import_2 db 'Error on load import library ',39,'buf2d',39,'" -tW',0
|
||||
err_msg_found_lib_3 db 'Sorry I cannot found library ',39,'box_lib.obj',39,'" -tE',0
|
||||
err_msg_import_3 db 'Error on load import library ',39,'box_lib',39,'" -tW',0
|
||||
err_msg_found_lib_4 db 'Sorry I cannot found library ',39,'kmenu.obj',39,'" -tE',0
|
||||
err_msg_import_4 db 'Error on load import library ',39,'kmenu',39,'" -tW',0
|
||||
end if
|
||||
|
||||
align 4
|
||||
l_libs_start:
|
||||
lib_0 l_libs lib_name_0, sys_path, file_name, system_dir_0,\
|
||||
err_message_found_lib_0, head_f_l, proclib_import,err_message_import_0, head_f_i
|
||||
lib_1 l_libs lib_name_1, sys_path, file_name, system_dir_1,\
|
||||
err_message_found_lib_1, head_f_l, import_libimg, err_message_import_1, head_f_i
|
||||
lib_2 l_libs lib_name_2, sys_path, library_path, system_dir_2,\
|
||||
err_msg_found_lib_2,head_f_l,import_buf2d,err_msg_import_2,head_f_i
|
||||
lib_3 l_libs lib_name_3, sys_path, file_name, system_dir_3,\
|
||||
err_msg_found_lib_3, head_f_l, import_box_lib,err_msg_import_3,head_f_i
|
||||
lib_4 l_libs lib_name_4, sys_path, file_name, system_dir_4,\
|
||||
err_msg_found_lib_4, head_f_l, import_libkmenu,err_msg_import_4,head_f_i
|
||||
lib_0 l_libs lib_name_0, file_name, system_dir_0, import_proclib
|
||||
lib_1 l_libs lib_name_1, file_name, system_dir_1, import_libimg
|
||||
lib_2 l_libs lib_name_2, file_name, system_dir_2, import_buf2d
|
||||
lib_3 l_libs lib_name_3, file_name, system_dir_3, import_box_lib
|
||||
lib_4 l_libs lib_name_4, file_name, system_dir_4, import_libkmenu
|
||||
l_libs_end:
|
||||
|
||||
align 4
|
||||
@@ -841,7 +805,7 @@ import_libimg:
|
||||
aimg_draw db 'img_draw',0
|
||||
|
||||
align 4
|
||||
proclib_import: ;<3B><><EFBFBD>ᠭ<EFBFBD><E1A0AD> <20><>ᯮ<EFBFBD><E1AFAE><EFBFBD><EFBFBD>㥬<EFBFBD><E3A5AC> <20>㭪権
|
||||
import_proclib:
|
||||
OpenDialog_Init dd aOpenDialog_Init
|
||||
OpenDialog_Start dd aOpenDialog_Start
|
||||
OpenDialog_Set_file_name dd aOpenDialog_Set_file_name
|
||||
@@ -1048,9 +1012,9 @@ align 4
|
||||
align 4
|
||||
proc mem_copy uses ecx esi edi, destination:dword, source:dword, len:dword
|
||||
cld
|
||||
mov esi, dword[source]
|
||||
mov edi, dword[destination]
|
||||
mov ecx, dword[len]
|
||||
mov esi, [source]
|
||||
mov edi, [destination]
|
||||
mov ecx, [len]
|
||||
rep movsb
|
||||
ret
|
||||
endp
|
||||
@@ -1102,12 +1066,10 @@ thread_n_file:
|
||||
rb 2048
|
||||
stacktop:
|
||||
sys_path rb 1024
|
||||
file_name:
|
||||
rb 1024
|
||||
library_path rb 1024
|
||||
file_name rb 2048
|
||||
plugin_path rb 4096
|
||||
openfile_path rb 4096
|
||||
filename_area rb 256
|
||||
pi rb 1024
|
||||
pi rb 1024
|
||||
mem:
|
||||
|
||||
|
@@ -11,13 +11,14 @@ include '../../macros.inc'
|
||||
include '../../proc32.inc'
|
||||
include '../../KOSfuncs.inc'
|
||||
include '../../load_img.inc'
|
||||
include '../../load_lib.mac'
|
||||
include '../../develop/libraries/box_lib/trunk/box_lib.mac'
|
||||
include '../../system/skincfg/trunk/kglobals.inc'
|
||||
include '../../system/skincfg/trunk/unpacker.inc'
|
||||
include 'te_data.inc'
|
||||
include 'te_work.inc' ;text work functions
|
||||
|
||||
@use_library_mem mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
|
||||
@use_library mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
|
||||
|
||||
icon_tl_sys dd 0 ;㪠<><E3AAA0>⥫<EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20>࠭<EFBFBD><E0A0AD><EFBFBD><EFBFBD> <20><><EFBFBD>⥬<EFBFBD><E2A5AC><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
@@ -324,8 +325,8 @@ align 4
|
||||
but_ctrl_o:
|
||||
push eax
|
||||
call get_wnd_in_focus
|
||||
cmp eax,0
|
||||
je @f
|
||||
or eax,eax
|
||||
jz @f
|
||||
stdcall [ted_open_file], eax,str_file_70,[edit1.text]
|
||||
@@:
|
||||
pop eax
|
||||
@@ -336,8 +337,8 @@ align 4
|
||||
but_ctrl_n:
|
||||
push eax
|
||||
call get_wnd_in_focus
|
||||
cmp eax,0
|
||||
je @f
|
||||
or eax,eax
|
||||
jz @f
|
||||
stdcall [ted_clear], eax,1
|
||||
stdcall [ted_draw], eax
|
||||
@@:
|
||||
@@ -358,7 +359,7 @@ get_wnd_in_focus:
|
||||
;@@:
|
||||
ret
|
||||
|
||||
hed db 'TextEditor syntax file converter 06.02.20',0 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
hed db 'TextEditor syntax file converter 18.12.20',0 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
|
||||
conv_tabl rb 128 ; ⠡<><E2A0A1><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E0AEA2><EFBFBD><EFBFBD> scan-<2D><><EFBFBD><EFBFBD> <20> ascii-<2D><><EFBFBD>
|
||||
|
||||
txt_load_f db '<27><><EFBFBD><EFBFBD>. 䠩<>',0
|
||||
@@ -366,17 +367,10 @@ txt_save_f db '
|
||||
txt_inp_file db '<27><><EFBFBD>. 䠩<>:',0
|
||||
txt_out_file db '<27><><EFBFBD>. 䠩<>:',0
|
||||
|
||||
head_f_i:
|
||||
head_f_l db '"System error',0
|
||||
err_message_found_lib_0 db 'Sorry I cannot found library ',39,'box_lib.obj',39,'" -tE',0
|
||||
err_message_import_0 db 'Error on load import library ',39,'box_lib.obj',39,'" -tW',0
|
||||
err_message_found_lib_1 db 'Sorry I cannot found library ',39,'libimg.obj',39,'" -tE',0
|
||||
err_message_import_1 db 'Error on load import library ',39,'libimg.obj',39,'" -tW',0
|
||||
|
||||
;library structures
|
||||
l_libs_start:
|
||||
lib0 l_libs lib_name_0, sys_path, file_name, system_dir_0, err_message_found_lib_0, head_f_l, import_box_lib,err_message_import_0, head_f_i
|
||||
lib1 l_libs lib_name_1, sys_path, file_name, system_dir_1, err_message_found_lib_1, head_f_l, import_libimg,err_message_import_1, head_f_i
|
||||
lib0 l_libs lib_name_0, file_name, system_dir_0, import_box_lib
|
||||
lib1 l_libs lib_name_1, file_name, system_dir_1, import_libimg
|
||||
load_lib_end:
|
||||
|
||||
IncludeIGlobals
|
||||
@@ -385,14 +379,11 @@ align 16
|
||||
i_end:
|
||||
IncludeUGlobals
|
||||
procinfo process_information
|
||||
rb 1024
|
||||
thread:
|
||||
rb 1024
|
||||
rb 1024
|
||||
thread:
|
||||
rb 1024
|
||||
stacktop:
|
||||
sys_path:
|
||||
rb 4096
|
||||
file_name:
|
||||
rb 4096
|
||||
file_name_rez:
|
||||
rb 4096
|
||||
sys_path rb 4096
|
||||
file_name rb 4096
|
||||
file_name_rez rb 4096
|
||||
mem:
|
||||
|
Reference in New Issue
Block a user