gl tf siggraph-2013

18
© Copyright Khronos Group 2013 | Page Fabrice Robinet COLLADA Working Group Chair. graphics library Transmission Format https://github.com/KhronosGroup/glTF Wednesday, July 24, 13

Upload: khaled-mamou

Post on 25-Dec-2014

513 views

Category:

Technology


0 download

DESCRIPTION

 

TRANSCRIPT

Page 1: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

Fabrice RobinetCOLLADA Working Group Chair.

graphics library Transmission Formathttps://github.com/KhronosGroup/glTF

Wednesday, July 24, 13

Page 2: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

Overview

•status•motivations•design principles•glTF pipeline

•scope•glTF... and what more ?•demos

Wednesday, July 24, 13

Page 3: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

Status

•COLLADA Working group initiative.•Work in progress - Not a ratified specification yet.•Code work and SPEC work at the same time.•SPEC currently catching up with the converter.•Community feedback welcomed on GitHub.

Wednesday, July 24, 13

Page 4: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

Motivations

•Bridge the gap between 3D formats and GL based APIs.•Reduce duplicated effort in content pipeline.•A common format for contents providers.

Wednesday, July 24, 13

Page 5: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

Design principles

•Streamline rendering: size, speed and ease of implementation•Offload processing from runtime.•Maps well to GL APIs and Typed Arrays.•Neutral, specify higher level only when necessary.

Wednesday, July 24, 13

Page 6: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

glTF Pipeline - overview

OpenCOLLADA Compression

COLLADA2GLTF C++ Library

Rapidjson

COLLADA2GLTF command line tool

Rest3Dtransactions & access to 3D assets

COLLADA2GLTF DeliveryAuthor Interchange API

Maya

Blender

..

COLLADA glTF

OpenGL/ES

WebGL

OpenGL

Converter

Wednesday, July 24, 13

Page 7: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

glTF Pipeline - COLLADA2GLTF

• Triangulate

• Unify indices

• Split meshes

• Generate shaders• Axis up conversion

• Minify shaders

• Flatten hierarchy & combine meshes

• Convert images

• Compress meshes• Interleave vertices

• ... Suggestions welcomed !

Mandatory transformations

Planned optimizations & transformations

Wednesday, July 24, 13

Page 8: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

Scope

•1.0- Node hierarchy- Cameras- Lights- Key-framed animations- Skinning- Morphing- Medias (images & videos)

•mesh compression as extensions

•multi-pass considered.

Wednesday, July 24, 13

Page 9: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

Compression

•Tested 2 compression libraries:- Open3DGC: https://github.com/amd/rest3d/tree/master/server/

o3dgc- webgl-loader: https://code.google.com/p/webgl-loader/

Wednesday, July 24, 13

Page 10: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

Open3DGC

•Open3DGC Binary is an implementation of the MPEG-SC3DMC (Scalable Compression 3D Mesh Compression)

•K. Mammou, T. Zaharia, F. Prêteux, “TFAN: A low complexity 3D mesh compression algorithm” Computer Animation and Virtual Worlds, Vol. 20(2-3), pp. 343–354, 2009

•2 modes: binary and ascii.- Open3DGC Binary exploits an adaptive arithmetic-based encoding to

exploit statistical properties of the encoded data- Open3DGC ASCII exploits a 7-bit ASCII encoding adapted for GZip

compression- Open3DGC ASCII is a slightly modified version of SC3DMC to

exploit GZip compression

Wednesday, July 24, 13

Page 11: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

ModelCOLLADACOLLADA glTFglTF glTF+Open3DGC

asciiglTF+Open3DGC

asciiglTF+Open3DGC

binaryglTF+Open3DGC

binaryModel

XML gzip raw gzip raw gzip raw •raw bin•gzip JSON

• bin:102k• JSON:11k

• bin:81k• JSON:2kb

• ascii:29k• JSON:11k

• ascii:19k• JSON:2k

• bin:18k• JSON:11k

• bin:18k• JSON:2k

336k 106k 113k 83k 40k 21k 29k 20k• bin:9220k• JSON:75k

• bin:3220k• JSON:5k

• ascii:3080k• JSON:151k

• ascii:1510k• JSON:11k

• bin: 1622k• JSON:151k

• bin: 1622k• JSON:11k

19767k 3417k 9295k 3225k 3231k 1521k 1773k 1633k

• bin:25224k• JSON:183k

• bin:5738k• JSON:8k

• ascii:7793k• JSON:587k

• ascii:1433k• JSON:29k

• bin:3205k• JSON:589k

• bin:3205k• JSON:29k

56763k 7378k 25407k 5746k 8380k 1462k 3794k 3234k

• bin:329k• JSON:255k

• bin:99k• JSON:10k

• ascii:122k• JSON:267k

• ascii:61k• JSON:11k

• bin:71k• JSON:267k

• bin:71k• JSON:11k

794k 133k 584k 109k 389k 77k 338k 88k

NOT final numbers - will be refined with integration improvements.

Wednesday, July 24, 13

Page 12: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

Compression: results overview

data from rest3d SigGraph 2013 BOF presentation, Khaled Mammou/Remi Arnaud

Wednesday, July 24, 13

Page 13: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

Open3DGC compression

•First integration within “collada2gltf” available on GitHub.- naive integration to be improved (leading to better compression).

•Encoder/Decoder in C++•Just to get it working quickly, converted code using emscripten to javascript.

•Decoding performance to be evaluated in JS.

Wednesday, July 24, 13

Page 14: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

“webgl-loader” compression

• First integration within “collada2gltf” available on GitHub.- naive integration to be improved (leading to better compression).

• Encoder in C++/Decoder in JS

• Fast decoding.

Model COLLADACOLLADA glTF+webgl-loaderglTF+webgl-loader glTF+Open3DGC asciiglTF+Open3DGC ascii glTF+Open3DGC binaryglTF+Open3DGC binaryModelXML gzip raw gzip raw gzip raw •raw bin

•gzip JSON

• utf8:42k• JSON:12k

• utf8:34k•JSON:2kb

• ascii:29k• JSON:11k

• ascii:19k• JSON:2k

• bin:18k• JSON:11k

• bin:18k• JSON:2k

336k 106k 54k 36k 40k 21k 29k 20k•utf8:8747k• JSON:753k

•utf8:1325k• JSON:29k

• ascii:7793k• JSON:587k

• ascii:1433k• JSON:29k

• bin:3205k• JSON:589k

• bin:3205k• JSON:29k

56763k 7378k 9500k 1354k 8380k 1462k 3794k 3234k

NOT final numbers - will be refined with integration improvements.

Wednesday, July 24, 13

Page 15: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

Compression: next steps

•Fix integration issues: currently both Open3DGC and webgl-loader do not handle shared vertex buffer by multiple index buffers. Needed some vertex duplication to work-around this.

•Benchmark for decoding performance and memory footprint.

•Compress animations, bones indices and weight

Wednesday, July 24, 13

Page 16: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

glTF... and what more ?

•package not only “models” but whatever you need a declarative way•For instance, the viewer uses glTF “techniques” to:- draw the background gradient- setup the specific image based picking shaders

Wednesday, July 24, 13

Page 17: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

Demos

•Montage Model Viewer•MegaCity & Video demo•Skinning

Wednesday, July 24, 13

Page 18: Gl tf siggraph-2013

© Copyright Khronos Group 2013 | Page

Thank you - See you on GitHub !

Specification : https://github.com/KhronosGroup/glTF/blob/master/specification/README.mdconverter : https://github.com/KhronosGroup/glTF/convertermontagejs viewer : https://github.com/fabrobinet/glTF-webgl-viewer

Wednesday, July 24, 13