Font Size: a A A

Study On The Real-Time Shading Language

Posted on:2004-10-04Degree:MasterType:Thesis
Country:ChinaCandidate:T H ZhuFull Text:PDF
GTID:2168360095956164Subject:Computer application technology
Abstract/Summary:PDF Full Text Request
Always, it is a dream to make the graphics programming easy for everyone. So nowadays with the rapid and diverse development of the programmable graphics hardware, the design and implementation of the Real-time Shading Language is becoming the focus of the Real-time Rendering. With Real-time Shading Language, the complex shading process can be described in a more uniform and flexible way, discarding the previous tedious API functions. So it is safe to say that the Real-time Shading Language can not only improve the efficiency of the coding of the graphics programs, but also direct the evolution of the newer graphics hardware.Firstly different shading languages are introduced chronologically, especially on the characteristics of the shading language and the architectures of the related shading systems. From all these examples, we can see the trend of the development of shading language.Then the architecture of the newly programmable graphics hardware is presented. Taking Geforce3 as an example, we give a detailed description of the Vertex Shader and Pixel Shader. After that, one per-pixel lighting example based on this programmable graphics hardware is described.Finally we make a detailed description of our prototype of the Real-time Shading Language, which can be divided into three layers. The first layer is called the compiler layer, on which the syntax is defined. At the same time, the data types, the pre-defined variables and the built-in functions are also declared on this layer. The second layer is named the abstract representation layer, here the Shade Tree is the key data type, which can not only represent the semantic of the whole shading program, but also act as an abstract representation method. The third layer is the implementation layer. We have two solutions on this layer, one is based on the general graphics hardware, and the other is based on the newly programmable graphics hardware. In each solution, theresult is presented after the algorithm and data type are introduced. It is demonstrated that the whole pipeline of a shading system is set up including syntax analysis, semantic analysis, code generation and code execution.
Keywords/Search Tags:Real Time shading language, Programmable graphics hardware, Compiler theory, Shade tree, Vertex Shader, Pixel Shader
PDF Full Text Request
Related items