forked from KolibriOS/kolibrios
NSV-fonts: tickfields renumerated
git-svn-id: svn://kolibrios.org@2499 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
05bd5db1d7
commit
3017a820d3
@ -214,14 +214,17 @@ diff16 "parse_tick : ",0,$
|
|||||||
pushad
|
pushad
|
||||||
mov dx, word[edx]
|
mov dx, word[edx]
|
||||||
movzx ecx, dl
|
movzx ecx, dl
|
||||||
test dl, 0xE0 ; ticks #32..255
|
test dl, 0xE0
|
||||||
jz .lntick.short
|
jz .lntick.short ; ticks #0..31
|
||||||
cmp dl, 0xE0
|
cmp dl, 0xE0
|
||||||
jae .lntick.long
|
jae .lntick.long ; ticks #224..255
|
||||||
cmp dl, 0xC0
|
cmp dl, 0xD8
|
||||||
jae .cstick
|
jae .cstick ; ticks #216..223
|
||||||
.gptick:
|
.gptick:
|
||||||
push edx
|
push edx
|
||||||
|
cmp dl, 38
|
||||||
|
jb .sptick ; special ticks #32-37
|
||||||
|
; general ticks #38..215
|
||||||
mov cl, dh
|
mov cl, dh
|
||||||
shr cl, 3 ; number of origin
|
shr cl, 3 ; number of origin
|
||||||
mov edx, [ebp+8] ; orig. table
|
mov edx, [ebp+8] ; orig. table
|
||||||
@ -230,31 +233,32 @@ diff16 "parse_tick : ",0,$
|
|||||||
mov cl, dh
|
mov cl, dh
|
||||||
and cl, 7 ; three rotation bits
|
and cl, 7 ; three rotation bits
|
||||||
movzx edx, dl ; dl = gptick#
|
movzx edx, dl ; dl = gptick#
|
||||||
sub dl, 32
|
cmp dl, 80
|
||||||
cmp dl, (sdsh_data.v5-sdsh_data.v1)
|
|
||||||
jae .gptick.2
|
jae .gptick.2
|
||||||
|
sub dl, 38
|
||||||
|
|
||||||
.gptick.1:
|
.gptick.1:
|
||||||
; 1-byte tickgroups .v1-v4:
|
; 1-byte tickgroups .v1-v4:
|
||||||
lea esi, [sdsh_data.v1+edx]
|
lea esi, [sdsh_data.v1+edx]
|
||||||
inc dh
|
inc dh ; dh = 1 vertex
|
||||||
sub dl, 2 ; .v1 : 2 ticks only (#32, 33)
|
sub dl, 2 ; .v1 : 2 ticks only (#38, 39)
|
||||||
jae .gptick.1v2v4
|
jae .gptick.1v2v4
|
||||||
mov dl, dh
|
mov dl, dh
|
||||||
mov dh, ch
|
mov dh, ch
|
||||||
jmp .draw
|
jmp .draw
|
||||||
|
|
||||||
.gptick.1v2v4:
|
.gptick.1v2v4:
|
||||||
; 1-byte tickgroups .v2-v4 : 8 ticks each
|
; 1-byte tickgroups .v2-v4 : 8, 16 and 16 ticks
|
||||||
inc dh
|
inc dh ; dh = 2 vertice
|
||||||
shr dl, 3
|
add dl, 8
|
||||||
|
shr dl, 4
|
||||||
jmp .gptick.done
|
jmp .gptick.done
|
||||||
|
|
||||||
.gptick.2:
|
.gptick.2:
|
||||||
; 2-byte tickgroups .v5-v8: 8 ticks each
|
; 2-byte tickgroups .v5-v8: 8 ticks each
|
||||||
sub dl, (sdsh_data.v5-sdsh_data.v1)
|
cmp dl, 112
|
||||||
cmp dl, (sdsh_data.v9-sdsh_data.v5)
|
|
||||||
jae .gptick.3
|
jae .gptick.3
|
||||||
|
sub dl, 80
|
||||||
lea esi, [sdsh_data.v5 + edx*2]
|
lea esi, [sdsh_data.v5 + edx*2]
|
||||||
mov dh, 5
|
mov dh, 5
|
||||||
shr dl, 3
|
shr dl, 3
|
||||||
@ -262,9 +266,9 @@ diff16 "parse_tick : ",0,$
|
|||||||
|
|
||||||
.gptick.3:
|
.gptick.3:
|
||||||
; 3-byte tickgroups .v9-12: 4 ticks each
|
; 3-byte tickgroups .v9-12: 4 ticks each
|
||||||
sub dl, (sdsh_data.v9-sdsh_data.v5)
|
cmp dl, 128
|
||||||
cmp dl, (sdsh_data.v13-sdsh_data.v9)
|
|
||||||
jae .gptick.4
|
jae .gptick.4
|
||||||
|
sub dl, 112
|
||||||
lea esi, [sdsh_data.v9 + edx*2 + edx]
|
lea esi, [sdsh_data.v9 + edx*2 + edx]
|
||||||
mov dh, 9
|
mov dh, 9
|
||||||
shr dl, 2
|
shr dl, 2
|
||||||
@ -272,9 +276,9 @@ diff16 "parse_tick : ",0,$
|
|||||||
|
|
||||||
.gptick.4:
|
.gptick.4:
|
||||||
; 4-byte tickgroups .v13-16: 4 ticks each
|
; 4-byte tickgroups .v13-16: 4 ticks each
|
||||||
sub dl, (sdsh_data.v13-sdsh_data.v9)
|
cmp dl, 128 ; fix this when needed
|
||||||
cmp dl, 16
|
jae .exit ; not implemented yet!
|
||||||
jae .exit
|
sub dl, 128
|
||||||
lea esi, [sdsh_data.v13 + edx*4]
|
lea esi, [sdsh_data.v13 + edx*4]
|
||||||
mov dh, 13
|
mov dh, 13
|
||||||
shr dl, 2
|
shr dl, 2
|
||||||
@ -352,6 +356,7 @@ diff16 "parse_tick : ",0,$
|
|||||||
pop ecx
|
pop ecx
|
||||||
call draw_tick
|
call draw_tick
|
||||||
.gptick.5:
|
.gptick.5:
|
||||||
|
.sptick:
|
||||||
.exit:
|
.exit:
|
||||||
popad
|
popad
|
||||||
ret
|
ret
|
||||||
@ -496,7 +501,7 @@ ch_checkwin:
|
|||||||
|
|
||||||
align 4
|
align 4
|
||||||
diff16 "ch_putpix : ",0,$
|
diff16 "ch_putpix : ",0,$
|
||||||
ch_putpixel:
|
; ch_putpixel:
|
||||||
; eax = x coordinate
|
; eax = x coordinate
|
||||||
; ebx = y coordinate
|
; ebx = y coordinate
|
||||||
; edi = 0x0RRGGBB
|
; edi = 0x0RRGGBB
|
||||||
@ -508,6 +513,24 @@ ch_putpixel:
|
|||||||
pop edx
|
pop edx
|
||||||
ret
|
ret
|
||||||
;)
|
;)
|
||||||
|
ch_putpixel:
|
||||||
|
; test version!!! ===== to be removed!!
|
||||||
|
; eax = x coordinate
|
||||||
|
; ebx = y coordinate
|
||||||
|
; edi = 0x0RRGGBB
|
||||||
|
push edx
|
||||||
|
mov edx, ebx
|
||||||
|
shl edx, 1
|
||||||
|
imul edx, [BytesPerScanLine]
|
||||||
|
lea edx, [edx+eax*8]
|
||||||
|
add edx, LFB_BASE
|
||||||
|
mov [edx], edi
|
||||||
|
mov [edx+4], edi
|
||||||
|
sub edx, [BytesPerScanLine]
|
||||||
|
mov [edx], edi
|
||||||
|
mov [edx+4], edi
|
||||||
|
pop edx
|
||||||
|
ret
|
||||||
|
|
||||||
|
|
||||||
diff10 "new font code size",sdsh_code,$
|
diff10 "new font code size",sdsh_code,$
|
||||||
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user