GB2355633A - Processing graphical data - Google Patents

Processing graphical data Download PDF

Info

Publication number
GB2355633A
GB2355633A GB9915060A GB9915060A GB2355633A GB 2355633 A GB2355633 A GB 2355633A GB 9915060 A GB9915060 A GB 9915060A GB 9915060 A GB9915060 A GB 9915060A GB 2355633 A GB2355633 A GB 2355633A
Authority
GB
United Kingdom
Prior art keywords
fragment
fragment information
data
pixel
queue
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Withdrawn
Application number
GB9915060A
Other versions
GB9915060D0 (en
Inventor
Ken Cameron
Eamon O'dea
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Pixelfusion Ltd
Original Assignee
Pixelfusion Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Pixelfusion Ltd filed Critical Pixelfusion Ltd
Priority to GB9915060A priority Critical patent/GB2355633A/en
Publication of GB9915060D0 publication Critical patent/GB9915060D0/en
Priority to GB0006986A priority patent/GB2352381B/en
Priority to GB0120840A priority patent/GB2362552B/en
Priority to GB0015678A priority patent/GB2356717B/en
Priority to GB0015766A priority patent/GB2356718B/en
Priority to PCT/GB2000/002474 priority patent/WO2001001352A1/en
Priority to US10/019,188 priority patent/US6898692B1/en
Priority to AU55545/00A priority patent/AU5554500A/en
Publication of GB2355633A publication Critical patent/GB2355633A/en
Withdrawn legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T15/003D [Three Dimensional] image rendering
    • G06T15/10Geometric effects
    • G06T15/40Hidden part removal
    • G06T15/405Hidden part removal using Z-buffer

Landscapes

  • Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Geometry (AREA)
  • Computer Graphics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Image Generation (AREA)

Abstract

A method of processing data relating to graphical primitives to be displayed on a display device using region-based multi-processor architecture, has the shading and blending operations deferred until rasterisation of the available graphical primitive data is completed. For example, the method may comprise the steps of: a) defining a data queue having a predetermined number of locations therein; b) receiving fragment information belonging to an image to be displayed by the pixel; c) determining whether the fragment information belongs to an opaque image or to a blended image; d) if the fragment information relates to a blended image, storing the fragment information on the next available location in the queue; e) if the fragment information relates to an opaque image, clearing the locations of the queue and storing the fragment information in the first location in the queue; f) repeating steps b) to e) for new fragment information, until fragment information is stored in all the locations in the data queue or until no further fragment information is available; and g) processing in turn fragment information stored in the locations of the queue to produce respective pixel display values.

Description

PROCESSING GRAPHICAL DATA The present invention relates to processing
graphical data and in particular to methods and apparatus f or calculating pixel data f or display on a display device having a plurality of pixels.
BACKGROUND OF THE INVENTION
Graphical images are conventionally displayed on display devices which include a plurality of picture elements, or pixels. One such device is illustrated in Figure I of the accompanying drawings. The display device I is made up of a plurality (for example 15 640x480, 8OOx6OO, to 1600x1200) of pixels (picture elements) 3 which are used to make up the image display on the screen as is well known. In order to display an image on the screen the colour value of each pixel must be calculated for each f rame of the image to be 20 displayed. The pixel information is typically stored in a "frame buffer" of the display device. Calculation of pixel colour values is known as "shading" and is advantageously performed by a dedicated graphics processing system. The use of such a dedicated 25 graphics processing system in combination with a host system enables the processing power of the host system to be more effectively utilised processing applications software. The application software typically determines the geometry of the images to be shown on 30 the display device and the graphics system takes geometrical information and calculates the actual pixel values for display on the device 1 from that information.
Commonly, the graphics processing system receives information from the host application in the form of information data regarding graphical primitives to be displayed. A graphical primitive is a basic graphical element which can be used to make up complex images.
For example, a common graphical primitive is a triangle and a number of different shaped and sized triangles can be used to make up a larger more complex shape.
The primitive data includes information regarding, the extent, colour, texture and other attributes of the primitive. Any amount of primitive information can be used. For example, simply colour and extent information may be sufficient for the application or primitive concerned. visual depth information, ie the relative position, of the primitive can also be included. In the following examples, primitives having a high visual depth value are considered to be closer the viewer, ie more visible, than those primitives having lower visual depth value. Such a convention is arbitrary, and could be replaced by any other suitable convention.
Figure 2 illustrates in side view, and Figure 3 illustrates in front view, the display of primitives P1, P2 and P3 on the pixels 3 of the display device 1.
Primitive P1 is the rearmost primitive, having a visual depth Pld which is lower than the visual depths of the other primitives. Primitive P3 is the frontmost primitive. As can be seen, the primitives overlap one another, and so the graphics processing system must calculate, for each pixel, which of the primitives is displayed at that pixel.
In the following examples, three pixels 3a, 3b and 3c will be used illustrate the graphical processing of the primitive data.
In a graphical processing system having a single processor, a primitive analysed so that a pixel covered by the primitive can be identified. A "fragment" of the primitive data is determined for that pixel, and is then processed to determine the colour to be displayed for the pixel. When one fragment has been processed, a further fragment can be identified and processed.
The graphics processor receives fragment information which contains data indicating the colour, texture and blending characteristics of the primitive concerned at a particular pixel.
A "shading" process is then used to process the fragment information in order to determine the actual pixel data which is to be written to the frame buffer of the display device for display thereon. The shading process results in the determination of the colour of the pixel from the fragment information. This may involve a texture look-up operation to determine the texture characteristics to be displayed at the pixel.
A texture look-up involves a memory access step to retrieve the texel, or texture element, for the pixel.
For opaque primitives, the colour information is supplied to the frame buffer where it overwrites the current value to give a new value for display.
The frame buffer contents can be displayed immediately, or could be displayed at an arbitrary time in the future (for example using multiple frame buffers for the device), and any suitable scheme can be used for the display device concerned.
Figure 4 shows the final frame buffer values for the primitives arrangements shown in Figure 2 and 3. Pixel 3a will display the properties of primitive P1, pixel 3b will display the properties of primitive P2, and pixel 3c will display the properties of primitive P3.
A development of such a system uses a region-based processing scheme including a plurality of processors.
As illustrated in Figure 1, the pixels 3 of the display device 1 are grouped in to a number of regions, f or example region 5. The region size is usually def ined by the number of processors in the multiple processor system. one particular processing architecture could be a single instruction multiple data (SIMD) processing architecture. In a region based architecture, the primitives are sorted to determine which regions of the display include which primitives and are then subjected to "rasterisation" to break the primitives into fragments. The fragment information is stored for each primitive until all of the primitives have been rasterised. Usually, only the most recently determined fragment information is retained for each pixel. A shading process is then used to determine the pixel data to be stored in the frame buffer for display.
Such a scheme has the advantage that the shading process can be used a minimized number of times by shading multiple pixels at the same time (using one processor per pixel) and by waiting until a high proportion of pixels are ready to be shaded. Such a scheme is known as "deferred shading" because the shading process is carried out after the rasterisation process has been completed.
Such a scheme works well when all of the primitives are opaque since deferring the shading operation enables large memory accesses (i.e. texture look-ups) to be deferred and performed in parallel. The result for opaque primitives will be as shown in Figure 4.
A technique which can be used to provide transparent or partly transparent primitives is known as "blending".
In a blending process, the current pixel data stored in the frame buffer is combined with newly calculated pixel data relating to a new primitive. The combination is performed in a manner defined by the blending algorithm in accordance with a so-called a value which indicates the amount of blending that is to be achieved, for example an a-value of 0.5 indicates that the result of the blend is to be half existing colour and half new colour. Blending occurs after the shading process. In the single processor case blending is performed immediately following the shading process f or each pixel. The pixel data is blended in the order in which the associates primitives are output from the host system.
Figure 5 illustrates the calculated frame buffer values for the primitives of Figures 2 and 3, where primitives PI and P2 are blended, and P3 is opaque. Pixel 3a displays a blend of primitive P1 and the background pixel 3b displays a blend of P1, P2 and the background, and 3c displays only P3.
In the region based architecture, it is not practical to defer blending with the deferred shading process because of the requirement to store large amounts of data relating to all of the primitives occurring at a pixel regardless of whether those primitives are visible or not. This is necessary because a blended primitive can have an effect on the final values of the pixel. In such a case, the shading and blending processes must be carried out f or a pixel as soon as a blended primitive is encountered. This results in low utilisation of a multi-processor design, since, on average, a single blended primitive is likely to cover only a small number of pixels and so the shading and blending processes must be carried out even though only a small number of the available processors have the required data. In addition, if shading and blending were to be performed for each primitive, many operations would be unnecessary due to overlapping primitives at a pixel.
Deferred shading for images including blended primitives has not been implemented for region based multiple processor graphics processing architectures, because of these problems.
It is therefore desirable to provide a graphics processing system which can defer blending and shading operations in order to provide higher performance and faster computation time.
SUMMARY OF THE PRESENT INVENTION
According to one aspect of the present invention, there is provided a method of processing data relating to graphical primitives to be displayed on a display device using a region-based multi-processor architecture, wherein shading and blending operations are deferred until rasterisation of the available graphical primitive data is completed.
According to another aspect of the present invention, there is provided a data processing apparatus for processing data for display on a display device, the apparatus comprising a plurality of processing elements operable to rasterise all available graphical primitive data into fragment data, and then to perform shading and blending processes on the fragment data in parallel for respective pixels of the display device.
According to another aspect of the present invention there is provided a A method of processing data representing images to be displayed on a device having is a plurality of pixels, the method comprising, for each pixel of the device:
a) defining a data queue having a predetermined number of locations therein; b) receiving fragment information belonging to an image to be displayed by the pixel; C) determining whether the fragment information belongs to an opaque image or to a blended image; d) if the fragment information relates to a blended image, storing the fragment information on the next available location in the queue; e) if the fragment information relates to an opaque image, clearing the locations of the queue and storing the fragment information in the first location in the queue; f) repeating steps b) to e) for new fragment information, until fragment information is stored in all the locations in the data queue or until no further fragment information is available; and g) processing in turn fragment information stored in the locations of the queue to produce respective pixel display values.
According to another aspect of the present invention, there is provided a data processing apparatus for processi-ng data relating to images to be displayed on a display device having a plurality of pixels, the apparatus comprising; rasterisation means connected to receive graphical primitive data and operable to produce fragment information from the graphical primitive data for each pixel of the graphical primitive, storage means operable to store the fragment information for a plurality of pixels; and processor means connected to receive fragment information, and operable to produce pixel display data from the fragment information, wherein the storage means defines, for each pixel, a data queue having a plurality of locations, the fragment information for a pixel being stored in respective locations of the data queue, and wherein the apparatus comprises control means operable to analyse the fragment information, and to discard all queue locations for a pixel and store new fragment information in the first location of the queue if the new fragment information relates to an opaque primitive, and to store new fragment information in the next available location in the data queue if the new fragment information relates to a blended primitive.
BRIEF DESCRIPTION OF THE DRAWINGS
Figure 1 is a schematic diagram illustrating a display device; Figure 2 and Figure 3 are schematic diagrams illustrating graphical primitives and the device of Figure 1; Figures 4 and 5 illustrate calculated frame buffers for non-blended and blended graphics primitives respectively; Figure 6 illustrates a graphics processing system; Figure 7 illustrates part of the system of Figure 6; Figures 8 and 9 provide respective flow charts showing steps in methods according to aspects of the present invention; Figure 10 illustrates the provision of a queue for each pixel; Figures 12 to 15 illustrate the queue contents for example pixels during processing in accordance with the method of Figure 9; Figure 16 illustrates an alternative method of embodying an alternative aspect of the present invention; Figure 17 illustrates primitives including an alpha tested primitive; Figures 18 to 21 illustrate queue contents during processing of the primitives of Figure 17 in accordance with the process of Figure 16; and Figure 22 illustrates final frame buffer contents.
DESCRIPTION OF THE PREFERRED EMBODIMENT
Figure 6 of the accompanying drawings illustrates a graphics processing system including a host system 11 connected to communicate with a graphics processing core 13. The graphics processing core 13 includes processor elements 15 and a controller 17. The processor elements 15 receive graphical primitive information from the host system 11 and control signals from the controller 17. The processor elements 15 operate to process the graphical primitive data in accordance with instructions from the controller 17 and to output information relating to properties of a respective pixel. Figure 7 illustrates one of the processor elements 15 of Figure 6 in more detail. The processor element 15 includes a processor unit 151, and a memory unit 152. The processor unit 151 may, for example, include an arithmetic logic unit and operates to process the data supplied by the host system, and the memory unit 152 is used as a local data storage area by the processor unit 151.
A method of processing graphical data embodying one aspect of the present invention will now be described with reference to Figures 6 to 12. As illustrated in Figure 10 a respective data queue 19a, 19b, 19c is defined for each pixel 3a, 3b, 3c (Figure 2). Each queue has a plurality of locations and acts as a first in-first-out queue. Each queue is preferably defined within the processor memory unit 152, although could be implemented as a dedicated FIFO buffer or other appropriate device.
Graphical primitive information is received from the host system 11 a single primitive at a time. A rasterisation and sorting process identifies the pixels that are included in the primitive and divides the primitive into fragments, one fragment per pixel. When all of the primitives have been rasterised and sorted, the pixel attribute calculation can begin. Such rasterisation and sorting processes are well known in the art.
Figure 8 shows a f low chart of a method embodying the present invention. The process starts at step A and at step B a queue 19a, 19b, 19c (Figure 10) is defined for each pixel. Each queue has a plurality of locations as illustrated in Figure 10. The number of locations is arbitrary and in the example shown equals eight.
However, any number of locations can be used. The queue is preferably stored in the memory unit 152 of the processor 15, but could be provided by a dedicated FIFO buffer or other suitable device. The queue is initialised by clearing all the locations of the queue.
Processing takes place on a pixel-by-pixel basis, with multiple pixels being processed in parallel. For each pixel, fragment information is received (step D). The fragment information includes data regarding the colour, texture and blending characteristics of the corresponding primitive of the pixel concerned. This first example assumes that no visual depth information is supplied, for example because the application software defining the geometry outputs primitive data in the correct order for display.
The blending characteristics of the fragment are tested (step E) to determine whether the fragment is opaque or blended. If the fragment is opaque then all the locations in the queue are cleared (step F). For both opaque and blended fragments, the fragment information is stored in the next available queue location (step G) These steps have the effect that if the fragment is opaque then the fragment inf ormation is stored in the first queue location, and if the fragment is blended then the information will be stored at the next available queue location.
The queue is analysed (step H) and if it is not full and there are more fragments to be processed (step I) then the process returns to step D f or the receipt of further fragment information.
However, if the queue is full or if there are no further primitives to be processed, the fragment information stored at the first queue location is shaded (step J). The shading process determines the colour (pixel data) for the pixel caused by the fragment concerned. The pixel data is then supplied to the frame buffer of the display device to replace, or be blended with, the existing frame buffer data. The blending characteristics of the fragment determine whether the frame buffer is simply overwritten or blended with the new data. If no further queue locations have fragment information stored therein, then the process is complete (step M).
If further locations in the queue contain fragment information, then the fragment information of the next queue location is shaded (step N), and then blended (step K) with the frame buffer. This process continues until there are no further unprocessed queue locations.
In this way, shading and blending of fragment information can be deferred so that the large texture look-ups and other calculations which are required for shading and blending do not impact on the processing speed of the rasterisation process. In addition, the shading and blending is deferred until a large number of the processor units 15 are able to take part in the shading operation. This is particularly important in a single instruction multiple data (SIMD) processor architecture in which all processors process the same instruction at the same time.
Another advantage of this method is that when the queues are not filled during rasterisation, the number of shade steps is minimized. Even where a queue is filled, the number of shade steps will probably be less than the number of rasterisation steps.
An alternative method embodying the invention is illustrated in Figure 9. If the host application does not supply the primitive information in the correct order, then the graphics system must perform some further processing so that the primitives are correctly displayed. One particular way of achieving this is for the host to supply visual depth information with the primitive information. The received fragment information then includes fragment visual depth information.
As before a queue is defined for each pixel (step B) In addition, a current depth value is assigned for the pixel. The queue and current depth value are initialised (step C), to zero. The fragment information is received (step D), and the fragment visual depth compared with the current visual depth (step DA). The depth test results are used to determine the visibility of the fragment (visibility test, step DB). If the fragment is not visible, then the fragment information is discarded. If there are more fragments to be processed then the process returns to step D to receive further fragment information. If there are no further fragments (step DE), and no fragment information stored in the queue(step DF) the process is complete (step DG). If fragment information is stored in the queue, the processing proceeds to step J (Figure 8).
If the primitive is visible, then the current depth value is updated to the newly received fragment depth value, and the fragment information is processed from step E of Figure 8, as described above.
Referring now to Figures 2 and 3, and to Figures 10 to 13, the method of Figure 9 will be illustrated by way of an example. In Figures 2 and 3, three primitive P1, P2 and P3 are shown. Each primitive has a respective visual depth value Pid, P2d and P3d. For the purposes of this example, primitive PI is assumed to be blended, primitive P2 is opaque and P3 is blended. The primitives are assumed to arrive from the host in the order P1, P2, P3.
Figure 11 shows the state of the queues for each pixel after initialisation, all of the queue locations are empty and the depth current value is set to zero.
Fragment information relating to primitive Pi is received for pixels 3a, 3b and 3c and since the fragment depth value (Pid) is greater than the current depth value (0), the fragment blending characteristic is checked. Since primitive PI is a blended primitive, the PI fragment information is stored in the next available location in each queue, as shown in Figure 12. The current depth value is updated to become Pld.
Fragment information relating to primitive P2 is received for pixels 3b and 3c and, since the primitive depth is greater than the current depth value Ue. P2d > Pid), the blending characteristics of P2 are tested.
Since P2 is opaque, the queues for pixels 3b and 3c are cleared, and the P2 fragment information stored at the first queue location for queues 19b and 19c. The current depth value is updated for those two pixels.
The result of this step is shown in Figure 13.
Finally in this example, fragment information relating to primitive P3 is received for pixel 3c and since P3d > P2d, the blending characteristics are tested. P3 is a blended primitive, and so the P3 information is added to the queue for pixel 3c, and the depth value for that pixel updated to become P3d. This is illustrated in Figure 14.
Since P3 is the last primitive to be processed, the shading and blending processes can now take place. The results of theses steps are shown in Figure 15.
For pixel 3a, primitive PI is blended and so the pixel data derived from shading according to the P1 fragment information is blended with the current background information (BG) to produce the new frame buffer contents (BG and PI).
For pixel 3b, primitive P2 is opaque, and so the f rame buffer is simply overwritten with the pixel data derived from shading according to the P2 fragment information.
For pixel 3c, the first queue location relates to the opaque primitive P2 so the f rame buf f er is overwritten with the P2 fragment data. However, a second queue location exists for pixel 3c, and so that location is shaded and blended with the frame buffer to produce the final frame buffer contents (P2 and P3).
The above described method is appropriate to simple depth testing to determine visibility of the primitive.
However, "a-testing" of primitives can cause additional complications. a-testing operates on the a-value used for blending and is used for primitives having a texture which includes holes. For example, a mesh or net-like texture defines a series of holes bound by material. The a-value would then vary from 1.0 for the net material to 0. 0 for the holes. It is of course possible simply to shade and blend each pixel using the a-value. However, this is wasteful of resources since those pixels having a=0.0 result in no change to the frame buffer, and so processing effort is effectively wasted. Subjecting the a-value to a threshold test (the "a-test") enables unnecessary processing to be avoided. All pixels having an a-value less than the threshold are not processed.
If an a-tested fragment is defined at a pixel, there is then uncertainty concerning the actual colour to be displayed, unless the a-test is performed. However, a testing must be performed as part of the shading process because the actual a-value is determined by the part of the texture to be shown at the pixel and so, in the Figure 9 method, potentially important fragments may be discarded because they fail the simple depth test. Thus, the decision concerning the queue contents is effectively determined by the result of processing the data held in the queue. The goal of the method described above is to defer such calculations so that the rasterisation process can be carried out efficiently. Performing shading to determine the result of the a-test would therefore defeat this goal.
However, a development of the above described method embodying the present invention enables a-testing to be supported. The fragment information received by the system includes a flag which indicates simply if the fragment uses an a-tested texture. The flag does not itself give the result of the a-test.
In order to prevent potentially important fragments failing the simple depth test, a second current depth value is used for each pixel. The first current depth is the non-a-tested depth, and the second is the a tested depth. Initially, both current depths are set to the background depth (typically zero)
Two depth values are required because the presence of an a-tested -fragment leads to uncertainty in the actual visible depth at a pixel. A pixel may show a colour of the a-tested texture, or may occur at a hole in the texture. This does not become apparent until the a test is performed as part of the shading process. The first depth value can therefore be seen to represent the certain visible depth, behind which fragments do not contribute. The second depth value represents the uncertain visible depth, behind which fragments may or may not contribute.
The method described above is then modified to handle the following fragment types:
Any fragment behind the non-a-tested (first) depth is discarded.
An opaque fragment (not blended nor a-tested) in front of the a-tested (second) current depth clears the queue, replaces the first queue location, and sets both depth values to the new depth value.
A blended, non-a-tested fragment in front of the a tested depth, is stored in the next available position in the queue and both current depth values are updated to the new value.
An a-tested fragment which occurs in front of the a tested depth value is stored in the next available queue location, and the a-tested (second) depth value is updated.
A non-a-tested fragment which occurs between the two current depth values is stored at the next available position in the queue and the current non-a-tested depth value is updated.
An a-tested fragment which occurs between the two current depths is stored at the next available queue position, but does not update either of the current depth values.
The order in which items are placed in the queue is the order that they are shaded and blended. As the fragment information is not strictly depth-tested before being placed on the stack, the depth test must be performed for the true (certain) current depth after each a-test (after each shade and blend step).
Therefore, the a-test may determine that a later primitive does not, in fact, have an effect on the pixel concerned and that the data can be discarded.
Figures 16 shows a flow chart of a method embodying the present invention for use with a-tested primitives. The initial stages of the process are as shown in Figure 9, with the exception that two depth values are defined for each queue. 10 The visibility, or depth, test, now includes three tests. Firstly, the fragment depth value is compared (step DA I) with the first depth value, i.e. against the current certain depth value. If the fragment is not is visible with regard to the first depth value, then the fragment information is discarded (step DC'), and the usual test (steps DDI, DEI) made regarding further fragments being available. If the fragment is visible with regard to the first depth value, the a-test flag 20 is examined (step DFI) If the a-test flag indicates that the primitiveis not a-tested, then the first depth value is updated (step DGI) to be equal to the fragment depth value, ie. the 25 certain, non-Q-tested depth is updated. If the primitive is a-tested, then the first depth value remains unchanged and the fragment depth value is tested (step DHI) against the second (u-tested) depth 30 value.
If the fragment depth value indicates that the fragment is visible with respect to the second depth value, then the second depth value is updated (step DII) with the fragment depth value and processing proceeds as before (ie. to step E of Figure 8).
Referring now to the example primitives shown in Figure 17, the a-tested method will now be illustrated. In Figure 17, the primitives are produced by the host application in the order P1, P2, P3, and all primitives are blended. Primitive P2 is an a-tested primitive, as illustrated by the partial cross hatching in the Figure. The processing of pixel data for two pixels 3d and 3e will be explained with reference to Figures 18 to 22.
After initialisation, the queue for each pixel is cleared and both depth values are set to zero (Figure 18). The fragment information relating to primitive P1 is received and since the P1 fragment depth value is greater than both the f irst and second current depth values, fragment information is stored in the first queue location and both depth values set to Pld for both pixels (Figure 19).
The second primitive P2 is blended and has a larger depth value than the P1 fragment and so the f ragment information is stored in the second queue location for each pixel. However, since P2 is also a-tested, the actual visible depth produced by P2 is uncertain.
Therefore, only the second depth value is updated to P2d (Figure 20).
Fragment information relating to the third primitive P3 is received. The depth value for P3 therefore is larger than the Pi depth value, and smaller than the P2 depth value. Since the P1 depth value is the certain (non-a-tested) depth value, then the P3 fragment information is stored in the next available queue location, and the value is set to P3d. The second depth value is not updated because P3 is not visible with regard to the P2 depth value. However, the actual visibility of P3 will be calculated during the shading process in which the actual pixel values contributed by P2 will be determined.
When the queue locations are processed, the fragment information relating to primitive P3 will be discarded for pixel 3d, because P2 contributes to pixel 3d (ie. a > threshold), and so P3 will fail the depth test for pixel 3d. The result f or pixel 3d will be a blend of is the background, P1 and P2.
Since P2 does not contribute to pixel 3d (i. e. a < threshold) then pixel 3e results in being a blend of background, P1 and P3, as illustrated in Figure 22.
It will therefore be appreciated that methods of processing graphical data embodying the present invention can provide increased flexibility and performance over the prior considered methods, in particular when handling blended and a-tested graphical primitives.
The above described method is appropriate when all fragments use the same rule to determine visibility with regard to depth. This may be either that a fragment with a larger depth value than the current depth is visible, or alternatively that a fragment with a smaller depth value than the current value is visible. The method can be further extended to allow a mixture of fragments in which the depth test varies. Each time a fragment is presented which has a different test to the proceeding fragment, the alpha-tested and non-alpha-tested depth values are swapped before the fragments depth is tested. This is the only modification required.

Claims (20)

1. A method of processing data representing images to be displayed on a device having a plurality of pixels, the method comprising, for at least one pixel of the device:
a) defining a data queue having a predetermined number of locations therein; b) receiving fragment information belonging to an image to he displayed by the pixel; c) determining whether the fragment information belongs to an opaque image or to a blended image; d) if the fragment information relates to a blended image, storing the fragment information on the next available location in the queue; e) if the fragment information relates to an opaque image, clearing the locations of the queue and storing the fragment information in the first location in the queue; f) repeating steps b) to e) for new fragment information, until fragment information is stored in all the locations in the data queue or until no further fragment information is available; and g) processing in turn fragment information stored in the locations of the queue to produce respective pixel display values.
2. A method as claimed in claim 1, comprising determining whether the fragment information relates to a visible image, and discarding the fragment information if it does not relate to a visible image.
3. A method as claimed in claim 2, wherein the fragment information includes a fragment visual depth value indicative of the relative visibility of the image to which it belongs, and wherein the method comprises defining a current depth value indicative of the actual visibility of the pixel, and comparing the visual depth value of the received fragment information with the current depth value, thereby determining the visibility of the image to which the received fragment information belongs.
4. A method as claimed in claim 3, comprising, if the image to which the fragment information belongs is visible, updating the current visual depth value to be equal to the fragment visual depth value.
is
5. A method as claimed in claim 1, wherein the fragment information includes a fragment visual depth value indicative of the relative visibility of the image to which it belongs, and a fragment a-flag indicative of whether the image to which the fragment belongs is an a-tested image, the method comprising:
defining first and second current depth values; comparing the fragment visual depth value with the first and second current depth values; updating the first depth value to equal the fragment visual depth value, if the fragment a-flag indicates that the image is not an a-tested image and if the fragment depth value indicates that the image is visible with respect to the first current depth value; and updating the- second depth value to equal the fragment depth value, if the fragment depth value indicates that the image is visible with respect to the second current depth value.
6. A method as claimed in any one of the preceding claims, wherein the processing of the fragment information includes a shading step in which pixel data is derived from the fragment information.
7. A method as claimed in claim 6, wherein the display includes a frame buffer for storing pixel display data, and wherein the processing of the fragment information includes blending derived pixel data with the frame buffer for fragments belonging to blended images.
8. A method as claimed in claim 6, wherein the display includes a frame buffer for storing pixel display data, and wherein the processing of the fragment information includes replacing existing pixel display data stored in the frame buffer.
9. A data processing apparatus for processing data relating to images to be displayed on a display device having a plurality of pixels, the apparatus comprising; rasterisation means connected to receive graphical primitive data and operable to produce fragment information from the graphical primitive data for each pixel of the graphical primitive; storage means operable to store the fragment information for a plurality of pixels; and processor means connected to receive fragment information, and operable to produce pixel display data from the fragment information, wherein the storage means defines, for each pixel, a data queue having a plurality of locations, the fragment information for a pixel being stored in respective locations of the data queue, and wherein the apparatus comprises control means operable to analyse the fragment information, and to discard all queue locations for a pixel and store new fragment information in the first location of the queue if the new fragment information relates to an opaque primitive, and to store new fragment information in the next available location in the data queue if the new fragment information relates to a blended primitive.
10. Apparatus as claimed in claim 9, comprising means for determining the visibility of a primitive to which fragment information relates.
11. Apparatus as claimed in claim 10, wherein the control means is operable to discard new fragment data relating to graphical primitives which are not visible.
12. A data processing apparatus for processing data for display on a display device, the apparatus comprising a plurality of processing elements operable to rasterise all available graphical primitive data into fragment data, and then to perform shading and blending processes on the fragment data in parallel for respective pixels of the display device.
13. A graphics processing system including data processing apparatus as claimed in any one of claims 9 to 12.
14. A games console including data processing apparatus as claimed in any one of claims 9 to 12.
15. An integrated circuit including data processing apparatus as claimed in any one of claims 9 to 12.
16. An integrated circuit as claimed in claim 15, comprising a central processing unit.
17. An integrated circuit as claimed in claim 15, comprising a single instruction multiple data (SIMD) architecture processing core.
18. A method of processing data relating to graphical primitives to be displayed on a display device using a region-based multi-processor architecture, wherein shading and blending operations are deferred until rasterisation of the available graphical primitive data is completed.
19. A method of processing data substantially as hereinbefore described with reference to the accompanying drawings.
20. A data processing apparatus substantially as hereinbefore described with reference to, and as shown in, the accompanying drawings.
GB9915060A 1999-06-28 1999-06-28 Processing graphical data Withdrawn GB2355633A (en)

Priority Applications (8)

Application Number Priority Date Filing Date Title
GB9915060A GB2355633A (en) 1999-06-28 1999-06-28 Processing graphical data
GB0006986A GB2352381B (en) 1999-06-28 2000-03-22 Processing graphical data
GB0120840A GB2362552B (en) 1999-06-28 2000-03-22 Processing graphical data
GB0015678A GB2356717B (en) 1999-06-28 2000-06-27 Data processing
GB0015766A GB2356718B (en) 1999-06-28 2000-06-27 Data processing
PCT/GB2000/002474 WO2001001352A1 (en) 1999-06-28 2000-06-28 Method and apparatus for rendering in parallel a z-buffer with transparency
US10/019,188 US6898692B1 (en) 1999-06-28 2000-06-28 Method and apparatus for SIMD processing using multiple queues
AU55545/00A AU5554500A (en) 1999-06-28 2000-06-28 Method and apparatus for rendering in parallel a z-buffer with transparency

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
GB9915060A GB2355633A (en) 1999-06-28 1999-06-28 Processing graphical data

Publications (2)

Publication Number Publication Date
GB9915060D0 GB9915060D0 (en) 1999-08-25
GB2355633A true GB2355633A (en) 2001-04-25

Family

ID=10856182

Family Applications (2)

Application Number Title Priority Date Filing Date
GB9915060A Withdrawn GB2355633A (en) 1999-06-28 1999-06-28 Processing graphical data
GB0006986A Expired - Fee Related GB2352381B (en) 1999-06-28 2000-03-22 Processing graphical data

Family Applications After (1)

Application Number Title Priority Date Filing Date
GB0006986A Expired - Fee Related GB2352381B (en) 1999-06-28 2000-03-22 Processing graphical data

Country Status (1)

Country Link
GB (2) GB2355633A (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7268779B2 (en) 2002-12-24 2007-09-11 Intel Corporation Z-buffering techniques for graphics rendering
GB2404316B (en) * 2003-07-25 2005-11-30 Imagination Tech Ltd Three-Dimensional computer graphics system

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO1995002236A1 (en) * 1993-07-09 1995-01-19 Taligent, Inc. Display compositing system
WO1998053425A1 (en) * 1997-05-22 1998-11-26 Sega Enterprises, Ltd. Image processor and image processing method
US5923333A (en) * 1997-01-06 1999-07-13 Hewlett Packard Company Fast alpha transparency rendering method

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4399910B2 (en) * 1998-09-10 2010-01-20 株式会社セガ Image processing apparatus and method including blending processing
GB2343601B (en) * 1998-11-06 2002-11-27 Videologic Ltd Shading and texturing 3-dimensional computer generated images

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO1995002236A1 (en) * 1993-07-09 1995-01-19 Taligent, Inc. Display compositing system
US5923333A (en) * 1997-01-06 1999-07-13 Hewlett Packard Company Fast alpha transparency rendering method
WO1998053425A1 (en) * 1997-05-22 1998-11-26 Sega Enterprises, Ltd. Image processor and image processing method

Non-Patent Citations (7)

* Cited by examiner, † Cited by third party
Title
"Deferred Shading", URL: http://graphics.stanford.edu/ïjedavis/courses/348c-spring/deferredshading.h *
"Real-Time Programmable Shading", URL: http://wwwcs.unc.edu/ïolano/papers/ *
"Triangle Scan Conversion usinh 2D Homogeneous Coordinates" URL: http://wwwcs.unc..edu/ïolano/papers *
"Visualize PxF1", URL: http://www.webstage.hp.se/webstage *
/2dh-tri/ *
_970921/arbetss/arbetss_vispxfl.html *
tml *

Also Published As

Publication number Publication date
GB0006986D0 (en) 2000-05-10
GB9915060D0 (en) 1999-08-25
GB2352381A (en) 2001-01-24
GB2352381B (en) 2001-10-24

Similar Documents

Publication Publication Date Title
US6898692B1 (en) Method and apparatus for SIMD processing using multiple queues
US11182952B2 (en) Hidden culling in tile-based computer generated images
US6552723B1 (en) System, apparatus and method for spatially sorting image data in a three-dimensional graphics pipeline
US8345051B2 (en) Processing of 3-dimensional graphics
US7538765B2 (en) Method and apparatus for generating hierarchical depth culling characteristics
US6115049A (en) Method and apparatus for high performance antialiasing which minimizes per pixel storage and object data bandwidth
US6670955B1 (en) Method and system for sort independent alpha blending of graphic fragments
US6424345B1 (en) Binsorter triangle insertion optimization
WO2003046836A1 (en) Image processing apparatus and constituent parts thereof, rendering method
US9454844B2 (en) Early depth testing in graphics processing
KR102547879B1 (en) z-Identify or remove overlapping fragments after culling
US7589722B2 (en) Method and apparatus for generating compressed stencil test information
GB2538856A (en) Opacity testing for processing primitives in a 3D graphics processing system
US6963346B2 (en) Method and system for efficiently using fewer blending units for antialiasing
JPH09500462A (en) Computer graphics system with high performance multi-layer z-buffer
US6741243B2 (en) Method and system for reducing overflows in a computer graphics system
US6906715B1 (en) Shading and texturing 3-dimensional computer generated images
US10726610B2 (en) Efficient graphics processing using metadata
US6421060B1 (en) Memory efficient system and method for creating anti-aliased images
US20090154834A1 (en) Rendering system and data processing method for the same
GB2355633A (en) Processing graphical data
US11790479B2 (en) Primitive assembly and vertex shading of vertex attributes in graphics processing systems
GB2362552A (en) Processing graphical data
US10157132B1 (en) Data processing systems using both a cache and a buffer for processing data
US7408549B1 (en) Method for hardware sorted fragment composition

Legal Events

Date Code Title Description
WAP Application withdrawn, taken to be withdrawn or refused ** after publication under section 16(1)