fix test_array1, add some example programs in iso

git-svn-id: svn://kolibrios.org@6287 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
IgorA 2016-02-23 17:51:54 +00:00
parent ce8c06cf27
commit 04aea36120
3 changed files with 21 additions and 17 deletions

View File

@ -152,6 +152,13 @@ extra_files = {
{"kolibrios/3D/voxel_utilites/TOOLBAR.PNG" , PROGS .. "/media/voxel_editor/utilites/toolbar.png"}, {"kolibrios/3D/voxel_utilites/TOOLBAR.PNG" , PROGS .. "/media/voxel_editor/utilites/toolbar.png"},
{"kolibrios/3D/voxel_utilites/TOOLBAR_M.PNG" , PROGS .. "/media/voxel_editor/utilites/toolbar_m.png"}, {"kolibrios/3D/voxel_utilites/TOOLBAR_M.PNG" , PROGS .. "/media/voxel_editor/utilites/toolbar_m.png"},
{"kolibrios/3D/voxel_utilites/TOOLBAR_T.PNG" , PROGS .. "/media/voxel_editor/utilites/toolbar_t.png"}, {"kolibrios/3D/voxel_utilites/TOOLBAR_T.PNG" , PROGS .. "/media/voxel_editor/utilites/toolbar_t.png"},
{"kolibrios/3D/FONT8X9.BMP", PROGS .. "/fs/kfar/trunk/font8x9.bmp"},
{"kolibrios/3D/TOOLB_1.PNG", PROGS .. "/develop/libraries/TinyGL/asm_fork/examples/toolb_1.png"},
{"kolibrios/3D/GEARS", PROGS .. "/develop/libraries/TinyGL/asm_fork/examples/gears"},
{"kolibrios/3D/TEST_GLU1", PROGS .. "/develop/libraries/TinyGL/asm_fork/examples/test_glu1"},
{"kolibrios/3D/TEST_GLU2", PROGS .. "/develop/libraries/TinyGL/asm_fork/examples/test_glu2"},
{"kolibrios/3D/TEXT_2.PNG", PROGS .. "/develop/libraries/TinyGL/asm_fork/examples/text_2.png"},
{"kolibrios/3D/TEXTURES1", PROGS .. "/develop/libraries/TinyGL/asm_fork/examples/textures1"},
{"kolibrios/emul/dosbox/", "common/emul/DosBox/*"}, {"kolibrios/emul/dosbox/", "common/emul/DosBox/*"},
{"kolibrios/emul/e80/readme.txt", PROGS .. "/emulator/e80/trunk/readme.txt"}, {"kolibrios/emul/e80/readme.txt", PROGS .. "/emulator/e80/trunk/readme.txt"},
{"kolibrios/emul/fceu/fceu", PROGS .. "/emulator/fceu/fceu"}, {"kolibrios/emul/fceu/fceu", PROGS .. "/emulator/fceu/fceu"},

View File

@ -1,14 +1,11 @@
use32 use32
org 0x0 org 0x0
db 'MENUET01' db 'MENUET01'
dd 0x1 dd 1,start,i_end,mem,stacktop,0,cur_dir_path
dd start
dd i_end
dd mem,stacktop
dd 0,cur_dir_path
include '../../../../../proc32.inc' include '../../../../../proc32.inc'
include '../../../../../macros.inc' include '../../../../../macros.inc'
include '../../../../../KOSfuncs.inc'
include '../../../../../develop/libraries/box_lib/load_lib.mac' include '../../../../../develop/libraries/box_lib/load_lib.mac'
include '../../../../../dll.inc' include '../../../../../dll.inc'
include '../opengl_const.inc' include '../opengl_const.inc'
@ -19,10 +16,10 @@ align 4
start: start:
load_library name_tgl, cur_dir_path, library_path, system_path, \ load_library name_tgl, cur_dir_path, library_path, system_path, \
err_message_found_lib, head_f_l, import_lib_tinygl, err_message_import, head_f_i err_message_found_lib, head_f_l, import_lib_tinygl, err_message_import, head_f_i
cmp eax,-1 cmp eax,SF_TERMINATE_PROCESS
jz button.exit jz button.exit
mcall 40,0x27 mcall SF_SET_EVENTS_MASK,0x27
;заполняем массив индексов из файла house.3ds (который вшит внутрь данной программы) ;заполняем массив индексов из файла house.3ds (который вшит внутрь данной программы)
mov esi,house_3ds mov esi,house_3ds
@ -51,7 +48,7 @@ red_win:
align 4 align 4
still: still:
mcall 10 mcall SF_WAIT_EVENT
cmp al,1 cmp al,1
jz red_win jz red_win
cmp al,2 cmp al,2
@ -63,19 +60,19 @@ still:
align 4 align 4
draw_window: draw_window:
pushad pushad
mcall 12,1 mcall SF_REDRAW,SSF_BEGIN_DRAW
mov edx,0x33ffffff mov edx,0x33ffffff
mcall 0,(50 shl 16)+430,(30 shl 16)+400,,,caption mcall SF_CREATE_WINDOW,(50 shl 16)+430,(30 shl 16)+400,,,caption
stdcall [kosglSwapBuffers] stdcall [kosglSwapBuffers]
mcall 12,2 mcall SF_REDRAW,SSF_END_DRAW
popad popad
ret ret
align 4 align 4
key: key:
mcall 2 mcall SF_GET_KEY
cmp ah,27 ;Esc cmp ah,27 ;Esc
je button.exit je button.exit
@ -133,11 +130,11 @@ key:
align 4 align 4
button: button:
mcall 17 mcall SF_GET_BUTTON
cmp ah,1 cmp ah,1
jne still jne still
.exit: .exit:
mcall -1 mcall SF_TERMINATE_PROCESS
align 4 align 4
@ -179,7 +176,7 @@ delt_size dd 3.0
align 4 align 4
house_3ds: ;внедряем файл внутрь программы (в идеальном случае должен открыватся через окно диалога, но для облегчения примера вшит внутрь) house_3ds: ;внедряем файл внутрь программы (в идеальном случае должен открыватся через окно диалога, но для облегчения примера вшит внутрь)
file '../../../../../demos/3DS/3ds_objects/house.3ds' file '../../../../../demos/3DS/3ds_objects/House.3ds'
align 4 align 4
Indices rb 0x1a6*6 ;0x1a6 - число граней, на каждую грань по 3 точки, индекс точки 2 байта Indices rb 0x1a6*6 ;0x1a6 - число граней, на каждую грань по 3 точки, индекс точки 2 байта
@ -202,10 +199,10 @@ include '../export.inc'
;-------------------------------------------------- ;--------------------------------------------------
system_path db '/sys/lib/' system_path db '/sys/lib/'
name_tgl db 'tinygl.obj',0 name_tgl db 'tinygl.obj',0
err_message_found_lib db 'Sorry I cannot load library tinygl.obj',0 err_message_found_lib db 'Sorry I cannot load library ',39,'tinygl.obj',39,0
head_f_i: head_f_i:
head_f_l db 'System error',0 head_f_l db 'System error',0
err_message_import db 'Error on load import library tinygl.obj',0 err_message_import db 'Error on load import library ',39,'tinygl.obj',39,0
;-------------------------------------------------- ;--------------------------------------------------
i_end: i_end:

Binary file not shown.

Before

Width:  |  Height:  |  Size: 69 KiB

After

Width:  |  Height:  |  Size: 235 KiB