flat assembler
Message board for the users of flat assembler.

flat assembler > OS Construction > gui methods in real mode

Author
Thread Post new topic Reply to topic
GhostXoPCorp



Joined: 13 Dec 2008
Posts: 199
Location: 01F0:0100
how can i do a grphics mode of more then 320 200 preferably 640 480, can some one point me to a tutorial in assembly so i may use it. i know i have to acsess chunks of the screen in 64k blocks, but how? plz help me

_________________
Oh that divide overflow. Just jumps out of the bushes every time to scare the day lights out of me.
Post 21 Nov 2009, 04:18
View user's profile Send private message Reply with quote
windwakr



Joined: 30 Jun 2004
Posts: 827
Location: Michigan, USA
Look up VESA.

There's some good info on it here:
http://www.monstersoft.com/tutorial1/VESA_intro.html

I've also seen some VESA stuff here on the forums, try searching around.

_________________
----> * <---- My star, won HERE
Post 21 Nov 2009, 04:50
View user's profile Send private message Reply with quote
GhostXoPCorp



Joined: 13 Dec 2008
Posts: 199
Location: 01F0:0100
great thank u so much for the fast response
Post 21 Nov 2009, 04:55
View user's profile Send private message Reply with quote
Dex4u



Joined: 08 Feb 2005
Posts: 1601
Location: web
Here is how vesa bank switching works in real mode
As your in realmode your limted to 64k, so this mode uses 1 boxs 64k in size, you need to swich boxs eg:
********box0****
64k
********box1****
64k
********box2****
64k
********box3****
64k
********box4****
64k
****************
Here this may help
Code:
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;                                           ;;
;; fasm example.By Craig Bamford (Dex) 2002. ;;
;; 640*480 8bpp (256 colors) vesa1           ;;
;; C:\fasm vesa1.asm vesa1.com               ;;
;;                                           ;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
ORG    100h

Start:
        mov ax,4f02h
        mov bx,101h
        int 10h

        mov dx,0xa000
        mov es,dx
        call window

StartAgain:
        xor dx,dx
        mov [color],0      
MainLoop:
        push dx
        call window
        xor bx,bx
        inc [color]
        mov al,[color]
        call static

        pop dx
        cmp dx,4
        je StartAgain
        inc dx  ;<** here is box number
        mov ah,01h
        int 16h
        jz MainLoop
        mov ah,00h
        int 16h
        mov ax,0003h
        int 10h

        ret

window:
        mov ax,4f05h
        mov bx,0
        int 10h
        xor bx,bx
        ret

static:         
        stosb
        inc bx
        cmp bx,0x00000
        jne static
        ret




color    db         0
Row      db         0
    


More info here: http://board.flatassembler.net/topic.php?t=6032

PS: I am working on a Dos port of my GUI, but will switch between real amd pmode to run Dos programs, you may want to look into that.
Post 21 Nov 2009, 16:28
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2019, Tomasz Grysztar.

Powered by rwasa.