Title: AnyGL: A Large Scale Hybrid Distributed Graphics System
1AnyGL A Large Scale Hybrid Distributed Graphics
System
- Ph.D Candidate Yang Jian(??)
- Supervisor Jiaoying Shi(???)
- State Key Lab of CADCG, Zhejiang Univ.
- 2002
2Contents
- Goal of Computer Graphics Architecture
- Parallel Graphics Architecture
- AnyGL in Details
- Conclusion
- Further Research
3Goal of Graphics Architecture
- Real-time
- Triangle rendering capacity
- Rasterization rate
- Texture size
- Display Resolution
- Realistic
- Local illumination, Gouraud, Phong
- Global illumination, ray-trace, ray-casting,
Radiosity
4Goal of Graphics Architecture
- Programmable,
- more effects
- faster,
- realistic
- non-realistic
5Contents
- Goal of Computer Graphics Architecture
- Parallel Graphics Architecture
- AnyGL in Details
- Conclusion
- Further Research
6Parallel Graphics Architecture
- Development of Graphcis Architecure
- Classification of Parallel Graphics Architecure
- Hardware System
- Software System
- Scalability of Parallel Parallel Graphics
Architecure
7Development of Graphics Architecture
- 1rd Generantion, 1975 1985,
- Geometry transfromation, clip, render objects
based on wire frame - 2rd Generation, mid 1985 1990
- Video memory, depth buffer, back face cull,
- gouraud rendering
- 3rd Generation, 1990 2000s
- Texture Mapping
- anti-alias, mutlis-sample
8Development of Graphics Architecture
- 4th Generation,1997
- Local illumination
- Hardware lighting, complex texture mapping(bump ,
compressed, 2000 - SIMD, 2001
- Programmable processor, 2001
- More programmable processors, 2002
- 5th Generations, 2005?
- Global illumination
9Parallel Graphics Architecture
- Development of Graphcis Architecure
- Sorting Classification of Parallel Graphics
Architecure - Hardware System
- Software System
- Scalability of Parallel Parallel Graphics
Architecure - Misc.
10Sorting Classification
- S. Molnar et al. 1994
- sort-first
- sort-middle
- sort-last
- M. Eldridge 2000, Pomegranate
- Transform Lighting
- Rasterization
- Texture
- Fragment
- Display
11Typical Graphics Pipeline
12sort-first
13sort-middle
14sort-last
15Parallel Graphics Architecture
- Development of Graphcis Architecure
- Sorting Classification of Parallel Graphics
Architecure - Hardware System
- Software System
- Scalability of Parallel Parallel Graphics
Architecure
16Hardware System of PGA
- SGI Reality Engine
- sort-middle
- share bus, broadcast
- every 2 scanlines one processor
17SGI Reality Engine
18Hardware System of PGA
- PixelFlow
- Sort-last
- ring-net, compose image
- SIMD is highly expolited
- Pomegranate
- 5 stages
- 64 nodes
19Pomegranate
20Hardware System of PGA
- Evans Sutherland Freedom 3000
- sort-last
- Kubota Denali
- sort-last
- Sepia, Compaq Reserch 2000
- sort-last
- ServerNet-II
21Parallel Graphics Architecture
- Development of Graphcis Architecure
- Sorting Classification of Parallel Graphics
Architecure - Hardware System
- Software System
- Scalability of Parallel Parallel Graphics
Architecure - Misc.
22Sortware System
- GLR
- Client/Server
- GLX, X Windows
- Princeton Multi-projector System
- sort-first
- one node distriutes commands
- 8 nodes receive and render commands
- Parallel Mesa
- sort-last
- binary swapping, parallel pipeline compositing
23Sortware System
- WireGL
- sort-first
- state tracking and state switch, dirty-bits,
Lazy-update - 3 kinds of OpenGL commands
- 16 clients 16 servers
- Lightning-2 assembles images
24WireGL(Chromium)
25Parallel Graphics Architecture
- Development of Graphcis Architecure
- Sorting Classification of Parallel Graphics
Architecure - Hardware System
- Software System
- Scalability of Parallel Parallel Graphics
Architecure - Misc.
26Scalability of Parallel Parallel Graphics
Architecure
- 5 parameters, Eldridge et al.2000
- triangle input rate
- triangle rendering rate
- texture size
- pixel rate
- display resolution
27Contents
- Goal of Computer Graphics Architecture
- Parallel Graphics Architecture
- AnyGL in Details
- Conclusion
- Further Research
28AnyGL
- Goal
- Architecture
- Classification of OpenGL Commands
- State Tracking
- Compression
- Scalability
- Parallel Graphics API
29Goal of AnyGL
- Hibrid Distributed Graphics System
- sort-first
- sort-last
- Large scale
- sort-first, new state tracking
- sort-last, image compression
- Good Scalability
30AnyGL
- Goal
- Architecture
- Command classification
- Analysis of Dependency Relation
- State Tracking
- Compression
- Scalability
31Architecture of AnyGL
- 4 kinds of Nodes
- Geometry Distributing Node ( G-node )
- Goemetry Rendering None ( R-node )
- Image Composite Node ( C-node )
- Display Node ( D-node )
- Sort-first
- G-node, R-node
- Sort-Last
- C-node, D-node
32Architecture of AnyGL
33(No Transcript)
34Geometry Rendering Node
- Capture opengl commands of application
- Packet OpenGL commands
- Computer State changes
- Send OpenGL command packets
35Geometry Rendering Node
- Receive Packet
- Check if context switch is needed
- Context switch
- Unpack the command packet
- Send corlor depth buffer to C-node
36Image Composite Node
- Receive color and depth data from R-nodes
- If they are compressed, decompress them.
- Compose the received data
- Send composed color and depth buffer to D-nodes
37Display Node
- Receive color and depth data from C-node
- Assemble image for final display
- Display the final image by CRT, Projector, LCD...
38Logical Division of Command Buffer
- Command buffer is divided into 2 parts
- Command Code buffer
- Parameter Buffer
- Command Code buffer
- ptr--
- Parameter Buffer
- ptr
39(No Transcript)
40Command Packet Structure
41Subdivision of glBegin-glEnd
- Condition
- lots of commands appear between a pair of
glBegin-glEnd - The command buffer or parameter is full, while
glBegin does not meet the corresponding glEnd - Requirement
- Make sure that glBegin and glEnd are matched in
each packet - Maitain completeness of primitive
42Subdivision of glBegin-glEnd
- ??2.1 glBegin????
- ?glBegin?glEnd?????????glBeginEnd,????1
- ?glVertex??????vtxCount,?????0
- ?nPrimtiveType???????
- glBegin?????????????
- glBegin??(????)??????????
- glBeginEnd 0
- nPrimitiveType glBegin????
43Subdivision of glBegin-glEnd
- ??2.2 glVertex????
- ?glVertex???????????
- ????????????
- if(glBeginEnd1)vtxCount,??????????
- ??2.3 glEnd??????
- ?glEnd???????????
- glBeginEnd1
- vtxVount0
44Subdivision of glBegin-glEnd
- ??2.4????????OpenGL???????
- if (glBeginEnd) then ??,?????????
- if(vtxCount 0 )??
- ????????????vtxBackdate
- ???????GL_TRIANGLES_FAN??GL_POLYGON,???????????,bR
ecoverFirst1 - ?glEnd???????????
- ?????????
- ??glBegin??
- if(bRecoverFirst 1)
-
- ??????????glBegin????
- ??????????glVertex?????????
-
- ??vBackdate?glVertex????
- ??????????OpenGL????????????????????????
45AnyGL
- Goal
- Architecture
- Command classification
- Analysis of Dependency Relation
- State Tracking
- Compression
- Scalability
46Command Classification
- OpenGL 1.3
- 17 kinds
- Four kinds in AnyGL
- primitive commands
- state commands
- remote remapping commands
- speical commands
47Remote Mapping Commands
- G-nodes send textures to R-nodes
- R-nodes receive textures from G-nodes
- For R-nodes
- textures with same texture ID may reresent
different textures, since they come from
different textures - textures with different texture IDs maybe same
texture.
48AnyGL
- Goal
- Architecture
- Command classification
- Analysis of Dependency Relation
- State Tracking
- Compression
- Scalability
49Analysis of Dependency Relation
- OpenGL is client/server based state machine, its
commands have serious order - See OpenGL 1.1 state machine
50Analysis of Dependency Relation
- Graphics Pipeline
- Transformation
- Lighting
- Rasterization
- Fragment
- According to OpenGL 1.3
- 17 categories
51AnyGL
- Goal
- Architecture
- Command classification
- Analysis of Dependency Relation
- State Tracking
- Compression
- Scalability
52State Tacking of AnyGL
- History of Sate Tracking
- Sate Tracking Based On Logic Timestamp
- Test Result
53History of State Tracking
- GLS, no
- GLR, pixel format
- GLX, X Windows, all 2d, pixelformat vertex array
- Multi-projector by Princeton, no
- Parallel Mesa, no
- Argus, notice the problem
54History of State Tracking
- M. Cox, parallel renderman
- WireGL, Dirty-bits, Lazy-update
- Chromium, user-defined
55State Tacking of AnyGL
- History of Sate Tracking
- Sate Tracking Based On Logic Timestamp
- Test Result
56State Tacking
- GLS
- GLR, Pixel Format
- GLX X Windows(R11) , Vertex Array
- M.Cox, RenderMan, Approximate
- WireGL
- Dirty-bits and Lazy-update
57State Tacking Based on Logic Timestamp
- G-node
- Maintain n1 virtual context,
- n is the number of R-nodes connected to this
G-node - The extra virtual context is called application
virtual context, same as the context of current
process - R-node
- Maintain m virtual context
- m is the number of G-nodes connected to this
R-node
58State Tacking Based on Logic Timestamp
- Application Virtual Context
- Always same as the context of the current process
- Active Virtual Context (G-node)
- If and only if it will be the command packages
destination - Active Virtual Context(R-node)
- If and only if it represents the source node of
the current command packet
59State Tacking Based on Logic Timestamp
- 5 Functions
- State tracking of G-node
- Context Difference
- Context Synchronization
- Context Switch
- State tracking of R-node
60(No Transcript)
61State Tacking on G-node
glLightf_state(light, pname, param) check
validate of parameters check change of the
light state if (changed) lightslight.pnamex
param lightslight.pnamex.timestamp lights
light.timestamp
62Context Difference
glLight_Diff(src, dest) if timestamp of src,
dest are equal return if (lighting.timestamp of
src,dest not equal dest.lighting.enable) pack
glEnable(GL_LGHTING) else pack
glDisable(GL_LGHTING) if( dst.lighting) for(I
0 I Ilt num_lights, I) if(lightI.timestamp of
src,dest not equal) pack changed parameters of
dest into geometry packet call difference
of material
63Context Synchronization
glFragment_synch(src, dest) if(
fragement.timestamp of src, dest are equal)
return if(src.fog.timestamp ! dest.
fog.timestamp) src.fog dest.fog src.fog.tim
estamp dest.fog.timestamp call
sychronization of depth
64Context Switch
glTransform_switch(src, dest)
if(transform.timestamp of src ,dest are
equal) return if(modelview.timestamp of src,
dest not equal) //call hardware
api glLoadMartix(dest_model_view) src.modelview
dest.modelview src. modelview.timestamp
dest. modelview.timestamp call
projection switch of src , dest
65State Tracking on R-node
- Similar to state tracking on R-node
- It call hardware API directly
66State Tacking of AnyGL
- History of Sate Tracking
- Sate Tracking Based On Logic Timestamp
- Test Result
67State Tracking Performance
- It is almost as fast as WireGL
- Context Difference is fast
- Context Switch is fast
- Context synchronization
- lt 1 microsecond
68(No Transcript)
69(No Transcript)
70AnyGL
- Goal
- Architecture
- Command classification
- Analysis of Dependency Relation
- State Tracking
- Compression
- Scalability
71Compression
- Image Compression
- Geometry Compression
- Normal
- Position
- Color
72Image Compression
- VCM(Video Compression Manager)
- Default Color Image Compression
- HUFFYUV
- Default Grayscale Image Compression
- JPEG-LS
73Geometry Compression
- Deering95
- Normal
- Position
- Color
74Geometry Compression
- Normal
- Deer95 software implementation
- 18-bits
- Programmer can choose compression precision
75Geometry Compression
- Position
- Linear Prediction,
- GL_POINT, GL_LINES, GL_LINESTRIP,
GL_TRIANGLES,GL_QUADS - Circle prediction,
- GL_POLYGON, GL_LINE_LOOP
- Parallelogram prediction,
- GL_TRIANGLE_STRIP, GL_QUAD_STRIP
- Fan Prediction
- GL_TRIANGLE_FAN
-
76Circle Prediction
Parallelogram Prediction
77Triangle Fan Prediction
78Geometry Compression
79Geometry Compression
Triangle fan prediction
80AnyGL
- Goal
- Architecture
- Command classification
- Analysis of Dependency Relation
- State Tracking
- Compression
- Scalability
- Parallel Graphics API
81Scalability
- Scalability of Parallel System
- Component
- System Size
- Problem Size
82Scalability
- 5 Parameters in Pomegranate,
- Triangle input rate
- Triangle Rendering Rate
- Pixel Rate
- Texture Size
- Display Resolution
83Scalability of Nodes
- G-node
- Pack capability, 20M triangles /s
- R-node
- Render capability
- C-node
- Composite capability
- D-node
- Display Resolution
84Scalability of Nodes
- No Node Number Limit
- Main bottleneck
- Network Bandwidth
- Compression is Adopted to solve the bottle- neck
- Geometry Compression
- Image Compression
85AnyGL
- Goal
- Architecture
- Command classification
- Analysis of Dependency Relation
- State Tracking
- Compression
- Scalability
- Parallel Graphics API
86Parallel Graphics API
- Traditional Parallel Programming
- Parallel Graphics API in Argus
- Global Share Extension of AnyGL
- Parallel Programming Frame of AnyGL
87Traditional Parallel Programming
- Single Process, Vector Machine, HPF and Fortran
90 - DSM
- Message Passing, PVM, MPI,
- Multi-Process, global variables, SGI Power C,
p-tread
88Parallel Graphics API in Argus
- Barrier
- Distributed Mutex
- Typical Application
- Volume Rendering
89Global Share Extension
- Assume
- m G-nodes have same texture tex0
- Tex0 occupies K MB memory
- Each R-node allocate M K MB memory to store
Tex0!
90Global Share Extension
- GL_TEXTURE_nD, n 1, 2, 3
- Local Texture
- R-node allocates memory for each local texture
- GL_GLOBAL_TEXTURE_nD, n 1,2,3
- Global Texture
- R-node allocates shared memory for global texture
91Global Share Extension
- GL_GLOBAL_TEXTURE_nD, n 1,2,3
92Parallel Frame of AnyGL
- int main(int argc, char argv)
- glboals.bWorking 1
- globals.M_PolygonMode GL_FILL
- globals.S_PolygonMode GL_FILL
- MPI_Init(argc, argv) /MPI???/
- MPI_Comm_rank( MPI_COMM_WORLD, rank_id)
- MPI_Comm_size( MPI_COMM_WORLD, nprocs )
- if(rank_id 0) /?????/
- MasterGUIInit(argc, argv) /??GUI??/
- Create_Context() /??GLcontext/
- MasterMainLoop(Display)
- else /?????/
- Create_Context()
- for() Displau()
-
- MPI_Finalize( ) / ??????/
- return 0
93Contents
- Goal of Computer Graphics Architecture
- Parallel Graphics Architecture
- AnyGL in Details
- Conclusion
- Further Research
94Conclusion
- 1.AnyGL is a larger-scale hybrid distributed
graphics system, which has integrated sort-first
and sort-last parallel graphics architecture. It
provides unlimited scalability for distributed
graphics system. - 2.Its virtual parallel graphics pipeline is
composed of 4 kinds of logic nodes, G-Node,
R-Node, C-Node, D-Node
95- 3. A new kind of dependency relation, graphics
context dependency relation of OpenGL pipeline,
is analyzed for distributed graphics architecture
in details. - 4. A new state-tracking algorithm is implemented
in AnyGL, which is called Logic Timestamp
Graphics State Tracking. - 5. Image compression and geometry compression are
deeply exploited in AnyGL.
96- 6. A new parallel programming interface, global
share of texture object and display list, are
proposed for future parallel graphics
architecture research. - AnyGL provides a new solution for larger scale
distributed graphics system in theory.
Performance test proves the high scalability of
AnyGL. It does not limit the nodes number of
logic node. Graphics state tracking algorithm
based on Logic timestamp introduces almost no
extra overheads. It research is the basis of LAN
larger scale distributed graphics system.
97Further Research
- D3D
- COM ? DCOM
- Parallel of Stream Based Graphics Architecture?
- Global Illumination for Parallel Architecture
- Programmable Shading Language Support for
Distributed Graphics System?
98Thanks for Your Attention!