I was going over the Game Developer's Conference schedule for 2006 and came across this session entitled "Collada for the PlayStation3". The reason it caught my eye is that Collada is a specification put forth by the Khronos Group, which I had read about in my SVG research.


The Khronos Group is a collection of parties in the multimedia hardware industry that is:

focused on the creation of open standard APIs to enable the authoring and playback of dynamic media on a wide variety of platforms and devices

Members includes heavy mobile players like Nokia, Ericsson, and Motorola, video and audio card manufacturers like ATI, nVidia, and Creative, component manufacturers like Panasonic, Philips and Toshiba, high-end workstation folks like SGI and Sun, and gaming console manufacturers like Sony. It's a huge gang with some notable exceptions.

The first time I heard of Khronos was last year when they released OpenVG 1.0. OpenVG is an API for hardware accelerated vector and raster graphics, which means it is the 2D equivalent to OpenGL.

Speaking of OpenGL, one of the first tasks of the Khronos Group when it initially formed was to take the OpenGL specification and define a subset that could be used in embedded devices (like mobile phones and gaming consoles). Embedded devices serve a particular purpose and thus, support for all OpenGL features might not be required. This subset API specification was written by Khronos and dubbed OpenGL ES.

Now we come to their latest venture: Collada. Collada is a schema that enables the common exchange of digital assets for 3D applications. In this context, "digital assets" are any resources that are needed to supply the actual 3D game content (models, textures, light sources, shaders, animations, etc). Here, "common exchange" means the ability to pass around these digital assets from one tool to another without having to worry about converting from one particular file format to another.

The Khronos Group chose XML as the base grammar for this format. Describing complex assets like 3D models using text instead of a binary format may seem a little crazy at first, but it doesn't surprise me really, for reasons that the Collada specification points out:

  • issues with character sets are already accounted for in XML
  • XML is "plain text" and is easy enough to understand just by looking at the file
  • XML is easily extensible (that's the 'X'), thus content creators can add tool-specific information to the assets while still conforming to the Collada schema
  • there are XML parsers for nearly every available platform

Furthermore, the spec states that this schema is not intended as the final format for delivery in a product for end-users. This schema is really to help streamline the content generation process, not fulfill any need for the final product.


A common schema to describe 3D geometry, light sources, skins and animation frames sounds incredibly useful - and incredibly complex. But these people are experts so I'm sure they'll get the contents right. To me, what's really important is how conforming tools in the industry are. I'd really like to know how far particular versions of Collada have penetrated into the tool markets. The GDC speaker (Rémi Arnaud) plans to showcase a modern toolset that supports the latest Collada specification. But do products like 3DS Max and Maya support it? If so, how conforming are they? A "common" format is only common if a large enough slice of tools/products support it. Is this really just a "Sony Playstation" only thing?

For instance, the lag-time on SVG adoption has been incredible. One big difference here is that SVG needs to penetrate not just into the tools but also into the libraries and into the end products (mobile phones, browsers, etc). It's only now, more than 5 years after it was originally introduced that mobile phones, graphics libraries, toolkits and browsers are really beginning to support SVG. In contrast, Collada needs only to make inroads into the tool vendors and with such a large group of parties involved in Khronos (as compared to W3C) perhaps their progress will be met with a higher degree of cooperation. Since I'm not directly involved in the industry, I have no clue so this is one thing I'm curious about.

Collada 1.4 was released in January of this year so it's fresh off the presses, so to speak. The GDC session talks about the new bits in 1.4: Collada FX and Collada PhX. Collada PhX actually attempts to define physics in a common format. Collada FX attempts to define effects (pixel shaders?) in a common format. Unfortunately not a lot of background information is given on the two new additions.

I read through the first 10 or so pages and then skimmed the rest of the 293-page specification to try and get a feel for it.

I noticed that Collada FX has a <code> element for inlining blocks of shader source code. The last thing I remember learning about shader languages (though this was two years ago by now) was that they were very fractured with at least three similar, but not identical, code formats: Microsoft had HLSL (DirectX API flavour), OpenGL had GLSL for its API, and nVidia had defined Cg which paid no allegiance to either API (but obviously has a hardware bias). I had thought that Collada FX was an attempt to abstract away from a particular format, but the ability to inline arbitrary shader code seems to go against that. There's an <include> element that does something similar (includes shader code from an external file). It's entirely possible that I'm misunderstanding the purpose of Collada FX, and that's why I'll be looking into attending this session.

Also, a nitpick, but under the "Remarks" section it states:

Inlined source code must have all XML identifier characters escaped, for example, converting “<” to “&lt;”.

I wonder why they didn't allow CDATA to be used? tsk tsk tsk ...


§210 · January 21, 2006 · Games, GDC, Software, Technology, XML · · [Print]

Leave a Comment to “GDC 2006: Collada on the PS3”

  1. Steven says:

    Saw this on SourceForge: http://sourceforge.net/projects/colladamaya/
    This plug-in allows Maya to exchange 3D assets in the Collada document format.

  2. Robin Green says:

    Excellent! We’ll have at least one attendee! Glad you like the ideas of COLLADA, we hope to sell you fully on the idea of asset management and interchange, with reconfigurable production pipelines. That’s the ultimate goal of the COLLADA project.

    Why no CData for scripts? Because the XML was defined using XML Schema language and not DTDs. We used the xs:string datatype for scripts whic, unfortunately, requires escaped source code. What type do you think we should have used?

    – Robin Green, Chair of COLLADA FX Working Group

  3. Jeff Schiller says:

    Robin,

    Thanks for the comment. I am definitely no XML Schema or DTD expert, so I will concede to your greater knowledge in this area. It seems surprising that there are things you can do in a DTD that you can’t in XML Schema, but I’m sure there was a reason for that…

    I look forward to the session.

    Regards,
    Jeff

  4. Steven Ho in Napervillek IL says:

    Mr. Schiller,

    Thanks for posting the nice article on SVG and the example. It’s truely inspiring. Keep up the good work. ^_^ I just moved to Chicago from Vancouver and I’m wondering if there is any networking event for software developers? Would be nice to know some developers arround this area.