News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu
avatar_McArti0

Change Aspect Ratio screen in native Amstrad Basic. NEW RESOLUTIONS in BASIC!

Started by McArti0, 14:40, 25 January 22

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

McArti0

Hi everyone!


I want to show You my experimental work.


Recompile part of LowRom and procedure to join and swithing between Rom and Ram.


Cherry on top, parameterization all variables to change aspect ratio screen. Many New Resolutions in Basic.


Main procedure joining recompiled ram and rom.


;<------------------------ jump from BDD0  and  BDCD
.l149c
ex (sp),hl
push af


ld a,#12
cp d
jr nz,l14cf
ld a,#65
cp e
jr nz,l14cf
ld de,l1265 ;<----------------- DE,#1265 !!!!!!!!


.l14cf


bit 7,h
jp nz,l06a2


ld a,#12
cp h
jr nz,l14aa
ld a,#9d
cp l
jr nz,l14aa
ld hl,l129d
.l14aa
ld a,#11
cp h
jr nz,l14b6
ld a,#76
cp l
jr nz,l14b6
ld hl,l1176
.l14b6
ld a,#2e
cp h
jr nz,l14c3
ld a,#7f
cp l
jr nz,l14c3
ld hl,l147f
.l14c3


jp l0688   ;->>>>>>>next in 0688



.l147f   ;change org pricedure from 2E7F
call l1265
call l13ac
push af
ex de,hl
call l1170
ld hl,(#b116)
inc h
call l11ca
jr nc,l1496
ld (#b116),hl
.l1496
call #2e4a
jp #2e99



.l0688  ; c.d.  bdcd i bdd0 from 147f
ld a,#15
cp h
jr nz,l0695
ld a,#52
cp l
jr nz,l0695
ld hl,l1552
jr l06a2
.l0695
ld a,#11
cp h
jr nz,l06a2
ld a,#47
cp l
jr nz,l06a2
ld hl,l1147
.l06a2


pop af
ex (sp),hl
jp l125f



.l06b0   ; jump from B992
push af
res 7,d
res 6,d
push hl
or a
ld hl,0-#1208 ; #edf8
adc hl,de
jr nz,l06bf
ld de,l1208
.l06bf
or A
ld hl,0-#16EA
adc hl,de
jr nz,l06bf_1
ld de,l16ea
.l06bf_1
or a
ld hl,0-#16A5
adc hl,de
jr nz,l06bf_2
ld de,l16a5
.l06bf_2


or a
ld hl,0-#0ae9
adc hl,de
jr nz,l06bf_3
ld de,l0ae9
.l06bf_3


or a
ld hl,0-#19d9
adc hl,de
jr nz,l06bf_4
ld de,l19d9
.l06bf_4


pop hl
pop af
ret



Hall recompiled code




width equ 64
hight  equ 32


m1width equ width / 2
print width
print m1width
org #85cc
.begin
.to_b763
dw l1513    ;0
dw l1335
dw l1297
dw l1286
dw l0AE9
dw l1940
dw l1459
dw l14E1
dw l1519
dw l151E
dw l1523   ;20
dw l1528
dw l154F
dw l153F
dw l12AB
dw l12A6
dw l155E
dw l1599
dw l158F
dw l1578
dw l1565   ;40
dw l1452
dw l14EC
dw l0C55
dw l12C6
dw l150D
dw l1501
dw l14EB
dw l14F1
dw l14FA
dw l1539   ;60
dw l1547   ;62
.DO_bdcd
dw l149c   ;64
dw l149c
dw l134b
dw l13be
dw l140a
dw l1786
dw l179a
dw l17b4
dw l0c8a
dw l0c71
dw l0b17
dw l1db8
dw l0835
dw l1d40   ;90
.l_skok_z_B992
dw l06b0   ;92-93
.l_adresy
dw w1714   ;94


dw b2F


dw b5F


dw l16      ;100


dw width1


dw width2


dw bminus20


dw bplus20


dw bminus60_1   ;110


dw bplus40   


dw bplus60


dw bminus60_2


dw bplus40_2   ;118


dw GrafResY


dw x12 ;graphic multiplier


dw GrafResOriginX


dw GrafResOriginY




.l00e8
dec hl
ld (hl),#00
dec hl
ld a,(#b82e)
or a
jr nz,l00fe
ld (#b82d),hl
ld (#b82f),hl
ld hl,#b831
set 6,(hl)
ret
.l00fe
ld de,(#b82f)
ld (#b82f),hl
ex de,hl
ld (hl),e
inc hl
ld (hl),d
ret
ld (#b832),sp
ld sp,#b8b4
push hl
push de
push bc
ld hl,#b831
bit 6,(hl)
jr z,l0139
.l011b
set 7,(hl)
.l011d
ld hl,(#b82d)
ld a,h
or a
jr z,l0132
ld e,(hl)
inc hl
ld d,(hl)
ld (#b82d),de
inc hl
call l0209
di
jr l011d
.l0132
ld hl,#b831
bit 0,(hl)
jr z,l0149
.l0139
ld (hl),#00
scf
ex af,af'
call l0189
or a
ex af,af'
ld hl,#b831
ld a,(hl)
or a
jr nz,l011b
.l0149
ld (hl),#00
pop bc
pop de
pop hl
ld sp,(#b832)
ret
.l0153
ld e,(hl)
inc hl
ld a,(hl)
inc hl
or a
jp z,l01e2
ld d,a
push de
call l01e2
pop hl
jr l0153
.l0163
push hl
inc hl
inc hl
call l01d2
pop hl
ld de,#b8b9
jp l0379
.l0170
ld de,#b8b9
jp l0388
push hl
inc hl
inc hl
call l01d2
pop hl
ld de,#b8bb
jp l0379
ld de,#b8bb
jp l0388
.l0189
ld hl,(#b8bd)
.l018c
ld a,h
or a
ret z
ld e,(hl)
inc hl
ld d,(hl)
inc hl
ld c,(hl)
inc hl
ld b,(hl)
ld a,b
or c
jr z,l01b0
dec bc
ld a,b
or c
jr nz,l01ad
push de
inc hl
inc hl
push hl
inc hl
call l01e2
pop hl
ld b,(hl)
dec hl
ld c,(hl)
dec hl
pop de
.l01ad
ld (hl),b
dec hl
ld (hl),c
.l01b0
ex de,hl
jr l018c
push hl
inc hl
inc hl
di
ld (hl),e
inc hl
ld (hl),d
inc hl
ld (hl),c
inc hl
ld (hl),b
pop hl
ld de,#b8bd
jp l0379
ld de,#b8bd
call l0388
ret nc
ex de,hl
inc hl
ld e,(hl)
inc hl
ld d,(hl)
ret
.l01d2
di
inc hl
inc hl
ld (hl),#00
inc hl
ld (hl),b
inc hl
ld (hl),e
inc hl
ld (hl),d
inc hl
ld (hl),c
inc hl
ei
ret
.l01e2
inc hl
inc hl
di
ld a,(hl)
inc (hl)
jp m,l0201
or a
jr nz,l0202
inc hl
ld a,(hl)
dec hl
or a
jp p,l022e
ex af,af'
jr nc,l0208
ex af,af'
add a
jp p,l00e8
dec (hl)
inc hl
inc hl
jr l0222
.l0201
dec (hl)
.l0202
ex af,af'
jr c,l0206
ei
.l0206
ex af,af'
ret
.l0208
ex af,af'
.l0209
ei
ld a,(hl)
dec a
ret m
.l020d
push hl
call l021b
pop hl
dec (hl)
ret z
jp p,l020d
inc (hl)
ret
inc hl
inc hl
.l021b
inc hl
ld a,(hl)
inc hl
rra
jp nc,#b9c1
.l0222
ld e,(hl)
inc hl
ld d,(hl)
ex de,hl
jp (hl)
ld hl,#0000
ld (#b8c1),hl
ret
.l022e
push hl
ld b,a
ld de,#b8c3
.l0233
ex de,hl
dec hl
dec hl
ld d,(hl)
dec hl
ld e,(hl)
ld a,d
or a
jr z,l0244
inc de
inc de
inc de
ld a,(de)
cp b
jr nc,l0233
.l0244
pop de
dec de
inc hl
ld a,(hl)
ld (de),a
dec de
ld (hl),d
dec hl
ld a,(hl)
ld (de),a
ld (hl),e
ex af,af'
jr c,l0253
ei
.l0253
ex af,af'
ret
di
ld hl,(#b8c0)
ld a,h
or a
jr z,l0274
push hl
ld e,(hl)
inc hl
ld d,(hl)
inc hl
inc hl
ld a,(#b8c2)
cp (hl)
jr nc,l0273
push af
ld a,(hl)
ld (#b8c2),a
ld (#b8c0),de
pop af
.l0273
pop hl
.l0274
ei
ret
ld (#b8c2),a
inc hl
inc hl
dec (hl)
ret z
di
jp p,l022e
inc (hl)
ei
ret
.l0284
call l028d
ld de,#b8c0
jp l0388
.l028d
inc hl
inc hl
ld (hl),#c0
dec hl
dec hl
ret
ld hl,#b8c2
set 5,(hl)
ret
ld hl,#b8c2
res 5,(hl)
ret
.l02a0
push hl
ld de,(#b8d3)
ld (#b8d3),hl
ld (hl),e
inc hl
ld (hl),d
inc hl
ld (hl),c
inc hl
ld (hl),b
pop hl
ret
ld de,#b8c3
ld bc,#0010
call #baa1
ex de,hl
dec hl
set 7,(hl)
ld hl,(#b8d3)
ld a,l
jr l02d4
.l02c4
push hl
inc hl
inc hl
ld c,(hl)
inc hl
ld b,(hl)
call l02f1
pop de
ret c
ex de,hl
ld a,(hl)
inc hl
ld h,(hl)
ld l,a
.l02d4
or h
jr nz,l02c4
ld c,#ff
.l02d9
inc c
call #ba7e
push af
and #03
ld b,a
call z,l02f1
call c,#061c ;------------------------ do ROM
pop af
add a
jr nc,l02d9
ld a,c
cp #10
jr c,l02d9
ret
.l02f1
ld hl,#c004
ld a,b
or a
jr z,l02fc
ld h,b
ld l,c
ld c,#ff
.l02fc
call #ba79
push bc
ld e,(hl)
inc hl
ld d,(hl)
inc hl
ex de,hl
jr l031e
.l0307
ld bc,#b8c3
.l030a
ld a,(bc)
cp (hl)
jr nz,l0316
inc hl
inc bc
add a
jr nc,l030a
ex de,hl
jr l0322
.l0316
ld a,(hl)
inc hl
add a
jr nc,l0316
inc de
inc de
inc de
.l031e
ld a,(hl)
or a
jr nz,l0307
.l0322
pop bc
jp #ba87
ld c,#0f
.l0328
call l0330
dec c
jp p,l0328
ret
.l0330
ld a,(#b8d9)
cp c
ret z
ld a,c
cp #10
ret nc
call #ba79
ld a,(#c000)
and #03
dec a
jr nz,l0366
push bc
scf
call #c006
jr nc,l0365
push de
inc hl
ex de,hl
ld hl,#b8da
ld bc,(#b8d6)
ld b,#00
add hl,bc
add hl,bc
ld (hl),e
inc hl
ld (hl),d
ld hl,#fffc
add hl,de
call l02a0
dec hl
pop de
.l0365
pop bc
.l0366
jp #ba87
.l0369
ld a,(hl)
cp e
inc hl
ld a,(hl)
dec hl
jr nz,l0373
cp d
scf
ret z
.l0373
or a
ret z
ld l,(hl)
ld h,a
jr l0369
.l0379
ex de,hl
di
call l0369
jr c,l0386
ld (hl),e
inc hl
ld (hl),d
inc de
xor a
ld (de),a
.l0386
ei
ret
.l0388
ex de,hl
di
call l0369
jr nc,l0395
ld a,(de)
ld (hl),a
inc de
inc hl
ld a,(de)
ld (hl),a
.l0395
ei
ret
di
exx
ld hl,#b8d5
ld d,(hl)
ld (hl),a
or #c0
out (c),a
ld a,d
exx
ei
ret


;nop


.l0591




; ----- CRTC default




;org #05c5
;db #3f,#28,#2e,#8e,#26,#00,#19,#1e
;db #00,#07,#00,#00,#30,#00,#c0,#00
;db #3f,#28,#2e,#8e,#1f,#06,#19,#1b
;db #00,#07,#00,#00,#30,#00,#c0,#00




;-----------------------------------
.l0688  ; c.d.  bdcd i bdd0 z 147f
ld a,#15
cp h
jr nz,l0695
ld a,#52
cp l
jr nz,l0695
ld hl,l1552
jr l06a2
.l0695
ld a,#11
cp h
jr nz,l06a2
ld a,#47
cp l
jr nz,l06a2
ld hl,l1147
.l06a2


pop af
ex (sp),hl
jp l125f




.l06b0   ; z B992
push af
res 7,d
res 6,d
push hl
or a
ld hl,0-#1208 ; #edf8
adc hl,de
jr nz,l06bf
ld de,l1208
.l06bf
or A
ld hl,0-#16EA
adc hl,de
jr nz,l06bf_1
ld de,l16ea
.l06bf_1
or a
ld hl,0-#16A5
adc hl,de
jr nz,l06bf_2
ld de,l16a5
.l06bf_2


or a
ld hl,0-#0ae9
adc hl,de
jr nz,l06bf_3
ld de,l0ae9
.l06bf_3


or a
ld hl,0-#19d9
adc hl,de
jr nz,l06bf_4
ld de,l19d9
.l06bf_4


pop hl
pop af
ret
;-----------------------------------------






; text brand


.l0776
cp #03
ret nc
di
exx
res 1,c
res 0,c
or c
ld c,a
out (c),c
ei
exx
ret
.l0786
push hl
ld hl,#0000
jr l0790
.l078c
push hl
ld hl,#0001
.l0790
push de
push bc
ex de,hl
ld bc,#7f10
call l07aa
inc hl
ld c,#00
.l079c
call l07aa
add hl,de
inc c
ld a,c
cp #10
jr nz,l079c
pop bc
pop de
pop hl
ret
.l07aa
out (c),c
ld a,(hl)
and #1f
or #40
out (c),a
ret
.l07b4
push af
push bc
ld b,#f5
.l07b8
in a,(c)
rra
jr nc,l07b8
pop bc
pop af
ret
.l07c0
push bc
rrca
rrca
and #30
ld c,a
ld a,h
rra
and #03
or c
ld bc,#bc0c
out (c),c
inc b
out (c),a
dec b
inc c
out (c),c
inc b
ld a,h
rra
ld a,l
rra
out (c),a
pop bc
ret
.l07e0
ld hl,#07f7
ld de,#b804
ld bc,#0015
ldir
ld hl,#07f1
jp l0ab4
inc bc
pop af
cp l
jp l0835
ld a,(bc)
and b
ld e,(hl)
and c
ld e,h
and d
ld a,e
and e
inc hl
and (hl)
ld b,b
xor e
ld a,h
xor h
ld a,l
xor l
ld a,(hl)
xor (hl)
ld e,l
xor a
ld e,e
rst #20
add a
inc a
ld c,a
ld b,#00
ld de,#b804
cp #2a
call c,#baa1
ret
push bc
push hl
ld hl,#b804
ld b,(hl)
inc b
.l0822
dec b
jr z,l082f
inc hl
cp (hl)
inc hl
jr nz,l0822
ld a,(hl)
cp #ff
jr z,l0832
.l082f
call #bdf1
.l0832
pop hl
pop bc
ret
.l0835
ld bc,#0032
.l0838
call l0858
jr nc,l0844
djnz l0838
dec c
jr nz,l0838
or a
ret
.l0844
push bc
ld b,#ef
and #7f
out (c),a
or #80
di
out (c),a
and #7f
ei
out (c),a
pop bc
scf
ret
.l0858
push bc
ld c,a
ld b,#f5
in a,(c)
rla
rla
ld a,c
pop bc
ret
di
ld b,#f4
out (c),a
ld b,#f6
in a,(c)
or #c0
out (c),a
and #3f
out (c),a
ld b,#f4
out (c),c
ld b,#f6
ld c,a
or #80
out (c),a
out (c),c
ei
ret
.l0883
ld bc,#f40e
out (c),c
ld b,#f6
in a,(c)
and #30
ld c,a
or #c0
out (c),a
out (c),c
inc b
ld a,#92
out (c),a
push bc
set 6,c
.l089d
ld b,#f6
out (c),c
ld b,#f4
in a,(c)
ld b,(hl)
ld (hl),a
and b
cpl
ld (de),a
inc hl
inc de
inc c
ld a,c
and #0f
cp #0a
jr nz,l089d
pop bc
ld a,#82
out (c),a
dec b
out (c),c
ret
.l08bd
ld hl,#08de
ld de,#bb00
ld bc,#cbcf
call l08cc
ld bc,#20ef
.l08cc
ld a,c
ld (de),a
inc de
ldi
inc bc
cpl
rlca
rlca
and #80
or (hl)
ld (de),a
inc de
inc hl
djnz l08cc
ret


;nop


.l0ab4
ld c,(hl)
add (hl)
nop
inc hl
ld e,(hl)
inc hl
ld d,(hl)
inc hl
ldir
ret
.l0abf
ld de,#1052
call l0786
ld a,#c0
ld (#b7c6),a
call l0ad0
jp l0b12
.l0ad0
xor a
call l0c55
ld hl,#0add
call l0ab4
jp l0cd8
add hl,bc
push hl
cp l
jp l0c8a
jp l0c71
jp l0b17
.l0ae9
and #03
cp #03
ret nc
push af
call l0d55
pop de
call l10b3
push af
call l15ce
push hl
ld a,d
call l0b31
call #bdeb
pop hl
call l15ae
pop af
call l10d1
jr l0b2e
.l0b0c
ld a,(#b7c3)
cp #01
ret
.l0b12
ld a,#01
call l0b31
.l0b17
call l0d55
ld hl,#0000
call l0b37
ld hl,(#b7c5)
ld l,#00
ld d,h
ld e,#01
ld bc,#3fff
ld (hl),l
ldir
.l0b2e
jp l0d42
.l0b31
ld (#b7c3),a
jp l0776
.l0b37
ld a,(#b7c6)
jr l0b3f
ld hl,(#b7c4)
.l0b3f
call l0b45
jp l07c0
.l0b45
and #c0
ld (#b7c6),a
push af
ld a,h
and #07
ld h,a
res 0,l
ld (#b7c4),hl
pop af
ret
ld hl,(#b7c4)
ld a,(#b7c6)
ret
.l0b5d
call l0b0c


.l0b60


w1714 equ l0b60+1
m0_width_1 equ width/4-1


ld bc,m0_width_1*256+hight-1  ;#1714   ;-------------------original #1318
ret c
m1_width_1 equ width/2-1


.l2F
b2F equ l2F+1


ld b,m1_width_1 ;#2f   ;--------------------------org #27
ret z


.l5F
b5F equ l5F+1


ld b,width-1      ;    #5f   ;------------------------org #4f
ret
.l0b6a
push de
call l0b0c
ld b,#04
jr c,l0b77
ld b,#02
jr z,l0b77
dec b
.l0b77
push bc
ld e,h
ld d,#00
ld h,d
push de
ld d,h
ld e,l
.l16
add hl,hl


if width=96
add hl,de   ;-------------------------- lx96 org x80
add hl,hl
else
if width=80
add hl,hl
add hl,de
else
add hl,hl
add hl,hl
endif
endif


add hl,hl
add hl,hl
add hl,hl


if width=66
add hl,de
add hl,de
nop
nop
nop
else
if width=62
sbc hl,de
sbc hl,de
nop
else
;x64
nop


nop
nop
nop
nop
endif
endif
;nop
;nop
;nop
;nop


pop de
.l0b87
add hl,de
djnz l0b87
ld de,(#b7c4)
add hl,de
ld a,h
and #07
ld h,a
ld a,(#b7c6)
add h
ld h,a
pop bc
pop de
ret
.l0b9b
ld a,e
sub l
inc a
add a
add a
add a
ld e,a
ld a,d
sub h
inc a
ld d,a
call l0b6a
xor a
.l0baa
add d
djnz l0baa
ld d,a
ret


.l0baf
push de
ex de,hl
.l0bb1
GrafResY equ l0bb1+2
ld hl,#00A7      ;GrafResY
or a
sbc hl,de
ld a,l
and #07
add a
add a
add a
ld c,a
ld a,l
and #f8
ld l,a
ld d,h
ld e,l
;srl d
;rr e
;srl d
;rr e
.x12
add hl,hl      ;x8 ----- org x10 (8*10)=80
add hl,hl
add hl,hl
nop
jr x12_stop


nop
nop
nop
nop
nop
nop


nop
nop
nop
nop


;sbc hl,de
;add hl,hl
.x12_stop
pop de
push bc
call l0bf6
ld a,b
and e
jr z,l0bd6
.l0bd1
rrc c
dec a
jr nz,l0bd1
.l0bd6
ex (sp),hl
ld h,c
ld c,l
ex (sp),hl
ld a,b
rrca
.l0bdc
srl d
rr e
rrca
jr c,l0bdc
add hl,de
ld de,(#b7c4)
add hl,de
ld a,h
and #07
ld h,a
ld a,(#b7c6)
add h
add c
ld h,a
pop de
ld c,d
ret
.l0bf6
call l0b0c
ld bc,#01aa
ret c
ld bc,#0388
ret z
ld bc,#0780
ret
.l0c05
inc l
ret nz
inc h
ld a,h
and #07
ret nz
ld a,h
sub #08
ld h,a
ret
ld a,l
dec l
or a
ret nz
ld a,h
dec h
and #07
ret nz
ld a,h
add #08
ld h,a
ret
.l0c1f
ld a,h
add #08
ld h,a
and #38
ret nz
ld a,h
sub #40
ld h,a
ld a,l
.lwidth_1
width1 equ lwidth_1+1
add width         ;#60 ;-------------------org #50
ld l,a
ret nc
inc h
ld a,h
and #07
ret nz
ld a,h
sub #08
ld h,a
ret
.l0c39
ld a,h
sub #08
ld h,a
and #38
cp #38
ret nz
ld a,h
add #40
ld h,a
ld a,l
.lwidth_2
width2 equ lwidth_2+1
sub width          ;#60--------------------------org #50
ld l,a
ret nc
ld a,h
dec h
and #07
ret nz
ld a,h
add #08
ld h,a
ret
.l0c55
and #03
ld hl,#0c74
jr z,l0c68
cp #02
ld l,#7a
jr c,l0c68
ld l,#7f
jr z,l0c68
ld l,#85
.l0c68
ld a,#c3
ld (#b7c7),a
ld (#b7c8),hl
ret
.l0c71
jp #b7c7
.l0c74
ld a,b
xor (hl)
and c
xor (hl)
ld (hl),a
ret
ld a,b
and c
xor (hl)
ld (hl),a
ret
ld a,c
cpl
or b
and (hl)
ld (hl),a
ret
ld a,b
and c
or (hl)
ld (hl),a
ret
.l0c8a
ld a,(hl)
jp l0cb2
.l0c8e
push bc
push de
call l0cc8
ld e,a
call l0bf6
ld b,#08
.l0c99
rrc e
rla
rrc c
jr c,l0ca2
rlc e
.l0ca2
djnz l0c99
pop de
pop bc
ret
.l0ca7
push bc
push af
call l0bf6
pop af
call l0cb2
pop bc
ret
.l0cb2
push de
ld de,#0008
.l0cb6
rrca
rl d
rrc c
jr c,l0cbf
rr d
.l0cbf
dec e
jr nz,l0cb6
ld a,d
call l0cc8
pop de
ret
.l0cc8
ld d,a
call l0b0c
ld a,d
ret nc
rrca
rrca
adc #00
rrca
sbc a
and #06
xor d
ret
.l0cd8
ld hl,#1052
ld de,#b7d4
ld bc,#0022
ldir
xor a
ld (#b7f6),a
ld hl,#0a0a
ld (#b7d2),hl
ret
ld hl,(#b7d2)
ret
.l0cf2
and #0f
inc a
jr l0cf8
.l0cf7
xor a
.l0cf8
ld e,a
ld a,b
call l0d10
ld b,(hl)
ld a,c
call l0d10
ld c,(hl)
ld a,e
call l0d35
ld (hl),c
ex de,hl
ld (hl),b
ld a,#ff
ld (#b7f7),a
ret
.l0d10
and #1f
add #99
ld l,a
adc #0d
sub l
ld h,a
ret
and #0f
inc a
jr l0d20
xor a
.l0d20
call l0d35
ld a,(de)
ld e,(hl)
call l0d2a
ld b,c
ld a,e
.l0d2a
ld c,#00
ld hl,#0d99
.l0d2f
cp (hl)
ret z
inc hl
inc c
jr l0d2f
.l0d35
ld e,a
ld d,#00
ld hl,#b7e5
add hl,de
ex de,hl
ld hl,#ffef
add hl,de
ret
.l0d42
ld hl,#b7f9
push hl
call l0170
call l0d73
ld de,#0d61
ld b,#81
pop hl
jp l0163
.l0d55
ld hl,#b7f9
call l0170
call l0d87
jp l0786
ld hl,#b7f8
dec (hl)
jr z,l0d73
dec hl
ld a,(hl)
or a
ret z
call l0d87
call l078c
jr l0d82
.l0d73
call l0d87
ld (#b7f8),a
call l078c
ld hl,#b7f6
ld a,(hl)
cpl
ld (hl),a
.l0d82
xor a
ld (#b7f7),a
ret
.l0d87
ld de,#b7e5
ld a,(#b7f6)
or a
ld a,(#b7d3)
ret z
ld de,#b7d4
ld a,(#b7d2)
ret
inc d
inc b
dec d
inc e
jr l0dbc
inc c
dec b
dec c
ld d,#06
rla
ld e,#00
rra
ld c,#07
rrca
ld (de),a
ld (bc),a
inc de
ld a,(de)
add hl,de
dec de
ld a,(bc)
inc bc
dec bc
ld bc,#0908
djnz l0dca
.l0db9
ld c,a
.l0dbc equ $ + 2
call l0b9b
.l0dbd
push hl
ld a,d
call l0eee
jr nc,l0dcd
ld b,d
.l0dc5
ld (hl),c
call l0c05
.l0dca equ $ + 1
djnz l0dc5
jr l0ddd
.l0dcd
push bc
push de
dec d
jp M,l0ddb
ld (hl),c
jr z,l0ddb
ld c,d
ld b,#00
ld d,h
ld e,l
inc de
ldir
.l0ddb
pop de
pop bc
.l0ddd
pop hl
call l0c1f
dec e
jr nz,l0dbd
ret
.l0de5
ld a,b
xor c
ld c,a
call l0b6a
ld d,#08
.l0ded
push hl
push bc
.l0def
ld a,(hl)
xor c
ld (hl),a
call l0c05
djnz l0def
pop bc
pop hl
call l0c1f
dec d
jr nz,l0ded
ret
.l0e00
ld c,a
push bc


ram_jL equ width*hight


.lminus20
bminus20 equ lminus20+1


if width=64
ld de,#00FF
else
ld de,ram_jL-2048;#ffe0   ;-20 ------------------ ffd0
endif


.lplus20
bplus20 equ lplus20+1


if width=64
ld b,1
else
ld b,2048-ram_jL ;#20   ;----------------   30
endif


call l0e2a
pop bc
call l07b4
ld a,b
or a
jr nz,l0e1f


.lminus60_1
bminus60_1 equ lminus60_1+1


ld de,-width ;#ffa0   ;-60  ------------------- ffb0
call l0e3d
ld de,#0000


.lplus40
bplus40 equ lplus40+1


ld b,-2048+width+ram_jL   ;#40   ;40       20
jr l0e2a


.l0e1f


.lplus60
bplus60 equ lplus60+1


ld de,width ;#0060   ;60 ------------------ 50
call l0e3d


.lminus60_2
bminus60_2 equ lminus60_2+1


ld de,-width ;#ffa0   ;-60   ----------------- ffb0


.lplus40_2
bplus40_2 equ lplus40_2+1


ld b,-2048+width+ram_jL  ;#40   ;40     20
.l0e2a
ld hl,(#b7c4)
add hl,de
ld a,h
and #07
ld h,a
ld a,(#b7c6)
add h
ld h,a
ld d,b
ld e,#08
jp l0dbd
.l0e3d
ld hl,(#b7c4)
add hl,de
jp l0b37
.l0e44
push af
ld a,b
or a
jr z,l0e79
push hl
call l0b9b
ex (sp),hl
inc l
call l0b6a
ld c,d
ld a,e
sub #08
ld b,a
jr z,l0e70
pop de
call l07b4
.l0e5d
push bc
push hl
push de
call l0eaa
pop hl
call l0c1f
ex de,hl
pop hl
call l0c1f
pop bc
djnz l0e5d
push de
.l0e70
pop hl
ld d,c
ld e,#08
pop af
ld c,a
jp l0dbd
.l0e79
push hl
push de
call l0b9b
ld c,d
ld a,e
sub #08
ld b,a
pop de
ex (sp),hl
jr z,l0e70
push bc
ld l,e
ld d,h
inc e
call l0b6a
ex de,hl
call l0b6a
pop bc
call l07b4
.l0e96
call l0c39
push hl
ex de,hl
call l0c39
push hl
push bc
call l0eaa
pop bc
pop de
pop hl
djnz l0e96
jr l0e70
.l0eaa
ld b,#00
call l0eec
jr c,l0ec7
call l0eec
jr nc,l0edb
push bc
xor a
sub l
ld c,a
ldir
pop bc
cpl
inc a
add c
ld c,a
ld a,h
sub #08
ld h,a
jr l0edb
.l0ec7
call l0eec
jr c,l0ede
push bc
xor a
sub e
ld c,a
ldir
pop bc
cpl
inc a
add c
ld c,a
ld a,d
sub #08
ld d,a
.l0edb
ldir
ret
.l0ede
ld b,c
.l0edf
ld a,(hl)
ld (de),a
call l0c05
ex de,hl
call l0c05
ex de,hl
djnz l0edf
ret
.l0eec
ld a,c
ex de,hl
.l0eee
dec a
add l
ret nc
ld a,h
and #07
xor #07
ret nz
scf
ret
.l0ef9
call l0b0c
jr c,l0f0b
jr z,l0f06
ld bc,#0008
ldir
ret
.l0f06
ld bc,#0288
jr l0f0e
.l0f0b
ld bc,#04aa
.l0f0e
ld a,#08
.l0f10
push af
push hl
ld l,(hl)
ld h,b
.l0f14
xor a
.l0f15
rlc l
jr nc,l0f1a
or c
.l0f1a
rrc c
jr nc,l0f15
ld (de),a
inc de
djnz l0f14
ld b,h
pop hl
inc hl
pop af
dec a
jr nz,l0f10
ret
.l0f2a
ld c,a
call l0b6a
call l0b0c
ld b,#08
jr c,l0f6b
jr z,l0f42
.l0f37
ld a,(hl)
xor c
cpl
ld (de),a
inc de
call l0c1f
djnz l0f37
ret
.l0f42
push bc
push hl
push de
call l0f5a
call l0c05
call l0f5a
ld a,e
pop de
ld (de),a
inc de
pop hl
call l0c1f
pop bc
djnz l0f42
ret
.l0f5a
ld d,#88
ld b,#04
.l0f5e
ld a,(hl)
xor c
and d
jr nz,l0f64
scf
.l0f64
rl e
rrc d
djnz l0f5e
ret
.l0f6b
push bc
push hl
push de
ld b,#04
.l0f70
ld a,(hl)
xor c
and #aa
jr nz,l0f77
scf
.l0f77
rl e
ld a,(hl)
xor c
and #55
jr nz,l0f80
scf
.l0f80
rl e
call l0c05
djnz l0f70
ld a,e
pop de
ld (de),a
inc de
pop hl
call l0c1f
pop bc
djnz l0f6b
ret
call l0fad
call l0fc2
jr l0fa1
call l0fad
call l1016
.l0fa1
ld hl,(#b802)
ld a,l
ld (#b6a3),a
ld a,h
ld (#b6b3),a
ret
.l0fad
push hl
ld hl,(#b6a3)
ld (#b6a3),a
ld a,(#b6b3)
ld h,a
ld a,#ff
ld (#b6b3),a
ld (#b802),hl
pop hl
ret
.l0fc2
scf
call l103b
.l0fc6
rlc b
ld a,c
jr nc,l0fde
.l0fcb
dec e
jr nz,l0fd1
dec d
jr z,l0ffd
.l0fd1
rrc c
jr c,l0ffd
bit 7,b
jr z,l0ffd
or c
rlc b
jr l0fcb
.l0fde
dec e
jr nz,l0fe4
dec d
jr z,l0ff1
.l0fe4
rrc c
jr c,l0ff1
bit 7,b
jr nz,l0ff1
or c
rlc b
jr l0fde
.l0ff1
push bc
ld c,a
ld a,(#b6a4)
ld b,a
ld a,(#b6b4)
or a
jr l1004
.l0ffd
push bc
ld c,a
ld a,(#b6a3)
ld b,a
xor a
.l1004
call z,#bde8
pop bc
bit 7,c
call nz,l0c05
ld a,d
or e
jr nz,l0fc6
.l1011
ld a,b
ld (#b6b3),a
ret
.l1016
or a
call l103b
.l101a
rlc b
ld a,(#b6a3)
jr c,l102a
ld a,(#b6b4)
or a
jr nz,l1030
ld a,(#b6a4)
.l102a
push bc
ld b,a
call #bde8
pop bc
.l1030
call l0c39
dec e
jr nz,l101a
dec d
jr nz,l101a
jr l1011
.l103b
push hl
jr nc,l1040
ld h,d
ld l,e
.l1040
or a
sbc hl,bc
call l1939
inc h
inc l
ex (sp),hl
call l0baf
ld a,(#b6b3)
ld b,a
pop de
ret


;----kolory 34 bajty


.l1074
call l1084
xor a
ld (#b735),a
ld hl,#0001
call l1139
jp l109f
.l1084
ld hl,#108d
call l0ab4
jp l1464
rrca
call #c3bd
ld e,a
ld (de),a
jp l125f
jp l134b
jp l13be
jp l140a
.l109f
ld a,#08
ld de,#b6b6
.l10a4
ld hl,#b726
ld bc,#000e
ldir
dec a
jr nz,l10a4
ld (#b6b5),a
ret
.l10b3
ld a,(#b6b5)
ld c,a
ld b,#08
.l10b9
ld a,b
dec a
call l10e4
call #bdd0
call l12c0
ld (#b730),a
call l12ba
ld (#b72f),a
djnz l10b9
ld a,c
ret
.l10d1
ld c,a
ld b,#08
.l10d4
ld a,b
dec a
call l10e4
push bc
ld hl,(#b72f)
call l1139
pop bc
djnz l10d4
ld a,c
.l10e4
and #07
ld hl,#b6b5
cp (hl)
ret z
push bc
push de
ld c,(hl)
ld (hl),a
ld b,a
ld a,c
call l1126
call l111e
ld a,b
call l1126
ex de,hl
call l111e
ld a,c
pop de
pop bc
ret
ld a,(#b6b5)
push af
ld a,c
call l10e4
ld a,b
ld (#b6b5),a
call l1126
push de
ld a,c
call l1126
pop hl
call l111e
pop af
jr l10e4
.l111e
push bc
ld bc,#000e
ldir
pop bc
ret
.l1126
and #07
ld e,a
add a
add e
add a
add e
add a
add #b6
ld e,a
adc #b6
sub e
ld d,a
ld hl,#b726
ret
.l1139
ex de,hl
ld a,#83
ld (#b72e),a
ld a,d
call l12ab
ld a,e
call l12a6
.l1147
xor a
call l13a8
call l137b
ld hl,#0000
ld de,#7f7f
call l1208
jp l1459
dec a
ld hl,#b72a
add (hl)
ld hl,(#b726)
ld h,a
jr l1173
dec a
ld hl,#b729
add (hl)
ld hl,(#b726)
ld l,a
jr l1173
.l1170
call l1186
.l1173
call #bdd0
.l1176
ld (#b726),hl
jp #bdcd
ld hl,(#b726)
call l1193
ld a,(#b72d)
ret
.l1186
ld a,(#b729)
dec a
add l
ld l,a
ld a,(#b72a)
dec a
add h
ld h,a
ret
.l1193
ld a,(#b729)
sub l
cpl
inc a
inc a
ld l,a
ld a,(#b72a)
sub h
cpl
inc a
inc a
ld h,a
ret
.l11a4
call #bdd0
.l11a7
ld hl,(#b726)
call l11d6
ld (#b726),hl
ret c
push hl
ld hl,#b72d
ld a,b
add a
inc a
add (hl)
ld (hl),a
call l1252
ld a,(#b730)
push af
call c,l0e44
pop af
call nc,l0e00
pop hl
ret
.l11ca
call l1186
call l11d6
push af
call l1193
pop af
ret
.l11d6
ld a,(#b72c)
cp h
jp p,l11e2
ld a,(#b72a)
ld h,a
inc l
.l11e2
ld a,(#b72a)
dec a
cp h
jp m,l11ef
ld a,(#b72c)
ld h,a
dec l
.l11ef
ld a,(#b729)
dec a
cp l
jp p,l1202
ld a,(#b72b)
cp l
scf
ret p
ld l,a
ld b,#ff
.l1200
or a
ret
.l1202
inc a
ld l,a
ld b,#00
or a
ret
.l1208
call l0b5d
ld a,h
call l1240
ld h,a
ld a,d
call l1240
ld d,a
cp h
jr nc,l121a
ld d,h
ld h,a
.l121a
ld a,l
call l1249
ld l,a
ld a,e
call l1249
ld e,a
cp l
jr nc,l1229
ld e,l
ld l,a
.l1229
ld (#b729),hl
ld (#b72b),de
ld a,h
or l
jr nz,l123a
ld a,d
xor b
jr nz,l123a
ld a,e
xor c
.l123a
ld (#b728),a
jp l1173
.l1240
or a
jp p,l1245
xor a
.l1245
cp b
ret c
ld a,b
ret
.l1249
or a
jp p,l124e
xor a
.l124e
cp c
ret c
ld a,c
ret
.l1252
ld hl,(#b729)
ld de,(#b72b)
ld a,(#b728)
add #ff
ret
.l125f
ld a,(#b72e)
and #03
ret nz
.l1265
push bc
push de
push hl
call l11a7
ld bc,(#b72f)
call l0de5
pop hl
pop de
pop bc
ret
push af
ld a,#fd
call l1288
pop af
ret
push af
ld a,#02
call l1299
pop af
ret
.l1286
ld a,#fe
.l1288
push af
call #bdd0
pop af
push hl
ld hl,#b72e
and (hl)
ld (hl),a
pop hl
jp #bdcd
.l1297
ld a,#01
.l1299
push af
call #bdd0
.l129d
pop af
push hl
ld hl,#b72e
or (hl)
ld (hl),a
pop hl
ret
.l12a6
ld hl,#b72f
jr l12ae
.l12ab
ld hl,#b730
.l12ae
push af
call #bdd0
pop af
call l0c8e
ld (hl),a
.l12b7
jp #bdcd
.l12ba
ld a,(#b72f)
jp l0ca7
.l12c0
ld a,(#b730)
jp l0ca7
.l12c6
call #bdd0
ld hl,(#b72f)
ld a,h
ld h,l
ld l,a
ld (#b72f),hl
jr l12b7
.l12d4
push de
ld e,a
call l132b
jr nc,l12e4
ld d,a
ld a,e
sub d
ccf
jr nc,l12e4
ld e,a
jr l12e7
.l12e4
ld hl,#3800
.l12e7
push af
ld d,#00
ex de,hl
add hl,hl
add hl,hl
add hl,hl
add hl,de
pop af
pop de
ret
.l12f2
ex de,hl
call l12d4
ret nc
ex de,hl
.l12f8
ld bc,#0008
ldir
ret
push hl
ld a,d
or a
ld d,#00
jr nz,l131e
dec d
push de
ld c,e
ex de,hl
.l1309
ld a,c
call l12d4
ld a,h
xor d
jr nz,l1315
ld a,l
xor e
jr z,l131d
.l1315
push bc
call l12f8
pop bc
inc c
jr nz,l1309
.l131d
pop de
.l131e
call l132b
ld (#b734),de
pop de
ld (#b736),de
ret
.l132b
ld hl,(#b734)
ld a,h
rrca
ld a,l
ld hl,(#b736)
ret
.l1335
ld b,a
ld a,(#b72e)
rlca
ret c
push bc
call l11a4
inc h
ld (#b726),hl
dec h
pop af
call #bdd3
jp #bdcd
.l134b
push hl
call l12d4
ld de,#b738
push de
call l0ef9
pop de
pop hl
call l0b6a
ld c,#08
.l135d
push bc
push hl
.l135f
push bc
push de
ex de,hl
ld c,(hl)
call l1377
call l0c05
pop de
inc de
pop bc
djnz l135f
pop hl
call l0c1f
pop bc
dec c
jr nz,l135d
ret
.l1377
ld hl,(#b731)
jp (hl)
.l137b
ld hl,#1392
or a
jr z,l1384
ld hl,#13a0
.l1384
ld (#b731),hl
ret
ld hl,(#b731)
ld de,#ec6e
add hl,de
ld a,h
or l
ret
ld hl,(#b72f)
ld a,c
cpl
and h
ld b,a
ld a,c
and l
or b
ld c,#ff
jr l13a3
ld a,(#b72f)
.l13a3
ld b,a
ex de,hl
jp l0c74
.l13a8
ld (#b733),a
ret
.l13ac
push hl
push de
push bc
call l11a4
call #bdd6
push af
call #bdcd
pop af
pop bc
pop de
pop hl
ret
.l13be
ld a,(#b730)
ld de,#b738
push hl
push de
call l0f2a
pop de
push de
ld b,#08
.l13cd
ld a,(de)
cpl
ld (de),a
inc de
djnz l13cd
call l13e1
pop de
pop hl
jr nc,l13db
ret nz
.l13db
ld a,(#b72f)
call l0f2a
.l13e1
ld c,#00
.l13e3
ld a,c
call l12d4
ld de,#b738
ld b,#08
.l13ec
ld a,(de)
cp (hl)
jr nz,l13f9
inc hl
inc de
djnz l13ec
ld a,c
cp #8f
scf
ret
.l13f9
inc c
jr nz,l13e3
xor a
ret
.l13fe
push af
push bc
push de
push hl
call #bdd9
pop hl
pop de
pop bc
pop af
ret
.l140a
ld c,a
ld a,(#b733)
or a
ld a,c
jp nz,l1940
ld hl,#b758
ld b,(hl)
ld a,b
cp #0a
jr nc,l144d
or a
jr nz,l1425
ld a,c
cp #20
jp nc,l1335
.l1425
inc b
ld (hl),b
ld e,b
ld d,#00
add hl,de
ld (hl),c
ld a,(#b759)
ld e,a
ld hl,#b763
add hl,de
add hl,de
add hl,de
ld a,(hl)
and #0f
cp b
ret nc
ld a,(#b72e)
and (hl)
rlca
jr c,l144d
inc hl
ld e,(hl)
inc hl
ld d,(hl)
ld hl,#b759
ld a,c
call #0016
.l144d
xor a
ld (#b758),a
ret
.l1452
ld a,#81
call l1299
jr l144d
.l1459
ld a,#7e
call l1288
jr l144d
ld a,(#b72e)
ret
.l1464
xor a
ld (#b758),a
ld hl,#1474
ld de,#b763
ld bc,#0060
ldir
ret


;nop


.l147f
call l1265
call l13ac
push af
ex de,hl
call l1170
ld hl,(#b116)
inc h
call l11ca
jr nc,l1496
ld (#b116),hl
.l1496
call #2e4a
jp #2e99




;<------------------------ z BDD0  i  BDCD
.l149c
ex (sp),hl
push af


ld a,#12
cp d
jr nz,l14cf
ld a,#65
cp e
jr nz,l14cf
ld de,l1265 ;<----------------- DE,#1265 !!!!!!!!


.l14cf


bit 7,h
jp nz,l06a2


ld a,#12
cp h
jr nz,l14aa
ld a,#9d
cp l
jr nz,l14aa
ld hl,l129d
.l14aa
ld a,#11
cp h
jr nz,l14b6
ld a,#76
cp l
jr nz,l14b6
ld hl,l1176
.l14b6
ld a,#2e
cp h
jr nz,l14c3
ld a,#7f
cp l
jr nz,l14c3
ld hl,l147f
.l14c3


jp l0688   ;->>>>>>> ciag dalszy w 0688




nop
nop
ld hl,#b763
ret
add a
nop
nop
ld e,d
nop
nop
dec bc
inc d
nop
.l14e1
push ix
ld hl,#14d8
call #2114
pop ix
.l14eb
ret
.l14ec
rrca
sbc a
jp l137b
.l14f1
inc hl
ld a,(hl)
inc hl
ld b,(hl)
inc hl
ld c,(hl)
jp l0cf2
.l14fa
inc hl
ld b,(hl)
inc hl
ld c,(hl)
jp l0cf7
.l1501
inc hl
ld d,(hl)
inc hl
ld a,(hl)
inc hl
ld e,(hl)
inc hl
ld l,(hl)
ld h,a
jp l1208
.l150d
inc hl
ld a,(hl)
inc hl
jp l12f2
.l1513
call l11a4
jp #bdcd
.l1519
ld de,#ff00
jr l152b
.l151e
ld de,#0100
jr l152b
.l1523
ld de,#0001
jr l152b
.l1528
ld de,#00ff
.l152b
push de
call l11a4
pop de
ld a,l
add e
ld l,a
ld a,h
add d
.l1535
ld h,a
jp l1176
.l1539
ld hl,(#b729)
jp l1173
.l153f
call l11a4
ld a,(#b72a)
jr l1535
.l1547
inc hl
ld d,(hl)
inc hl
ld e,(hl)
ex de,hl
jp l1170
.l154f
call #bdd0
.l1552
ld hl,(#b729)
ld (#b726),hl
ld de,(#b72b)
jr l15a2
.l155e
call l11a4
ld d,h
ld e,l
jr l15a2
.l1565
call l158f
ld hl,(#b729)
ld de,(#b72b)
ld a,(#b726)
ld l,a
inc l
cp e
ret nc
jr l1589
.l1578
call l1599
ld hl,(#b729)
ld a,(#b72c)
ld d,a
ld a,(#b726)
dec a
ld e,a
cp l
ret c
.l1589
ld a,(#b730)
jp l0db9
.l158f
call l11a4
ld e,l
ld a,(#b72c)
ld d,a
jr l15a2
.l1599
call l11a4
ex de,hl
ld l,e
ld a,(#b72a)
ld h,a
.l15a2
call l1589
jp #bdcd
.l15a8
call l15d7
ld hl,#0001
.l15ae
ld a,h
call l176e
ld a,l
call l1767
ld hl,#0000
ld d,h
ld e,l
call l160e
ld de,#8000
ld hl,#7fff
push hl
push de
call l16a5
pop hl
pop de
jp l16ea
.l15ce
call l177a
ld h,a
call l1775
ld l,a
ret
.l15d7
call l15f0
ld hl,#15e0
jp l0ab4
add hl,bc
call c,#c3bd
add (hl)
rla
jp l179a
jp l17b4
xor a
call l0c55
.l15f0
xor a
call l19d5
cpl
call l17b0
jp l17ac
call l165d
.l15fe
ld (#b697),de
ld (#b699),hl
ret
.l1606
ld de,(#b697)
ld hl,(#b699)
ret
.l160e
ld (#b693),de
ld (#b695),hl
.l1615
ld de,#0000
ld h,d
ld l,e
jr l15fe
ld de,(#b693)
ld hl,(#b695)
ret
.l1624
call l1606
.l1627
call l15fe
push hl
call l0b0c
neg
sbc #fd
ld h,#00
ld l,a
bit 7,d
jr z,l163c
ex de,hl
add hl,de
ex de,hl
.l163c
cpl
and e
ld e,a
ld a,l
ld hl,(#b693)
add hl,de
rrca
call c,l16e5
rrca
call c,l16e5
pop de
push hl
ld a,d
rlca
jr nc,l1653
inc de
.l1653
res 0,e
ld hl,(#b695)
add hl,de
pop de
jp l16e5
.l165d
push hl
ld hl,(#b697)
add hl,de
pop de
push hl
ld hl,(#b699)
add hl,de
pop de
ret
.l166a
ld hl,(#b69b)
scf
sbc hl,de
jp p,l167e
ld hl,(#b69d)
or a
sbc hl,de
scf
ret p
.l167b
or #ff
ret
.l167e
xor a
ret
.l1680
ld hl,(#b69f)
or a
sbc hl,de
jp m,l167b
ld hl,(#b6a1)
scf
sbc hl,de
jp p,l167e
scf
ret
.l1694
call l1627
.l1697
push hl
call l166a
pop hl
ret nc
push de
ex de,hl
call l1680
ex de,hl
pop de
ret
.l16a5
push hl
call l16d1
pop de
push hl
call l16d1
pop de
ld a,e
sub l
ld a,d
sbc h
jr c,l16b6
ex de,hl
.l16b6
ld a,e
and #f8
ld e,a
ld a,l
or #07
ld l,a
call l0b0c
dec a
call m,l16e1
dec a
call m,l16e1
ld (#b69b),de
ld (#b69d),hl
ret
.l16d1
ld a,d
or a
ld hl,#0000
ret m
.lGrafResOriginX
GrafResOriginX equ lGrafResOriginX
ld hl,width*8-1            ; width graficzna #027f=640-1
ld a,e
sub l
ld a,d
sbc h
ret nc
ex de,hl
ret
.l16e1
sra d
rr e
.l16e5
sra h
rr l
ret
.l16ea
push hl
call l1703
pop de
push hl
call l1703
pop de
ld a,l
sub e
ld a,h
sbc d
jr c,l16fb
ex de,hl
.l16fb
ld (#b69f),de
ld (#b6a1),hl
ret
.l1703
ld a,d
or a
ld hl,#0000
ret m
srl d
rr e
.lGrafResOriginY
GrafResOriginY equ lGrafResOriginY+1
ld hl,hight*8-1 ;----hight. garficzna fizyczna org.199 #C7
ld a,e
sub l
ld a,d
sbc h
ret nc
ex de,hl
ret
.l1717
ld de,(#b69b)
ld hl,(#b69d)
call l0b0c
dec a
call m,l1727
dec a
ret p
.l1727
add hl,hl
inc hl
ex de,hl
add hl,hl
ex de,hl
ret
ld de,(#b69f)
ld hl,(#b6a1)
jr l1727
call l1717
or a
sbc hl,de
inc hl
call l16e5
call l16e5
srl l
ld b,l
ld de,(#b6a1)
ld hl,(#b69f)
push hl
or a
sbc hl,de
inc hl
ld c,l
ld de,(#b69b)
pop hl
push bc
call l0baf
pop de
ld a,(#b6a4)
ld c,a
call l0dbd
jp l1615
.l1767
call l0c8e
ld (#b6a3),a
ret
.l176e
call l0c8e
ld (#b6a4),a
ret
.l1775
ld a,(#b6a3)
jr l177d
.l177a
ld a,(#b6a4)
.l177d
jp l0ca7
call l165d
jp #bddc
.l1786
call l1694
ret nc
call l0baf
ld a,(#b6a3)
ld b,a
jp #bde8
call l165d
jp #bddf
.l179a
call l1694
jp nc,l177a
call l0baf
jp #bde5
call l165d
jp #bde2
.l17ac
ld (#b6b3),a
ret
.l17b0
ld (#b6b2),a
ret
.l17b4
push hl
call l188b
pop hl
call l1627
push hl
ld hl,(#b6a5)
or a
sbc hl,de
ld a,h
ld (#b6ad),a
call m,l1939
pop de
push hl
ld hl,(#b6a7)
or a
sbc hl,de
ld a,h
ld (#b6ae),a
call m,l1939
pop de
or a
sbc hl,de
add hl,de
sbc a
ld (#b6af),a
ld a,(#b6ae)
jr z,l17eb
ex de,hl
ld a,(#b6ad)
.l17eb
push af
ld (#b6ab),de
ld b,h
ld c,l
ld a,(#b6b2)
or a
jr z,l17f9
inc bc
.l17f9
ld (#b6b0),bc
call l1939
push hl
add hl,de
ld (#b6a9),hl
pop hl
sra h
rr l
pop af
rlca
jr c,l1820
push hl
call l188b
ld hl,(#b6ad)
ld a,h
cpl
ld h,a
ld a,l
cpl
ld l,a
ld (#b6ad),hl
jr l1832
.l1820
ld a,(#b6b2)
or a
jr nz,l1833
add hl,de
push hl
ld a,(#b6af)
rlca
call c,l18da
call nc,l1928
.l1832
pop hl
.l1833
ld a,d
or e
jp z,l1898
push ix
ld bc,#0000
push bc
pop ix
.l1840
push ix
pop de
or a
adc hl,de
ld de,(#b6ab)
jp p,l1853
.l184d
inc bc
add ix,de
add hl,de
jr nc,l184d
.l1853
xor a
sub e
ld e,a
sbc a
sub d
ld d,a
.l1859
add hl,de
jr nc,l1861
add ix,de
dec bc
jr l1859
.l1861
ld de,(#b6a9)
add hl,de
push bc
push hl
ld hl,(#b6b0)
or a
sbc hl,bc
jr nc,l1876
add hl,bc
ld b,h
ld c,l
ld hl,#0000
.l1876
ld (#b6b0),hl
call l1898
pop hl
pop bc
jr nc,l1888
ld de,(#b6b0)
ld a,d
or e
jr nz,l1840
.l1888
pop ix
ret
.l188b
push de
call l1624
ld (#b6a5),de
ld (#b6a7),hl
pop de
ret
.l1898
ld a,(#b6af)
rlca
jr c,l18eb
ld a,b
or c
jr z,l18da
ld hl,(#b6a7)
add hl,bc
dec hl
ld b,h
ld c,l
ex de,hl
call l1680
ld hl,(#b6a7)
ex de,hl
inc hl
ld (#b6a7),hl
jr c,l18bd
jr z,l18da
ld bc,(#b69f)
.l18bd
call l1680
jr c,l18c7
ret nz
ld de,(#b6a1)
.l18c7
push de
ld de,(#b6a5)
call l166a
pop hl
jr c,l18d7
ld hl,#b6ad
xor (hl)
ret p
.l18d7
call c,l1016
.l18da
ld hl,(#b6a5)
ld a,(#b6ad)
rlca
inc hl
jr c,l18e6
dec hl
dec hl
.l18e6
ld (#b6a5),hl
scf
ret
.l18eb
ld a,b
or c
jr z,l1928
ld hl,(#b6a5)
add hl,bc
dec hl
ld b,h
ld c,l
ex de,hl
call l166a
ld hl,(#b6a5)
ex de,hl
inc hl
ld (#b6a5),hl
jr c,l190a
jr z,l1928
ld bc,(#b69d)
.l190a
call l166a
jr c,l1914
ret nz
ld de,(#b69b)
.l1914
push de
ld de,(#b6a7)
call l1680
pop hl
jr c,l1924
ld hl,#b6ae
xor (hl)
ret p
.l1924
ex de,hl
call c,l0fc2
.l1928
ld hl,(#b6a7)
ld a,(#b6ae)
rlca
inc hl
jr c,l1934
dec hl
dec hl
.l1934
ld (#b6a7),hl
scf
ret
.l1939
xor a
sub l
ld l,a
sbc a
sub h
ld h,a
ret
.l1940
push ix
call l12d4
push hl
pop ix
call l1624
call l1697
jr nc,l199b
push hl
push de
ld bc,#0007
ex de,hl
add hl,bc
ex de,hl
or a
sbc hl,bc
call l1697
pop de
pop hl
jr nc,l199b
call l0baf
ld d,#08
.l1967
push hl
ld e,(ix+#00)
scf
rl e
.l196e
call l19c4
rrc c
call c,l0c05
sla e
jr nz,l196e
pop hl
call l0c1f
inc ix
dec d
jr nz,l1967
.l1983
pop ix
call l1606
ex de,hl
call l0b0c
ld bc,#0008
jr z,l1995
jr nc,l1996
add hl,bc
add hl,bc
.l1995
add hl,bc
.l1996
add hl,bc
ex de,hl
jp l15fe
.l199b
ld b,#08
.l199d
push bc
push de
ld a,(ix+#00)
scf
adc a
.l19a4
push hl
push de
push af
call l1697
jr nc,l19b4
call l0baf
pop af
push af
call l19c4
.l19b4
pop af
pop de
pop hl
inc de
add a
jr nz,l19a4
pop de
dec hl
inc ix
pop bc
djnz l199d
jr l1983
.l19c4
ld a,(#b6a3)
jr c,l19d1
ld a,(#b6b4)
or a
ret nz
ld a,(#b6a4)
.l19d1
ld b,a
jp #bde8
.l19d5
ld (#b6b4),a
ret
.l19d9
ld (#b6a5),hl
ld (hl),#01
dec de
ld (#b6a7),de
call l0c8e
ld (#b6aa),a
call l1624
call l1697
call c,l1b42
ret nc
push hl
call l1ae7
ex (sp),hl
call l1b15
pop bc
ld a,#ff
ld (#b6a9),a
push hl
push de
push bc
call l1a0b
pop bc
pop de
pop hl
xor a
.l1a0b
ld (#b6ab),a
.l1a0e
call l1ade
.l1a11
call l1697
call c,l1a50
jr c,l1a0e
ld hl,(#b6a5)
rst #20
cp #01
jr z,l1a4b
ld (#b6ab),a
ex de,hl
ld hl,(#b6a7)
ld bc,#0007
add hl,bc
ld (#b6a7),hl
ex de,hl
dec hl
rst #20
ld b,a
dec hl
rst #20
ld c,a
dec hl
rst #20
ld d,a
dec hl
rst #20
ld e,a
push de
dec hl
rst #20
ld d,a
dec hl
rst #20
ld e,a
dec hl
ld (#b6a5),hl
ex de,hl
pop de
jr l1a11
.l1a4b
ld a,(#b6a9)
rrca
ret
.l1a50
ld (#b6ac),bc
call l1b42
jr c,l1a62
call l1af1
ret nc
ld (#b6ae),hl
jr l1a73
.l1a62
push hl
call l1b15
ld (#b6ae),hl
pop bc
ld a,l
sub c
ld a,h
sbc b
call c,l1acb
ld h,b
ld l,c
.l1a73
call l1ae7
ld (#b6b0),hl
ld bc,(#b6ac)
or a
sbc hl,bc
add hl,bc
jr z,l1a94
jr nc,l1a8d
call l1af1
call c,l1a9d
jr l1a94
.l1a8d
push hl
ld h,b
ld l,c
pop bc
call l1acb
.l1a94
ld hl,(#b6ae)
ld bc,(#b6b0)
scf
ret
.l1a9d
push de
push hl
ld hl,(#b6a7)
ld de,#fff9
add hl,de
pop de
jr nc,l1ac5
ld (#b6a7),hl
ld hl,(#b6a5)
inc hl
ld (hl),e
inc hl
ld (hl),d
inc hl
pop de
ld (hl),e
inc hl
ld (hl),d
inc hl
ld (hl),c
inc hl
ld (hl),b
inc hl
ld a,(#b6ab)
ld (hl),a
ld (#b6a5),hl
ret
.l1ac5
xor a
ld (#b6a9),a
pop de
ret
.l1acb
call l1ad7
call l1b42
call nc,l1af1
call c,l1a9d
.l1ad7
ld a,(#b6ab)
cpl
ld (#b6ab),a
.l1ade
dec de
ld a,(#b6ab)
or a
ret z
inc de
inc de
ret
.l1ae7
xor a
ld bc,(#b69f)
call l1af3
dec hl
ret
.l1af1
ld a,#ff
.l1af3
push bc
push de
push hl
push af
call l1b4f
pop af
ld b,a
.l1afc
call l1b34
inc b
djnz l1b06
jr nc,l1b4b
xor (hl)
ld (hl),a
.l1b06
jr c,l1b4b
ex (sp),hl
inc hl
ex (sp),hl
sbc hl,de
jr z,l1b4b
add hl,de
call l0c39
jr l1afc
.l1b15
push bc
push de
push hl
ld bc,(#b6a1)
call l1b4f
.l1b1f
or a
sbc hl,de
jr z,l1b4b
add hl,de
call l0c1f
call l1b34
jr z,l1b4b
xor (hl)
ld (hl),a
ex (sp),hl
dec hl
ex (sp),hl
jr l1b1f
.l1b34
ld a,(#b6a3)
xor (hl)
and c
ret z
ld a,(#b6aa)
xor (hl)
and c
ret z
scf
ret
.l1b42
push bc
push de
push hl
call l0baf
call l1b34
.l1b4b
pop hl
pop de
pop bc
ret
.l1b4f
push bc
push de
call l0baf
pop de
ex (sp),hl
call l0baf
ex de,hl
pop hl
ret
.l1b5c
ld hl,#1e02
call l1df6
xor a
ld (#b655),a
ld h,a
ld l,a
ld (#b631),hl
ld bc,#ffb0
ld de,#b5d6
ld hl,#b692
ld a,#04
.l1b76
ex de,hl
add hl,bc
ex de,hl
ld (hl),d
dec hl
ld (hl),e
dec hl
dec a
jr nz,l1b76
ld hl,#1eef
ld bc,#00fa
ldir
ld b,#0a
ld de,#b635
ld hl,#b63f
xor a
.l1b91
ld (de),a
inc de
ld (hl),#ff
inc hl
djnz l1b91
.l1b98
call l1e75
call l1bf8
ld de,#b590
ld hl,#0098
call l1c0a
ld hl,#1bb3
call l0ab4
call l0ab4
jp l1e0b
inc bc
xor #bd
jp l1db8
inc bc
call p,#c3bd
ld b,b
dec e
.l1bbf
call l1bc5
jr nc,l1bbf
ret
.l1bc5
push hl
ld hl,#b62a
ld a,(hl)
ld (hl),#ff
cp (hl)
jr c,l1bf6
ld hl,(#b628)
ld a,h
or a
jr nz,l1be7
.l1bd6
call l1ce1
jr nc,l1bf6
cp #80
jr c,l1bf6
cp #a0
ccf
jr c,l1bf6
ld h,a
ld l,#00
.l1be7
push de
call l1cb3
jr c,l1bef
ld h,#00
.l1bef
inc l
ld (#b628),hl
pop de
jr nc,l1bd6
.l1bf6
pop hl
ret
.l1bf8
ld a,#ff
ld (#b62a),a
ret
.l1bfe
call l1bc5
jr c,l1bfe
ret
call l1c0a
ccf
ei
ret
.l1c0a
di
ld a,l
sub #31
ld a,h
sbc #00
ret c
add hl,de
ld (#b62d),hl
ex de,hl
ld (#b62b),hl
ld bc,#0a30
.l1c1d
ld (hl),#01
inc hl
ld (hl),c
inc hl
inc c
djnz l1c1d
ex de,hl
ld hl,#1c3c
ld c,#0a
ldir
ex de,hl
ld b,#13
xor a
.l1c31
ld (hl),a
inc hl
djnz l1c31
ld (#b62f),hl
ld (#b629),a
ret
ld bc,#012e
dec c
dec b
ld d,d
ld d,l
ld c,(hl)
ld (#780d),hl
call l1cc3
ret nc
push bc
push de
push hl
call l1c6a
ccf
pop hl
pop de
pop bc
ret nc
dec de
ld a,c
inc c
.l1c59
ld (de),a
inc de
rst #20
inc hl
dec c
jr nz,l1c59
ld hl,#b629
ld a,b
xor (hl)
jr nz,l1c68
ld (hl),a
.l1c68
scf
ret
.l1c6a
ld b,#00
ld h,b
ld l,a
ld a,c
sub l
ret z
jr nc,l1c82
ld a,l
ld l,c
ld c,a
add hl,de
ex de,hl
add hl,bc
call l1ca7
jr z,l1ca1
ldir
jr l1ca1
.l1c82
ld c,a
add hl,de
push hl
ld hl,(#b62f)
add hl,bc
ex de,hl
ld hl,(#b62d)
ld a,l
sub e
ld a,h
sbc d
pop hl
ret c
call l1ca7
ld hl,(#b62f)
jr z,l1ca1
push de
dec de
dec hl
lddr
pop de
.l1ca1
ld (#b62f),de
or a
ret
.l1ca7
ld a,(#b62f)
sub l
ld c,a
ld a,(#b630)
sbc h
ld b,a
or c
ret
.l1cb3
call l1cc3
ret nc
cp l
ret z
ccf
ret nc
push hl
ld h,#00
add hl,de
ld a,(hl)
pop hl
scf
ret
.l1cc3
and #7f
cp #20
ret nc
push hl
ld hl,(#b62b)
ld de,#0000
inc a
.l1cd0
add hl,de
ld e,(hl)
inc hl
dec a
jr nz,l1cd0
ld a,e
ex de,hl
pop hl
scf
ret
.l1cdb
call l1ce1
jr nc,l1cdb
ret
.l1ce1
push hl
push bc
.l1ce3
call l1e9d
jr nc,l1d22
ld a,c
cp #ef
jr z,l1d21
and #0f
add a
add a
add a
dec a
.l1cf3
inc a
rrc b
jr nc,l1cf3
call l1d25
ld hl,#b632
bit 7,(hl)
jr z,l1d0c
cp #61
jr c,l1d0c
cp #7b
jr nc,l1d0c
add #e0
.l1d0c
cp #ff
jr z,l1ce3
cp #fe
ld hl,#b631
jr z,l1d1c
cp #fd
inc hl
jr nz,l1d21
.l1d1c
ld a,(hl)
cpl
ld (hl),a
jr l1ce3
.l1d21
scf
.l1d22
pop bc
pop hl
ret
.l1d25
rl c
jp c,l1ece
ld b,a
ld a,(#b631)
or c
and #40
ld a,b
jp nz,l1ec9
jp l1ec4
ld hl,(#b631)
ret
ld (#b631),hl
ret
.l1d40
ld de,#b649
ld hl,#b63f
call l0883
ld a,(#b64b)
and #a0
ld c,a
ld hl,#b637
or (hl)
ld (hl),a
ld hl,#b649
ld de,#b635
ld b,#00
.l1d5c
ld a,(de)
xor (hl)
and (hl)
call nz,l1dd1
ld a,(hl)
ld (de),a
inc hl
inc de
inc c
ld a,c
and #0f
cp #0a
jr nz,l1d5c
ld a,c
and #a0
bit 6,c
ld c,a
call nz,#bdee
ld a,b
or a
ret nz
ld hl,#b653
dec (hl)
ret nz
ld hl,(#b654)
ex de,hl
ld b,d
ld d,#00
ld hl,#b635
add hl,de
ld a,(hl)
ld hl,(#b691)
add hl,de
and (hl)
and b
ret z
ld hl,#b653
inc (hl)
ld a,(#b68a)
or a
ret nz
ld a,c
or e
ld c,a
ld a,(#b633)
.l1da1
ld (#b653),a
call l1e86
ld a,c
and #0f
ld l,a
ld h,b
ld (#b654),hl
cp #08
ret nz
bit 4,b
ret nz
set 6,c
ret
.l1db8
ld hl,#b63d
bit 2,(hl)
ret z
ld a,c
xor #a0
jr nz,l1e19
push bc
inc hl
ld b,#0a
.l1dc7
adc (hl)
dec hl
djnz l1dc7
pop bc
cp #a4
jr nz,l1e19
rst #00
.l1dd1
push hl
push de
.l1dd3
ld e,a
cpl
inc a
and e
ld b,a
ld a,(#b634)
call l1da1
ld a,b
xor e
jr nz,l1dd3
pop de
pop hl
ret
ld a,(#b63b)
and #7f
ld l,a
ld a,(#b63e)
and #7f
ld h,a
ret
ld hl,(#b633)
ret
.l1df6
ld (#b633),hl
ret
call l1e0b
ld hl,#b657
ld b,#40
call l01d2
ld a,#ff
ld (#b656),a
ret
.l1e0b
push bc
push de
ld hl,#b656
ld (hl),#00
inc hl
call l0284
pop de
pop bc
ret
.l1e19
ld hl,#b656
ld a,(hl)
ld (hl),#00
cp (hl)
ret z
push bc
push de
inc hl
call l01e2
ld c,#ef
call l1e86
pop de
pop bc
ret
ld hl,(#b691)
jr l1e50
cp #50
ret nc
ld hl,(#b691)
call l1e55
cpl
ld c,a
ld a,(hl)
xor b
and c
xor b
ld (hl),a
ret
push af
ld a,(#b637)
and #a0
ld c,a
pop af
ld hl,#b635
.l1e50
call l1e55
and (hl)
ret
.l1e55
push de
push af
and #f8
rrca
rrca
rrca
ld e,a
ld d,#00
add hl,de
pop af
push hl
ld hl,#1e6d
and #07
ld e,a
add hl,de
ld a,(hl)
pop hl
pop de
ret
ld bc,#0402
ex af,af'
djnz l1e93
ld b,b
add b
.l1e75
di
ld hl,#b686
ld (hl),#15
inc hl
xor a
ld (hl),a
inc hl
ld (hl),#01
inc hl
ld (hl),a
inc hl
ld (hl),a
ret
.l1e86
ld hl,#b686
or a
dec (hl)
jr z,l1e9b
call l1eb4
ld (hl),c
inc hl
ld (hl),b
.l1e93
ld hl,#b68a
inc (hl)
ld hl,#b688
scf
.l1e9b
inc (hl)
ret
.l1e9d
ld hl,#b688
or a
dec (hl)
jr z,l1eb2
call l1eb4
ld c,(hl)
inc hl
ld b,(hl)
ld hl,#b68a
dec (hl)
ld hl,#b686
scf
.l1eb2
inc (hl)
ret
.l1eb4
inc hl
inc (hl)
ld a,(hl)
cp #14
jr nz,l1ebd
xor a
ld (hl),a
.l1ebd
add a
add #5e
ld l,a
ld h,#b6
ret
.l1ec4
ld hl,(#b68b)
jr l1ed1
.l1ec9
ld hl,(#b68d)
jr l1ed1
.l1ece
ld hl,(#b68f)
.l1ed1
add l
ld l,a
adc h
sub l
ld h,a
ld a,(hl)
ret
ld hl,(#b68b)
jr l1ee5
ld hl,(#b68d)
jr l1ee5
ld hl,(#b68f)
.l1ee5
cp #50
ret nc
add l
ld l,a
adc h
sub l
ld h,a
ld (hl),b
ret
.l1eef

org #b992
.lb992
call l06b0
nop

org #bdcd
.lbdcd
jp l149c
.lbdd0
jp l149c
.lbdd3
CPC 6128, Whole 6128 and Only 6128, with .....
NewPAL v3 for use all 128kB RAM by CRTC as VRAM
TYPICAL :) TV Funai 22FL532/10 with VGA-RGB-in.

lmimmfn

interesting, is it possible to have half screen Mode 0 so the pixels are essentially mode 1 size?
6128 for the win!!!

McArti0

unfortunately no, the memory read frequency is constans. 16MHz per bit, 2MHz per byte.
CPC 6128, Whole 6128 and Only 6128, with .....
NewPAL v3 for use all 128kB RAM by CRTC as VRAM
TYPICAL :) TV Funai 22FL532/10 with VGA-RGB-in.

TotO

Nice done. The 256x256 screen is the best alternative for a 16K page in MODE 1.

An idea is to define a 32K screen with 256x256 resolution in MODE 0 and put a 24MHz master clock to display a full screen with 16 colours square pixels, 512x256 with 4 coulours and 1024x256 with 2 colours.  ;D
"You make one mistake in your life and the internet will never let you live it down" (Keith Goodyer)

McArti0

CPC 6128, Whole 6128 and Only 6128, with .....
NewPAL v3 for use all 128kB RAM by CRTC as VRAM
TYPICAL :) TV Funai 22FL532/10 with VGA-RGB-in.

McArti0

Quote from: lmimmfn on 16:06, 25 January 22
is it possible to have half screen Mode 0 so the pixels are essentially mode 1 size?
maybe this way? 17 line characters.
CPC 6128, Whole 6128 and Only 6128, with .....
NewPAL v3 for use all 128kB RAM by CRTC as VRAM
TYPICAL :) TV Funai 22FL532/10 with VGA-RGB-in.

lmimmfn

Im not sure i understand this last pic  :)
Maybe i didnt describe properly, ToTO did a better job of explaining, essentially mode 0 where pixel size is the same as mode 1 but with double the resolution, so it looks like 16 colour mode 1 without raster tricks.

Can you post the same screens above in mode 0, like has been said square mode 0 pixels are a dream but interested in seeing what the reduction looks like.


Im curious why this involves low rom usage or is that a  separate achievement?
6128 for the win!!!

lmimmfn

Quote from: TotO on 16:37, 25 January 22
Nice done. The 256x256 screen is the best alternative for a 16K page in MODE 1.

An idea is to define a 32K screen with 256x256 resolution in MODE 0 and put a 24MHz master clock to display a full screen with 16 colours square pixels, 512x256 with 4 coulours and 1024x256 with 2 colours.  ;D
256x256 mode 0 square pixels(or rather 4:3 aspect ratio) would be an absolute dream on the CPC
6128 for the win!!!

McArti0

Quote from: lmimmfn on 21:21, 25 January 22
Im not sure i understand this last pic  :)

Can you post the same screens above in mode 0, like has been said square mode 0 pixels are a dream but interested in seeing what the reduction looks like.

This is simple example how change hight factor x2 by typing OUT&BC00,0:OUT&BD00,129.  OUT&BC00,7:OUT&BD00,27 little down screen. You still have to set V-position of monitor.


Quote from: lmimmfn on 21:21, 25 January 22Im curious why this involves low rom usage or is that a  separate achievement?

YES YES YES! i other resolution work almost whole Basic and editor. SHIFT+ARROWS , COPY, Locate X,Y, WINDOW, DRAW, PLOT, DRAWR, FILL and hardware scroll. This program ovs18.bas on dsk is very usefull for write other program.
CPC 6128, Whole 6128 and Only 6128, with .....
NewPAL v3 for use all 128kB RAM by CRTC as VRAM
TYPICAL :) TV Funai 22FL532/10 with VGA-RGB-in.

lmimmfn

Quote from: McArti0 on 00:14, 26 January 22
This is simple example how change hight factor x2 by typing OUT&BC00,0:OUT&BD00,129.  OUT&BC00,7:OUT&BD00,27 little down screen. You still have to set V-position of monitor.


YES YES YES! i other resolution work almost whole Basic and editor. SHIFT+ARROWS , COPY, Locate X,Y, WINDOW, DRAW, PLOT, DRAWR, FILL and hardware scroll. This program ovs18.bas on dsk is very usefull for write other program.
I just ran this on Winape, the thread title is "Change Aspect Ratio" but all i see it doing is changing the screen width in characters(not the aspect ratio)?
Unless you mean doubling the vertical aspect ratio for the screen in basic so characters are double size but only every other line is drawn?
6128 for the win!!!

McArti0

https://en.wikipedia.org/wiki/Aspect_ratio_(image)

change aspect ratio changing resolution of course. (Does not change the physical dimensions of the monitor ;D )

"simple example how change hight factor x2" is only offtopic for you. pixels in mode 0 although they pretend to be square ;)  (res 160x128 only)

CPC 6128, Whole 6128 and Only 6128, with .....
NewPAL v3 for use all 128kB RAM by CRTC as VRAM
TYPICAL :) TV Funai 22FL532/10 with VGA-RGB-in.

eto

Quote from: lmimmfn on 00:28, 26 January 22I just ran this on Winape, the thread title is "Change Aspect Ratio" but all i see it doing is changing the screen width in characters(not the aspect ratio)?

Aspect ratio is not related to the resolution itself but to the ratio of the x-resolution to the y-resolution and the pixel size.

If the screen has 320x200 pixels, the aspect ratio is 16:10. If the screen is changed to 256x200 it's 4:3 (well, almost, 192 would be correct but that won't work on the CPC) and 256x256 is 1:1. If you change to MODE 0, the resolution shrinks to 160x200 but since the pixels are twice as wide as tall, the aspect ratio does not change.

Full HD has 1920x1080, which is 16:9 and 1920x1200 is (again) 16:10. 1280x1024 is 5:4 and 640x480 is 4:3.

pelrun

More accurately, aspect ratio is the ratio of image width to height, independent of resolution. Resolution is *related* to aspect ratio, but depends on the pixel aspect ratio as well. While PC monitors and MODE 1 (mostly) has square pixels, making the relationship 1:1, that's not always the case. CRTs and their physically independent pixel height/width may be obsolete, but anamorphic lenses are still commonly used when filming, and chroma subsampling is common in video compression (where the chroma channels often only have half the horizontal resolution) so it's important to also take into consideration what the source material is.

I've spent too many hours debugging this stuff in my day job...  :laugh:

McArti0

1024x128 and WORK!!!  :o  but not on standard monitor.


I can not add new jpg. Why?  :-\
CPC 6128, Whole 6128 and Only 6128, with .....
NewPAL v3 for use all 128kB RAM by CRTC as VRAM
TYPICAL :) TV Funai 22FL532/10 with VGA-RGB-in.

McArti0

CPC 6128, Whole 6128 and Only 6128, with .....
NewPAL v3 for use all 128kB RAM by CRTC as VRAM
TYPICAL :) TV Funai 22FL532/10 with VGA-RGB-in.

Powered by SMFPacks Menu Editor Mod