Int 10h, 1Ch            Save/Restore Video State                          VGA

Performs a complete save or restore of the VGA video state.

──────────────────────────────────────────────────────────────────
Return size of buffer needed to save/restore video state

Entry AX = 1C00h
CX = Requested states:
Bit 2 1 = DAC state
Bit 1 1 = BIOS data
Bit 0 1 = Video hardware state

Return AL = 1Ch If function supported
BX = Save/restore buffer size block count
(each block is 64 bytes)

──────────────────────────────────────────────────────────────────
Save video state

Entry AX = 1C01h
CX = Save:
Bit 2 1 = Save DAC state
Bit 1 1 = Save BIOS data
Bit 0 1 = Save video hardware state
ES:BX = Address of buffer

Return AL = 1Ch If function supported

──────────────────────────────────────────────────────────────────
Restore video state

Entry AX = 1C02h
CX = Restore:
Bit 2 1 = Restore DAC state
Bit 1 1 = Restore BIOS data
Bit 0 1 = Restore video hardware state
ES:BX = Address of buffer

Return AL = 1Ch If function supported

──────────────────────────────────────────────────────────────────

This service lets you save or restore the video state. First, you
must determine the size of the memory buffer you need to store
video information.

To get that size, use subservice 0. You need to specify how
much information you want to store by setting the bits of CX as
follows:
Bit 2 1 = Save/restore DAC state
Bit 1 1 = Save/restore BIOS data
Bit 0 1 = Save/restore video hardware state

Subservice 1 saves the state. Pass it the address of the data
buffer you want to use in ES:BX and set the bits in CX to match
those parts of the video state you want to save. Note that many
BIOSes corrupt the video registers when saving the state, so a
program should restore the state, using subservice 2, immediately
after saving it (the saved data is uncorrupted).

Subservice 2 restores the video state. The inputs are the same
as for subservice 1.