Site Tools


documentation:hardware:opera:vdlp

Overview

The VDLP (video display line processor) is responsible for taking the 16bit RGB framebuffer data and converting it into 24bit RGB which is then connected to the DAC. It manages whether or not the signal is PAL or NTSC, stores the CLUTs (color lookup tables), performs the optional horizontal and vertical interpolation, setting the “background” color, etc.

When reading about the VDLP keep in mind that there is the VDLP hardware side of things and the VDLP software side of things. The software often uses the same data structures that must be passed into the hardware but not everything is one for one. The software will “proof” or validate the input and wraps user input with it's own VDL entries. Limiting the user generated ones to visible lines rather than the full number of lines the system supports.

Pixel Formats

  • 1555:
    • bit 15: subposition weighting bit used by the interpolator
    • bit 14 - 10: red
    • bit 9 - 5: green
    • bit 4 - 0: blue
  • 15541:
    • bit 15: bit 1 of 2 subposition weighting bits used by the interpolator
    • bit 14 - 10: red
    • bit 9 - 5: green
    • bit 4 - 1: blue
    • bit 0: bit 2 of 2 subposition weighting bits used by the interpolator
  • P555:
    • bit 15: “soft-versus-hard palette select” bit which defines whether the user-programmable CLUT or the hardwired pseudo-linear CLUT will be used for performing color expansion (from 5 to 8 bits)
    • bit 14 - 10: red
    • bit 9 - 5: green
    • bit 4 - 0: blue
  • P5541:
    • bit 15: “soft-versus-hard palette select” bit which defines whether the user-programmable CLUT or the hardwired pseudo-linear CLUT will be used for performing color expansion (from 5 to 8 bits)
    • bit 14 - 10: red
    • bit 9 - 5: green
    • bit 4 - 1: blue
    • bit 0: subposition weighting bit used by the interpolator

Data Structures

The VDL (video display list)

A VDL is a collection of VDL entries. Each entry contains commands and information that can be read in the horizontal blank between display lines. A VDL must have at least one VDL entry, but need not have more than one. A simple VDL (used for most standard screens) has just a single VDL entry that sets display parameters for all lines of the screen.

A VDL can have as many VDL entries as there are display lines, but should not have more entries than display lines. If there are fewer VDL entries than there are display lines, some of those entries must persist for more than one display line. The entries themselves can define the length (in lines) of their persistence. If the persistence of the last VDL entry isn't set to last to the end of the display, the VDL processor will increase its persistence to reach to the end of the display.

VDL Entries

A VDL entry is a string of 32-bit words. The string must be no greater than 38 words in length. The string contains

  • 4 header words (required for every VDL entry)
  • 1 to 34 command words

The header words control the VDL processor's operation and DMA access to the bitmap buffer. The following list shows the words in the order in which they must occur:

  • The CLUT-DMA control word controls the display generator's access to VRAM (where it finds current- and previous-line bitmap buffers, how many words it reads per display line, how many lines it displays per screen, and other parameters). It also determines the size and persistence of this VDL entry and how the VDL processor will find the next VDL entry.
  • The current bitmap-buffer address word contains the address of the VRAM containing pixel data for this line. The address may or may not be used, depending on settings in the CLUT-DMA-control word.
  • The previous bitmap-buffer address word contains the address of the VRAM containing pixel data for the previous display line. The address may or may not be used, depending on settings in the CLUT-DMA-control word.
  • The next VDL-entry address word contains a pointer to the next VDL entry to be read by the VDL processor. This pointer can be an absolute or a relative address depending on settings in the CLUT-DMA-control word.

The length of a VDL entry is limited by the time available to read its words during a horizontal blank. The upper limit of 34 command words allows a VDL entry to change the contents of all 33 CLUT registers, with one command word left over to set other display parameters for the line.

The command words, which are optional for a VDL entry, set CLUT colors and control display generator operation. They need not occur in any particular order, but you should note that if two command words contain contradictory commands (two different colors for the same CLUT register, for example) the later word wins out.

The types of command words are

  • The color-value word sets the contents of a single CLUT color register (0 to 31). It can simultaneously set the red, green, and blue components of a register, or it can set any one of those color components without touching the others-for example, setting red without setting green and blue values.
  • The background-value word sets the contents of CLUT register number 32, the background color register.
  • The display-control word offers the fixed CLUT set, controls transparency, turns interpolation on or off, sets cornerweight HV values, and controls other display generator parameters.
  • The NULLOP word does absolutely nothing. Use it to pad out VDL entries if necessary.

CLUT-DMA Control Word

BitsField NameSDK Flag NamePatent DescriptionSDK Description
31:27 Reserved, must be set to zero for this versionNot available to a user task. Set to 0.
26SBC640SC1=doubles the S-Bus clock rate for faster memory fetch rateNot available to a user task. Set to 0.
25:23DmodeDISPMODThese 3 bits tell the hardware how many pixels to expect per line. 0=320, 1=384, 2=512, 3=640, 4=1024, 5=reserved, 6=reserve,d 7=reserved.Sets the modulo value (in words) added to the VDL processor's bitmap-buffer registers. 000=320; 001=384; 010=512; 011=640; 100=1024; 101, 110, and 111 are unused.
22EnS/SSLIPEN1 = Enables Slip Stream capture during H-blanking period.Not available to a user task, set to 0.
21EnVDMAENVIDDMA1 = Enables operation of video DMA.Enables video DMA. 1=enable, which shows the bitmap-buffer image on the display; 0=disable, which shows only vertical-blank color on the display.
20SelS/SSLIPCOMMSEL1 = Selects on of the two DMA channels as source of slipstream image data or command data.Not available to a user task. Set to 0.
19VRes480RES0 = Vertical resolution of incoming data is 240 lines per screen. 1= Vertical resolution of incoming data is 480 lines per screen.Sets vertical mode. 1=480 lines per frame; 0=240 lines per frame.
18NexVLCBrRELSELIndicates whether the “next CLUT list” address is absolute (=0) or relative (=1)Indicates the type of the address stored in the next VDL-entry-address word. 1=absolute; 0=relative.
17NexPlinePREVSELSpecifies whether the “previous video line” address for each subsequent scan line is to be calculated by adding a predefined modulo or by defining it as the previously used “current video line” address.Sets how the previous bitmap-buffer address register is ticked at line's end. 1=add modulo amount (set in bits 25-23); 0=accept current bitmap-buffer address-register value.
16CAValidLDCURIndicates the validity of the “current line video address” (0 = use normally incremented “current line video address”, 1 = use new address included in current CLUT list instead)Sets current bitmap-buffer address register override. 1=load address from current bitmap-buffer address word; 0=use address generated by register tick (modulo addition to last register contents).
15PAValidLDPREVIndicates the validity of the “previous line video address” (0 = use normally incremented “previously line video address”, 1 = use new address included in current CLUT list instead)Sets previous bitmap-buffer address-register override. 1=load address from previous bitmap-buffer address word; 0=use address generated by register tick (rotated current bitmap-buffer value or modulo addition to last register contentsset by bit 17).
14:9ListLenLENThese 6 bits indicate the length in words left to the rest of this list = VLCB_len-4 (-4 because 4 preamble words are always loaded in the current load)Gives the number of control words in this VDL entry (total number of VDL entry words minus the four used for the header). Should be from 1 to 34.
8:0NoLinesLINEThese 9 bits indicate the number of additional H scan lines to wait after this line before processing the next VLBC (range = 0 to 2Gives the number of display lines this VDL entry persists. This is the number of lines the VDL processor waits until reading the next entry in the VDL. The current line counts as one. The minimum value is 1 except for the last VDL entry, which should be 0. (0 specifies persistence until the bottom of the screen.)

Color-Value Word

BitsField NameSDK Flag NamePatent DescriptionSDK Description
31Ctrl/Colr (0=Colr) This first read bit indicates whether the remainder of this 32bit word is a color palette download word or a display control (command) word. Bit 31 is 0 for a color palette download word. The subsequent bit descriptions (Bits 30-0) in this Table are only valid for the case were Bit 31=0.Set to 0 to specificy that this is a color-value word.
30:29RGBenFULLRGB / REDONLY / GREENONLY / BLUEONLYThese 2 bits are write enable bits. 00 = enable a write of the download data of this word to all three current CLUTs (RGB) at the same time. 01 = write the blue field to the blue CLUT only. 10 = write the green field to the green CLUT only. 11 = write the read field to the red CLUT only.Determines what parts of a register are written to. 00 = write to al lthree registers (red, green, and blue); 01 = write to blue only; 10 = write to green only; 11 = write to red only.
28:24Addr This five bit address field is applied to the RGB CLUT's simultaneously.Contains the number (0-31) of the color register to write to.
23:16RedV This is the 8 bit Red value to be downloaded if enabled and later output from the Red CLUT when the present address is input.Contains 8 bits of red color value with bit 23 as the most-significant bit.
15:8GreenV This is the 8 bit Green value to be downloaded if enabled and later output from the Green CLUT when the present address is input.Contains 8 bits of green color value with bit 15 as the most-significant bit.
7:0BlueV This is the 8 bit Blue value to be downloaded if enabled and later output from the Blue CLUT when the present address is input.Contains 8 bits of blue color value with bit 7 as the most-significant bit.

Background-Value Word

BitsField NameSDK Flag NamePatent DescriptionSDK Description
31:24 Set to 11100000 to specify that this is a background-value word.
21:16 R_MASK
R_SHIFT
Contains eight bits of red color value with bit 23 as the most-significant bit.
15:8 G_MASK
G_SHIFT
Contains eight bits of green color value with bit 15 as the most-significant bit.
7:0 B_MASK
B_SHIFT
Contains eight bits of blue color value with bit 7 as the most-significant bit.

Display-Control Word

BitsField NameSDK Flag NamePatent DescriptionSDK Description
31:29Ctl/Colr (110=Ctl)DISPCTL Set to 110000 to specify that this is a display-control word.
28NullNULLAMY1 = forces the audio/video processor to send a null control word to audio/video output circuitry
27PAL/NTSCPALSELSelects the NTSC or PAL transmission standard for the output. 1 = PAL, 0 = NTSC
26 S640SELReserved
25ClutBypssCLUTBYPASSENEnables CLUT bypassMakes the fixed CLUT set available. 1=bitmap-buffer pixels with bit 15 set to 1 pass through the fixed CLUT set, those with bit 15 set to 0 pass through the custom CLUT set; 0=all bitmap-buffer pixels pass through the custom CLUT set (the fixed CLUT set is not available).
24SrcSelSLPDCELSelect source of background overlay data, 1 = SlipStream, 0 = CVBSNot available to a user task. Set to 0.
23TranTrueFORCETRANSForces transparency always true mode, letting overlay data be displayed from a slipstream capture if a pixel is defined as being “transparent”Forces pixel transparency. 1 = all pixels are transparent regardless of color value; 0 = transparency limited to background pixels (if enabled by bit 22). This bit is only meaningful for SlipStream.
22EnZDetBACKTRANSEnable the background color detector in the display path to indicate transparencySets transparency for background pixels. 1 = all pixels with 000 RGB value (backgorund pixels) are transparent; and are filled with the background register color. This bit is only meaningful for SlipStream.
21SwapHVWINSWAPHVSwaps the meaning of the horizontal and vertical subposition bits for window colorFor pixels going through the fixed CLUT set swaps the meaning of V and H cornerweight bits. 1 = H value is MSB, V value is LSB; 0 = H value is LSB, V value is MSB.
20:19VSrcWINVSUBSelect the vertical subposition bit source as being: a constant 0, a constant 1, equal to a value specified by the corresponding frame buffer bit, or equal to the value of the prior V source setting for windowFor pixels going through the fixed CLUT set sets each pixel's V cornerweight value. 00 = set V to 0; 01 = set V to 1; 10 = use V value stored in pixel; 11 = don't change this setting from the one used by the last VDL entry.
18:17HSrcWINHSUBSelect the horizontal subposition bit source as being: a constant 0, a constant 1, equal to a value specified by the corresponding frame buffer bit, or equal to the value of the prior H source setting for windowFor pixels going through the fixed CLUT set sets each pixel's H cornerweight value. 00 = set H to 0; 01 = set H to 1; 10 = use H value stored in pixel; 11 = don't change this setting from the one used by the last VDL entry.
16:15BlueLSBWINBLSBSelect the blue pen LSB source as being: 0, use frame buffer data bit 0, use frame buffer data bit 5, and maintain prioer setting for windowFor pixels going through the fixed CLUT set sets the value of each pixel's least-significant blue bit. 00 = set to 1; 01 = use bit 5 of the bitmap-buffer pixel value ( the least-significant green bit); 10 = use bit 0 of the bitmap-buffer pixel; 11 = don't change this setting from the one used by the last VDL entry.
14VIonWINVINTENEnables vertical interpolation for windowFor pixels going through the fixed CLUT set enables vertical interpolation. 1 = vertical interpolation on; 0 = vertical interpolation off.
13HIonWINHINTENEnables horizontal interpolation for windowFor pixels going through the fixed CLUT set enables horizontal interpolation. 1 = horizontal interpolation on; 0 = horizontal interpolation off.
12RndmRANDOMENEnables random number generator for the three LSBs of CLUT bypass module 484For pixels going through the fixed CLUT set enables random-number generation to fill in the three least-significant bits for the 8-bit red, green, and blue values coming out of the CLUT set. 1 = random number generation on; 0 = random number generation off, LSBs filled by technique determined in bit 11.
11MSBrepWINREPENEnables a window MSB replication gateFor pixels going through the fixed CLUT set determines how three least-significant bits for 8-bit read, green, and blue values are filled in. 1 = copied from the three most-significant bits of the color value; 0 = set to 000.
10SwapPENmsSWAPHVSwaps the MSB and LSB of the PEN halfword for lineFor pixels going through the custom CLUT set swaps the meaning of V and H cornerweight bits. 1 = H value is MSB, V value is LSB; 0 = H value is LSB, V value is MSB.
9:8VSrcVSUBSelect the vertical subposition bit source as being: a constant 0, a constant 1, equal to a value specified by the corresponding frame buffer bit, or equal to the value of the prior V source setting for lineFor pixels going through the custom CLUT set sets each pixel's V cornerweight value. 00 = set V to 0; 01 = set V to 1; 10 = use V value stored in pixel; 11 = don't change this setting from the one used by the last VDL entry.
7:6HSrcHSUBSelect the horizontal subposition bit source being: a constant 0, a constant 1, equal to a value specified by the corresponding frame buffer bit, or equal to the value of the prior H source setting for lineFor pixels going through the custom CLUT set sets each pixel's H cornerweight value. 00 = set H to 0; 01 = set H to 1; 10 = use H value stored in pixel; 11 = don't hange this setting from the one used by the last VDL entry.
5:4BlueLSBBLSBIn the case of a x/554/x mode, this field selects the blue pen LSB source as being: 0, use frame buffer data bit 0, use frame buffer data bit 5, and maintain prior setting for lineFor pixels going through the custom CLUT set sets the value of each pixel's least-significant blue bit. 00 = set to 1; 01 = use bit 5 of the bitmap-buffer pixel value (the least-significant green bit); 10 = use bit 0 of the bitmap-buffer pixel value; 11 = don't change this setting from the one used by the last VDL entry.
3VIonVINTENEnables vertical interpolation for lineFor pixels going through the custom CLUT set enables vertical interpolation. 1 = vertical interpolation on; 0 = vertical interpolation off.
2HIonHINTENEnables horizontal interpolation for lineFor pixels going through the custom CLUT set enables horizontal interpolation. 1 = horizontal interpolation on; 0 = horizontal interpolation off.
1ColrsOnlyCOLORSONLYColors Only after this point. Ignore optional download words that are other than color defining words.Not available to a user task. Set to zero.
0VIoff1lnONEVINTDISDisable vertical interpolation for this line only

NULLOP Word

BitsField NameSDK Flag NamePatent DescriptionSDK Description
31:24 NOP / NULLVDL Set to 11100001 to specify that this is a NULLOP word.
23:0 Have no significance whatsoever. Set to zero.

Block Diagram

Patents

Development Documents


documentation/hardware/opera/vdlp.txt · Last modified: 2022/10/02 19:55 by 127.0.0.1