In a graphics mode function 0Ch sets the pixel at column CX, row DX to colour AL, counting from 0 at the top left. The BIOS works out which byte and which bits hold that pixel in the current mode (two bits of an interleaved line in CGA mode 04h, one bit in each of four planes in the EGA modes, a whole byte in mode 13h), so the same code draws in every mode. The colour runs up to what the mode offers: 0–3 in mode 04h, 0–15 in modes 0Dh–12h, 0–255 in mode 13h.

With bit 7 of AL set, the BIOS XORs the colour into the pixel instead of replacing it, except in the 256-colour mode, where bit 7 is part of the colour. Drawing the same thing twice with XOR restores the picture underneath, the old way to move a crosshair or stretch a rubber-band line. Here every colour of mode 13h's default palette is drawn in a band across the middle:

Prints "Back in mode 03h"; on the screen a band of all 256 colours of the default palette crosses the middle for 2 seconds, then the text screen comes back cleared.
MOV AX, 0013h ; 320x200, 256 colours
INT 10h
MOV DX, 92 ; rows 92 to 107
ROW1:
MOV CX, 32 ; x from 32 to 287
DOT1:
MOV AL, CL
SUB AL, 32 ; colour = x - 32: 0..255 along the line
MOV AH, 0Ch ; write the pixel
MOV BH, 0 ; page 0
INT 10h
INC CX
CMP CX, 288
JB DOT1
INC DX
CMP DX, 108
JB ROW1
MOV CX, 001Eh ; wait 2 s: CX:DX = 1E8480h microseconds
MOV DX, 8480h
MOV AH, 86h ; BIOS: wait
INT 15h
MOV AX, 0003h ; mode 03h again: 80x25 text, clears the screen
INT 10h
MOV AH, 09h
MOV DX, OFFSET MSG1
INT 21h
MSG1 DB "Back in mode 03h", 13, 10, "$"

Speed, and the direct way

Each pixel costs an interrupt, the BIOS's register saves and a look at the mode: fine for a few thousand dots, far too slow to fill a screen. In mode 13h writing video memory is trivial, one byte at offset y × 320 + x in segment A000h, and nearly every mode 13h program does that:

MOV AX, 0A000h
MOV ES, AX
MOV AX, 100 ; y
MOV BX, 320
MUL BX ; AX = y * 320 (DX = 0)
ADD AX, 160 ; + x
MOV DI, AX
MOV BYTE PTR ES:[DI], 15 ; a white pixel

Pitfalls

In text modes the call does nothing useful; check the mode first. Coordinates are not checked: a pixel past the right edge lands on the next line, one below the bottom in memory beyond the screen. BH counts only in modes with several pages; keep it 0.