Skip to content

Latest commit

 

History

History

pc-dos

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Demos written in assembly language for PC and 16bit DOS

Primer for assembly language on PC/DOS

  1. The classic 'Hello world' written in assembly
  2. Shorter way how to exit from DOS application
  3. Waiting for key press before program exits
  4. Macros usage

Text and graphics on CGA graphics card

BIOS graphics subroutines

  1. Draw pixel via BIOS in graphics mode #4
  2. Draw pixel via BIOS in graphics mode #6
  3. Draw line using separate pixel draw via BIOS in graphics mode #4
  4. Draw line using separate pixel draw via BIOS in graphics mode #6

Accessing CGA video RAM directly

Screen fill

  1. Explicit loop with counter
  2. LOOP instruction usage
  3. REP STOSB instruction usage
  4. VSync-based synchronization

Putpixel implementation

  1. Naive variant based on 16bit multiplication
  2. A bit better variant based on 8bit multiplication
  3. Using shifts instead of multiplications
  4. Drawing pixels over image (incorrect variant)
  5. Drawing pixels over image (correct variant)

Image transfers (blitting)

  1. Base variant using program loop
  2. Faster variant using REP MOVSB
  3. Faster variant using REP MOVSW
  4. Correct even scanlines (empty odd scanlines)
  5. Correct even and odd scanlines
  6. Color palette selection
  7. Color palette selection + low intensity mode
  8. Color palette selection + low intensity mode after keypress

Text modes and pseuographics modes

  1. Standard BIOS text mode #1 (40x25)
  2. Standard BIOS text mode #3 (80x25)
  3. Changing meaning of intensity bit in color attributes
  4. Changing text cursor shape
  5. Changing characters height
  6. Pseudographics mode 160x25 'pixels'
  7. Pseudographics mode 160x100 'pixels'

Text and graphics on Hercules graphics card (HGC)

Text mode on HGC

  1. Text mode 80x25 characters
  2. Text mode with high intensity flag enabled
  3. Turning off video signal

Graphics mode on HGC

  1. Setting graphics mode 720x348 pixels, basic variant
  2. Setting graphics mode 720x348 pixels, better variant
  3. Putpixel operation in graphics mode

Text and graphics on EGA graphics card

Text mode on EGA

  1. Text mode 80x25 characters
  2. Text mode 80x43 characters
  3. Setting standard font read from ROM
  4. Setting custom font read from RAM

EGA graphics modes

  1. Graphics mode with resolution 320x200 pixels
  2. Graphics mode with resolution 640x200 pixels
  3. Graphics mode with resolution 640x350 pixels

EGA color palette

  1. Color palette settings in mode with 200 scanlines
  2. Color palette settings in mode with 350 scanlines
  3. Settings all colors via explicit loop
  4. Use BIOS service to set all colors in palette

Drawing on EGA card

  1. Enable/disable bitplanes to write to, basic approach
  2. Enable/disable bitplanes to write to, faster approach
  3. Drawing pixels in graphics mode 320x200, 16 colors
  4. Drawing pixels in graphics mode 640x350, 16 colors