fix exif.obj, update example

git-svn-id: svn://kolibrios.org@6313 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
IgorA
2016-03-09 23:24:53 +00:00
parent b0dc7f9b6b
commit 24104fc1e6
3 changed files with 161 additions and 120 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

After

Width:  |  Height:  |  Size: 2.2 KiB

View File

@@ -1,86 +1,25 @@
use32
org 0x0
db 'MENUET01' ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>. <20><EFBFBD><E1AFAE><EFBFBD><EFA5AC><EFBFBD><><E4A0A9> <20><EFBFBD><E1A5A3> 8 <20><><EFBFBD><EFBFBD>
dd 0x1
dd start
dd i_end ;ࠧ<><E0A0A7><EFBFBD> <20><EFBFBD><E0A8AB><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
dd mem
dd stacktop
dd 0
dd sys_path
dd 1, start, i_end, mem, stacktop, 0, sys_path
include '../../../../macros.inc'
include '../../../../proc32.inc'
include '../../../../develop/libraries/box_lib/load_lib.mac'
include '../../../../KOSfuncs.inc'
include '../../../../load_img.inc'
include '../../../../develop/libraries/box_lib/trunk/box_lib.mac'
include '../../../../dll.inc'
@use_library_mem mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
caption db '<27><><EFBFBD><EFBFBD><E1ACAE> <20><><EFBFBD><EFBFBD>樨 Exif 23.07.14',0 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
struct FileInfoBlock
Function dd ?
Position dd ?
Flags dd ?
Count dd ?
Buffer dd ?
db ?
FileName dd ?
ends
caption db '<27><><EFBFBD><EFBFBD><E1ACAE> <20><><EFBFBD><EFBFBD>樨 Exif 10.03.16',0 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
run_file_70 FileInfoBlock
image_data dd 0 ;㪠<><E3AAA0><EFBFBD> <20><> <20><EFBFBD><E0A5AC><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>. <20><><EFBFBD> <20><EFBFBD> <20><EFBFBD><EFBFBD><E0A0A7><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD>
fn_toolbar db 'toolbar.png',0
IMAGE_TOOLBAR_ICON_SIZE equ 16*16*3
IMAGE_TOOLBAR_SIZE equ IMAGE_TOOLBAR_ICON_SIZE*6
image_data_toolbar dd 0
IMAGE_FILE1_SIZE equ 128*144*3+54 ;ࠧ<><E0A0A7><EFBFBD><><E4A0A9> <20> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD><EFBFBD>
memory_file_size dd 512*1024 ;ࠧ<><E0A0A7><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><><E4A0A9><EFBFBD> (<28> <20><><EFBFBD> 512 Kb, <20><> <20><><EFBFBD><EFBFBD><EFBFBD><><E3A2A5><EFBFBD><E7A8A2><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><E5AEA4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>)
macro load_image_file path,buf,size { ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD>
;path - <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><E0A5AC><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><E0AEAA><EFBFBD><EFBFBD> <20><><EFBFBD><E0A0AC>
if path eqtype '' ;<3B><EFBFBD><E0AEA2><20><><EFBFBD><EFBFBD><EFBFBD> <20><> <20><><EFBFBD><E0AEAA> <20><><EFBFBD><E0A0AC><EFBFBD> path
jmp @f
local .path_str
.path_str db path ;<3B><><EFBFBD><20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><E0A5AC><EFBFBD><EFBFBD><EFBFBD>
db 0
@@:
;32 - <20><EFBFBD><E2A0AD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD><E2A5AC><EFBFBD> <20><>
copy_path .path_str,[32],file_name,0x0
else
copy_path path,[32],file_name,0x0 ;<3B><><EFBFBD><20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><E4A0A9> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD>, <20><><EFBFBD>ࠧ㬥<E0A0A7><E3ACA5><EFBFBD><EFBFBD> <20><><EFBFBD> <20><> <20> <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> <20> <20>ணࠬ<E0AEA3><E0A0AC><EFBFBD>
end if
stdcall mem.Alloc, dword size ;<3B><EFBFBD><20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD>
mov [buf],eax
mov eax,70 ;70-<2D> <20><EFBFBD><E3ADAA><EFBFBD><><E0A0A1><EFBFBD> <20><><E4A0A9><EFBFBD><EFBFBD>
mov [run_file_70.Function], 0
mov [run_file_70.Position], 0
mov [run_file_70.Flags], 0
mov [run_file_70.Count], dword size
m2m [run_file_70.Buffer], [buf]
mov byte[run_file_70+20], 0
mov [run_file_70.FileName], file_name
mov ebx,run_file_70
int 0x40 ;<3B><><EFBFBD><EFBFBD><EFBFBD><E3A6A0><> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD>
cmp ebx,0xffffffff
je @f
;<3B><><EFBFBD><E0A5A4><20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD> <20> <20><><EFBFBD><E0A5A2><EFBFBD><EFBFBD> <20><><EFBFBD> <20><> <20><EFBFBD><E0A5AC><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> image_data
stdcall dword[img_decode], dword[buf],ebx,0
mov dword[image_data],eax
;<3B><EFBFBD>ࠧ㥬 <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD> <20> <20><><EFBFBD><E0ACA0> rgb
stdcall dword[img_to_rgb2], dword[image_data],dword[buf]
;㤠<><20><EFBFBD><E0A5AC><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> image_data
stdcall dword[img_destroy], dword[image_data]
@@:
}
align 4
start:
load_libraries l_libs_start,l_libs_end
@@ -88,21 +27,22 @@ start:
mov ebp,lib_0
cmp dword [ebp+ll_struc_size-4],0
jz @f
mcall -1 ;exit not correct
mcall SF_TERMINATE_PROCESS
@@:
mcall 48,3,sc,sizeof.system_colors
mcall 40,0xC0000027
mcall SF_STYLE_SETTINGS,SSF_GET_COLORS,sc,sizeof.system_colors
mcall SF_SET_EVENTS_MASK,0xC0000027
stdcall [OpenDialog_Init],OpenDialog_data ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E2AEA2> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
stdcall [buf2d_create], buf_0 ;ᮧ<><E1AEA7><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
stdcall [buf2d_create], buf_thumb
load_image_file 'font8x9.bmp', image_data_toolbar,IMAGE_FILE1_SIZE
load_image_file 'font8x9.bmp', image_data_toolbar
stdcall [buf2d_create_f_img], buf_1,[image_data_toolbar] ;ᮧ<><E1AEA7><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>
stdcall mem.Free,[image_data_toolbar] ;<3B><EFBFBD><E1A2AE><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
stdcall [buf2d_conv_24_to_8], buf_1,1 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> <20><EFBFBD><E0AEA7><EFBFBD><E7ADAE><EFBFBD> 8 <20><><EFBFBD>
stdcall [buf2d_convert_text_matrix], buf_1
load_image_file fn_toolbar, image_data_toolbar,IMAGE_TOOLBAR_SIZE
load_image_file fn_toolbar, image_data_toolbar
stdcall mem.Alloc,[memory_file_size]
mov dword[open_file],eax
@@ -115,7 +55,7 @@ red_win:
align 4
still:
mcall 10
mcall SF_WAIT_EVENT
cmp al,1
jz red_win
@@ -132,24 +72,17 @@ still:
align 4
draw_window:
pushad
mcall 12,1
mcall SF_REDRAW,SSF_BEGIN_DRAW
; *** <20><><EFBFBD><E1AEA2><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> (<28><EFBFBD><EBAFAE><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 1 ࠧ <20><><EFBFBD> <20><><EFBFBD><EFBFBD>᪥) ***
xor eax,eax
mov ebx,(20 shl 16)+480
mov ecx,(20 shl 16)+540
mov edx,[sc.work]
or edx,(3 shl 24)+0x30000000
mov edi,caption
int 0x40
mcall SF_CREATE_WINDOW, (20 shl 16)+590, (20 shl 16)+540
; *** ᮧ<><E1AEA7><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ***
mov eax,8
mov ebx,(5 shl 16)+20
mov ecx,(5 shl 16)+20
mov edx,3
mov esi,[sc.work_button]
int 0x40
mcall SF_DEFINE_BUTTON, (5 shl 16)+20, (5 shl 16)+20, 3
mov ebx,(30 shl 16)+20
mov edx,4
@@ -171,13 +104,13 @@ pushad
mov edx,8
int 0x40
; *** <20><><EFBFBD><E1AEA2><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ***
mov eax,7
mov ebx,[image_data_toolbar]
mov ecx,(16 shl 16)+16
mov edx,(7 shl 16)+7 ;icon new
mov ebx,(160 shl 16)+20
mov edx,9
int 0x40
; *** <20><><EFBFBD><E1AEA2><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ***
mcall SF_PUT_IMAGE, [image_data_toolbar], (16 shl 16)+16, (7 shl 16)+7 ;icon new
add ebx,IMAGE_TOOLBAR_ICON_SIZE
add edx,(25 shl 16) ;icon open
int 0x40
@@ -186,25 +119,28 @@ pushad
int 0x40
add ebx,IMAGE_TOOLBAR_ICON_SIZE
add edx,(30 shl 16) ;
add edx,(30 shl 16) ;app1 text
int 0x40
add ebx,IMAGE_TOOLBAR_ICON_SIZE
add edx,(25 shl 16) ;
add edx,(25 shl 16) ;app1 gps
int 0x40
add ebx,IMAGE_TOOLBAR_ICON_SIZE
add edx,(25 shl 16) ;app2 text
int 0x40
add ebx,IMAGE_TOOLBAR_ICON_SIZE
add edx,(25 shl 16) ;app2 thumbnail
int 0x40
;add ebx,IMAGE_TOOLBAR_ICON_SIZE
;add edx,(25 shl 16) ;
;int 0x40
; *** <20><><EFBFBD><E1AEA2><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ***
stdcall [buf2d_draw], buf_0
mcall 12,2
mcall SF_REDRAW,SSF_END_DRAW
popad
ret
align 4
key:
mcall 2
mcall SF_GET_KEY
jmp still
align 4
@@ -214,7 +150,7 @@ mouse:
align 4
button:
mcall 17
mcall SF_GET_BUTTON
cmp ah,3
jne @f
call but_new_file
@@ -239,14 +175,19 @@ button:
jne @f
call but_3
@@:
cmp ah,9
jne @f
call but_4
@@:
cmp ah,1
jne still
.exit:
stdcall [buf2d_delete],buf_0
stdcall [buf2d_delete],buf_1 ;㤠<><20><><EFBFBD><EFBFBD><EFBFBD>
stdcall [buf2d_delete],buf_thumb
stdcall mem.Free,[image_data_toolbar]
stdcall mem.Free,[open_file]
mcall -1
mcall SF_TERMINATE_PROCESS
align 4
@@ -269,16 +210,14 @@ but_open_file:
je .end_open_file
;<3B><><EFBFBD> <20><><EFBFBD> 㤠筮<E3A4A0> <20><><EFBFBD><EFBFBD><EFBFBD><20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
mov eax,70 ;70-<2D> <20><EFBFBD><E3ADAA><EFBFBD><><E0A0A1><EFBFBD> <20><><E4A0A9><EFBFBD><EFBFBD>
mov [run_file_70.Function], 5
mov [run_file_70.Function], SSF_GET_INFO
mov [run_file_70.Position], 0
mov [run_file_70.Flags], 0
mov dword[run_file_70.Count], 0
m2m [run_file_70.Buffer], [open_file]
mov byte[run_file_70+20], 0
mov dword[run_file_70.FileName], openfile_path
mov ebx,run_file_70
int 0x40 ;<3B><><EFBFBD><EFBFBD><EFBFBD><E3A6A0><> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD>
mcall SF_FILE,run_file_70
cmp eax,0
jne .end_open_file
@@ -293,16 +232,14 @@ but_open_file:
stdcall mem.ReAlloc, dword[open_file],ebx
@@:
mov eax,70 ;70-<2D> <20><EFBFBD><E3ADAA><EFBFBD><><E0A0A1><EFBFBD> <20><><E4A0A9><EFBFBD><EFBFBD>
mov [run_file_70.Function], 0
mov [run_file_70.Function], SSF_READ_FILE
mov [run_file_70.Position], 0
mov [run_file_70.Flags], 0
m2m dword[run_file_70.Count], dword[open_file_size]
m2m dword[run_file_70.Buffer],dword[open_file]
mov byte[run_file_70+20], 0
mov dword[run_file_70.FileName], openfile_path
mov ebx,run_file_70
int 0x40 ;<3B><><EFBFBD><EFBFBD><EFBFBD><E3A6A0><> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD>
mcall SF_FILE,run_file_70 ;<3B><><EFBFBD><EFBFBD><EFBFBD><E3A6A0><> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD>
cmp ebx,0xffffffff
je .end_open_file
@@ -310,13 +247,16 @@ but_open_file:
;add ebx,dword[open_file]
;mov byte[ebx],0 ;<3B><> <20><><EFBFBD><20>᫨ ࠭<><E0A0AD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><> <20><><EFBFBD><EFBFBD><EFBFBD><><E0A0A7><EFBFBD><EFBFBD> <20><><EFBFBD><20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><E4A0A9><EFBFBD>
stdcall [exif_get_app1], [open_file],h_app1
mcall 71,1,openfile_path
mcall SF_SET_CAPTION,1,openfile_path
call draw_file_1
.end_open_file:
popad
ret
;description:
; <20><><EFBFBD><EFBFBD><EFBFBD><E0ACA0><EFBFBD> exif <20><> app1
; ⥪<><EFBFBD><E2AEA2> <20> <20><><EFBFBD><E1ABAE><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
align 4
draw_file_1:
pushad
@@ -360,6 +300,9 @@ pushad
popad
ret
;description:
; <20><><EFBFBD><EFBFBD><EFBFBD><E0ACA0><EFBFBD> exif <20><> app1
; <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> gps
align 4
draw_file_2:
pushad
@@ -403,6 +346,9 @@ pushad
popad
ret
;description:
; <20><><EFBFBD><EFBFBD><EFBFBD><E0ACA0><EFBFBD> exif <20><> app2
; ⥪<><EFBFBD><E2AEA2> <20> <20><><EFBFBD><E1ABAE><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
align 4
draw_file_3:
pushad
@@ -425,7 +371,7 @@ pushad
cmp dword[h_child],0
je .no_found_child
mov eax,1
mov eax,1 ;25
sub ebx,5
.cycle_1:
stdcall [exif_get_app1_tag], h_child,eax,txt_buf,80
@@ -446,6 +392,63 @@ pushad
popad
ret
;description:
; <20><><EFBFBD><EFBFBD><EFBFBD><E0ACA0><EFBFBD> exif <20><> app2
; <20><><EFBFBD><EFBFBD><E2A8AD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> Nikon
align 4
draw_file_4:
pushad
stdcall [buf2d_clear], buf_0, [buf_0.color]
cmp dword[open_file_size],0
je .open_file
mov eax,1
mov ebx,1
;<3B><><EFBFBD><E5AEA4> app2
stdcall [exif_get_app2], h_app1,h_child
cmp dword[h_child],0
je .no_found_child
;<3B><><EFBFBD><EFBFBD><EFBFBD><EBA2A0> <20><><EFBFBD><EFBFBD><EFBFBD><>
stdcall [exif_get_app1_child], h_child,h_child,0x0011
cmp dword[h_child],0
je .no_found_child
stdcall [exif_get_app1_child], h_child,h_child_siz,0x0202
cmp dword[h_child_siz],0
je .no_found_child
stdcall [exif_get_app1_child], h_child,h_child,0x0201
cmp dword[h_child],0
je .no_found_child
;<3B><><EFBFBD><E0A5A4><20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD> <20> <20><><EFBFBD><E0A5A2><EFBFBD><EFBFBD> <20><><EFBFBD> <20><> <20><EFBFBD><E0A5AC><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> ebx
stdcall [img_decode],dword[h_child],dword[h_child_siz],0
cmp dword[eax+4],1
jl .no_found_child
cmp dword[eax+8],1
jl .no_found_child
mov ebx,eax
stdcall [buf2d_resize],buf_thumb,[eax+4],[eax+8],1
;<3B><EFBFBD>ࠧ㥬 <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD> <20> <20><><EFBFBD><E0ACA0> rgb
stdcall [img_to_rgb2],ebx,[buf_thumb]
;㤠<><20><EFBFBD><E0A5AC><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> ebx
stdcall [img_destroy],ebx
stdcall [buf2d_bit_blt], buf_0, 0,15, buf_thumb ;<3B><><EFBFBD><20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD>
stdcall [buf2d_draw_text], buf_0, buf_1,txt_thumb,3,3,0xb000
jmp @f
.no_found_child:
stdcall [buf2d_draw_text], buf_0, buf_1,txt_nochild,3,3,0xb000
jmp @f
.open_file:
stdcall [buf2d_draw_text], buf_0, buf_1,txt_openfile,3,3,0xb000
@@:
stdcall [buf2d_draw], buf_0
popad
ret
align 4
but_save_file:
pushad
@@ -456,18 +459,36 @@ but_save_file:
je .end_save_file
;<3B><><EFBFBD> <20><><EFBFBD> 㤠筮<E3A4A0> <20><><EFBFBD><EFBFBD><EFBFBD><20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
mov eax,70 ;70-<2D> <20><EFBFBD><E3ADAA><EFBFBD><><E0A0A1><EFBFBD> <20><><E4A0A9><EFBFBD><EFBFBD>
mov [run_file_70.Function], 2
mov [run_file_70.Function], SSF_CREATE_FILE
mov [run_file_70.Position], 0
mov [run_file_70.Flags], 0
if 1 ;<3B><EFBFBD><E2A0A2> 1 <20><20><><EFBFBD><EFBFBD><E0A0AD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD>
mov ebx, dword[open_file]
mov [run_file_70.Buffer], ebx
mov ebx,[open_file_size]
end if
if 0 ;<3B><EFBFBD><E2A0A2> 1 <20><20><><EFBFBD><EFBFBD><E0A0AD><EFBFBD><EFBFBD><EFBFBD> <20><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD>
;<3B><><EFBFBD><E5AEA4> app2
stdcall [exif_get_app2], h_app1,h_child
cmp dword[h_child],0
je .end_save_file
;<3B><><EFBFBD><EFBFBD><EFBFBD><EBA2A0> <20><><EFBFBD><EFBFBD><EFBFBD><>
stdcall [exif_get_app1_child], h_child,h_child,0x0011
cmp dword[h_child],0
je .end_save_file
stdcall [exif_get_app1_child], h_child,h_child,0x0201
cmp dword[h_child],0
je .end_save_file
mov ebx,dword[h_child] ;dword[open_file]
mov [run_file_70.Buffer], ebx
mov ebx,... ; <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><><E0A0A7><EFBFBD> <20><EFBFBD><E1AAA8> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 祬 [open_file_size]
end if
mov dword[run_file_70.Count], ebx ;ࠧ<><E0A0A7><EFBFBD><><E4A0A9>
mov byte[run_file_70+20], 0
mov dword[run_file_70.FileName], openfile_path
mov ebx,run_file_70
int 0x40 ;<3B><><EFBFBD>࠭塞 䠩<> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD>
mcall SF_FILE,run_file_70 ;<3B><><EFBFBD>࠭塞 䠩<>
;cmp ebx,0xffffffff
;je .end_save_file
; ... ᮮ<><EFBFBD><E9A5AD> <20> <20><>㤠筮<E3A4A0> <20><><EFBFBD><EFBFBD><E0A0AD><EFBFBD><EFBFBD> ...
@@ -491,6 +512,11 @@ but_3:
call draw_file_3 ;<3B><><EFBFBD><EFBFBD><EFBFBD><E0ACA0><EFBFBD> app2
ret
align 4
but_4:
call draw_file_4 ;<3B><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>-<2D><> <20><><EFBFBD><EFBFBD><EFBFBD><E0ACA0><EFBFBD> ...
ret
;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><><E4A0A9><EFBFBD>
align 4
OpenDialog_data:
@@ -560,9 +586,9 @@ l_libs_start:
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,\
lib_2 l_libs lib_name_2, sys_path, file_name, 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,\
lib_3 l_libs lib_name_3, sys_path, file_name, system_dir_3,\
err_msg_found_lib_3,head_f_l,import_exif,err_msg_import_3,head_f_i
l_libs_end:
@@ -629,7 +655,9 @@ import_buf2d:
buf2d_clear dd sz_buf2d_clear
buf2d_draw dd sz_buf2d_draw
buf2d_delete dd sz_buf2d_delete
buf2d_resize dd sz_buf2d_resize
buf2d_conv_24_to_8 dd sz_buf2d_conv_24_to_8
buf2d_bit_blt dd sz_buf2d_bit_blt
buf2d_convert_text_matrix dd sz_buf2d_convert_text_matrix
buf2d_draw_text dd sz_buf2d_draw_text
dd 0,0
@@ -639,7 +667,9 @@ import_buf2d:
sz_buf2d_clear db 'buf2d_clear',0
sz_buf2d_draw db 'buf2d_draw',0
sz_buf2d_delete db 'buf2d_delete',0
sz_buf2d_resize db 'buf2d_resize',0
sz_buf2d_conv_24_to_8 db 'buf2d_conv_24_to_8',0
sz_buf2d_bit_blt db 'buf2d_bit_blt',0
sz_buf2d_convert_text_matrix db 'buf2d_convert_text_matrix',0
sz_buf2d_draw_text db 'buf2d_draw_text',0
@@ -664,7 +694,7 @@ align 4
buf_0: dd 0 ;㪠<><E3AAA0><EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD>
dw 5 ;+4 left
dw 31 ;+6 top
.w: dd 456 ;+8 w
.w: dd 570 ;+8 w
.h: dd 480 ;+12 h
.color: dd 0xffffd0 ;+16 color
db 24 ;+20 bit in pixel
@@ -679,21 +709,31 @@ buf_1:
dd 0 ;+16 color
db 24 ;+20 bit in pixel
h_app1 dd 0,0,0 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><><E2A5A3>
dw 0
h_child dd 0,0,0 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
dw 0
align 4
buf_thumb:
dd 0 ;<EFBFBD><EFBFBD><EFBFBD> <20><> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
dw 0 ;+4 left
dw 0 ;+6 top
dd 120 ;+8 w
dd 100 ;+12 h
dd 0 ;+16 color
db 24 ;+20 bit in pixel
h_app1 rb 14 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><><E2A5A3>
h_child rb 14 ;<3B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><><E2A5A3>
h_child_siz rb 14
txt_openfile db '<27><><EFBFBD><EFBFBD><E0AEA9><> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD> <20> <20><><EFBFBD><E0ACA0> *.jpg.',0
txt_thumb db '<27><><EFBFBD> <20><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><E0A0A6><EFBFBD><EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> app2.',0
txt_nochild db '<27><><EFBFBD><EFBFBD><EFBFBD><E0ACA0><EFBFBD> <20><> <20><20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>.',0
txt_buf rb 80
align 16
i_end:
rb 2048
stacktop:
sys_path rb 1024
file_name:
rb 1024 ;4096
library_path rb 1024
file_name rb 4096
plugin_path rb 4096
openfile_path rb 4096
filename_area rb 256

View File

@@ -984,11 +984,12 @@ endp
align 4
proc exif_get_app2, app1:dword, app2:dword
pushad
mov edi,[app2]
mov eax,[app1]
xor edx,edx
cmp [eax],edx
je .no_suport ;<3B><20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><><E3AAA0><EFBFBD> <20><> <20><><EFBFBD> exif.app1
mov edi,[app2]
movzx edx,word[eax+offs_m_or_i] ;if 'MM' edx=1
;<3B><><EFBFBD> <20><><EFBFBD><20><EFBFBD><E0AEA8><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>