Write to real time ( such as he called )
So from the source:
#make_boot# org 7c00h use16 jmp start e: mov ax,cs mov ds,ax mov es,ax ret put_pix: push ax push dx mov ax,8000h mov es, ax mov ax,320 mul cx pop dx add ax,dx mov di,ax pop ax stosb ret fill_disp: push ax mov ax,8000h mov ds,ax pop ax mov ah,al mov bx,0000h mov [bx],ax p0: add bx,2 mov [bx],ax cmp bx,0FFFEh jz e jmp p0 e_draw: pop dx pop bx mov [x],dx mov [y],bx ret draw_sprite_nexline: inc si mov al,00h cmp al,[bx+si] jz e_draw dec si add [y],01h mov ax,[x_ret] mov [x],ax inc si jmp draw_sprite_1 draw_sprite: mov ax,bx mov dx,[x] mov bx,[y] push bx push dx mov bx,ax mov ax,[x] mov [x_ret],ax mov si,0000h draw_sprite_1: mov ax,8000h mov es, ax mov ax,320 mov cx,[y] mul cx mov dx,[x] add ax,dx mov di,ax mov al,[bx+si] cmp al,255 jz draw_sprite_2 stosb draw_sprite_2: inc si mov al,00h cmp al,[bx+si] jz draw_sprite_nexline add [x],1 jmp draw_sprite_1 draw_display: mov di,0000h mov bx,0000h mov si,0000h mov ax,8000h mov ds,ax mov ax,0A000h mov es,ax draw_display_1: cmp bx,0FFFFh jz draw_display_2 mov al,[bx] stosb inc bx jmp draw_display_1 draw_display_2: jz e left_sprite: sub [x],01h jmp p3 right_sprite: add [x],01h jmp p3 start mov ah, 0 mov al, 13h int 10h mov al,40 ;call fill_disp mov di,0000h mov si,0000h mov bx,sprite ;call draw_sprite p4: mov ah,01h int 16h jz p7 mov ah,00h int 16h cmp al,'a' jz left_sprite cmp al,'d' jz right_sprite p7: p3: mov di,0000h mov si,0000h mov al,60 call fill_disp mov di,0000h mov si,0000h mov bx,sprite call draw_sprite call draw_display jmp p4 x_ret dw 0 x dw 5 y dw 5 sprite db 30,30,30,30,30,0,30,30,30,30,30,0,30,30,30,30,30,0,30,30,30,30,30,0,30,30,30,30,30,0,30,30,30,30,30,0,0,0
In fact it is implemented, fill screen, create sprites, and that is not flickered created a second buffer through which it already displayed on the screen, And Yes it is a miracle works in virtual reality and I was able to write the piece of code and everything I thought.. Launched without emulatie in the gland, and there began then a black screen, then a bunch of different pixels, as the Bhutto climbed on some used piece of code.. And I don't really know where to find Pamyat for the second video buffer, I thought that his vobshe not, but I answered.
320x200 is 64 KB, not 64 MB as you wrote above.
if you use real mode you available 1MB - no need to write about 64 MB.
half of 1 MB is about 500 KB. I can fit 7-8 buffers at 64 KB.
I already changed a couple of times finding the buffer and nothing happens. Tell me what and how?