Contents
Propagation of Visual Entity Properties Under Bandwidth Constraints
 
 
Printer-Friendly VersionPrinter-Friendly Version
 
Latest News
spacer View All spacer
 
November 22, 2009
 
Video Game Watchdog National Institute On Media And The Family Shutting Down [11]
 
Modern Warfare 2 Infinity Ward's 'Most Successful PC Version' Yet [12]
 
New Tech, Design Details Of Project Natal To Emerge At Gamefest In February
spacer
Latest Jobs
spacer View All     Post a Job     RSS spacer
 
November 22, 2009
 
Sucker Punch Productions
Character Artist
 
Sucker Punch Productions
3D Environment Artist
 
Sucker Punch Productions
Network Programmer
 
Sucker Punch Productions
Texture Artist
 
Sony Online Entertainment
Brand Manager
 
Monolith Productions
Sr. Software Engineer, Engine - Monolith Productions - #113767
 
Crystal Dynamics
Sr. Level Designer
 
Gargantuan Studios
Lead World Designer
spacer
Latest Features
spacer View All spacer
 
November 22, 2009
 
arrow Upping The Craft: Susan O'Connor On Games Writing [6]
 
arrow Small Developers: Minimizing Risks in Large Productions - Part II [6]
 
arrow iPhone Piracy: The Inside Story [48]
 
arrow And Yet It Grows: Analyzing the Size and Growth of the European Game Market [5]
 
arrow NPD: Behind the Numbers, October 2009 [13]
 
arrow Reflecting On Uncharted 2: How They Did It [5]
 
arrow Sponsored Feature: Rasterization on Larrabee -- Adaptive Rasterization Helps Boost Efficiency
 
arrow Postmortem: Wadjet Eye's The Blackwell Convergence [2]
spacer
Latest Blogs
spacer View All     Post     RSS spacer
 
November 22, 2009
 
Accepting the Inherent Value of Games
 
Planckogenesis, Part II: Song Structure & Gravy Train [1]
 
Designing Games Is About Matching Personalities [1]
spacer
About
spacer News Director:
Leigh Alexander
Features Director:
Christian Nutt
Editor At Large:
Chris Remo
Advertising:
John 'Malik' Watson
Recruitment/Education:
Gina Gross
 
Features
  Propagation of Visual Entity Properties Under Bandwidth Constraints
by Olivier Cado
0 comments
Share RSS
 
 
May 24, 2007 Article Start Previous Page 6 of 7 Next
 

5. Data Compression

Online games based on small geographical zones can use position coordinates local to zones, with low range needs. However, a large seamless environment theoretically deals with wide-range coordinates. On the server side, we have 32-bit integer positions with millimetre precision. An approach would be to alternate absolute positions and “smaller” positions relative to the latest absolute positions. However, this technique has strong sequentially constraints, which cannot be easily adapted to our best-effort (non-reliable) lightweight network protocol.

A more suited approach was based on the assumption that a client will only display the entities in the neighbourhood, within the square kilometer surrounding the viewer (Figure 6). Then, a virtual local basis can be used. Instead of translating positions from absolute basis to a basis relative to the viewer, a more CPU-effective method consists in using the “truncated absolute coordinate” algorithm.

Advertisement

The server transmits short entity coordinates, and, to save more bandwidth, also lowers the precision to 16-millimeter in a 1024 m window by dividing the coordinate by 16 (i.e. shifting down by 4 bits). No reference to the viewer’s position is needed:

  • uint16 ec_short = (uint16)(ec_full >> 4);

To reconstruct the full position of an entity, the client needs the following inputs:

  • Full viewer coordinates (uint321 vc_full).

  • Short entity coordinates (uint16 ec_short).

The client calculates the short viewer coordinates, and the short entity delta coordinates from the transmitted values, to finally deduce the full entity coordinates from the full delta (obtained by sign extension) and the damped viewer coordinates (to avoid entity flickering when the viewer moves):

  • uint32 vc_full_damped = vc_full & ~0xF;

  • uint16 vc_short = (uint16)(vc_full >> 4);

  • sint16 delta_short = (sint16)(ec_short – vc_short);

  • sint32 delta_full = ((sint32)delta_short) << 4;

  • uint32 ec_full = (uint32)(vc_full_damped + delta_full);

For the example in Figure 6:

Full X Coordinates:
Viewer: 0x2C0000
Entity A: 0x2E0000
Entity B: 0x260000
Entity C: 0x320000

Short Coordinates:

Viewer: 0xC000

Entity A: 0xE000

Entity B: 0x6000

Entity C: 0x2000

Short Delta:

Entity A: 0x2000

Entity B: 0xA000

Entity C: 0x6000

Full Delta:

Entity A: 0x00020000

Entity B: 0xFFFA0000

Entity C: 0x00060000

Figure 6: Local Position Window Example

If dealing with ground entities, the z-value (altitude) may be even more compressed, by referring to a layer index, provided the client software can access efficiently the 3D topography structure corresponding to a 2D value.

1 Basic types shown are from the NeL library: uint32 is 32-bit unsigned int, sint16 is 16-bit signed int, etc.

 
Article Start Previous Page 6 of 7 Next
 
Comments

none
 
Comment:
 


Submit Comment