porting from pc to xbox - technical challenges

13
PORTING FROM PC TO XBOX TECHNICAL CHALLENGES Nihav Jain Brian Bennett

Upload: nihav-jain

Post on 18-Feb-2017

359 views

Category:

Education


6 download

TRANSCRIPT

Page 1: Porting from PC to XBOX - Technical Challenges

PORTING FROM PC TO XBOXTECHNICAL CHALLENGES

Nihav JainBrian Bennett

Page 2: Porting from PC to XBOX - Technical Challenges

Outline• Audio• OpenGL to DirectX• Box2D and TinyXML• Angry Birds specific

Page 3: Porting from PC to XBOX - Technical Challenges

Implementing Audio on XBOX• Used FMOD on the PC version, really simple and easy-to-use library

• FMOD didn’t port to XBOX so had to switch to XACT

• “Building” the sound bank• Limited documentation about XACT lead a lot of time being wasted in realizing

that the sound bank had to be pre-built and then used in the project

• Only some particular file formats work with XACT (WMA)

Page 4: Porting from PC to XBOX - Technical Challenges

OpenGL to DirectX• Y – axis is opposite in the two

• Solution -> y = ScreenHeight – y;

• Screen resolution on XBOX was 640x480 as compared to 1920x1080 on PC• Solution -> ScaleX = TargetScreenWidth / IdleScreenWidth,

ScaleY = TargetScreenHeight / IdleScreenHeight

• The center of rotation for the textures in DirectX was based on the local coordinates of the texture whereas OpenGL took that in screen space

• The direction of rotation was opposite in OpenGL and DirectX

• Textures were supposed to be square in shape with the image dimensions in powers of 2

Page 5: Porting from PC to XBOX - Technical Challenges

Porting Box2D and TinyXML to XBOX• Box2D had windows.h included in a few files

• Replaced references to windows.h components with their XBOX counterparts

• TinyXML used basic file operations like fopen, fread etc. which are not allowed on XBOX• Read XML using XBOX XDK file functions• Bypassed the file read functions of TinyXML and provided it directly with a

character stream

• Mapping the sprites to the actual Box2D physics bodies was difficult

Page 6: Porting from PC to XBOX - Technical Challenges

Angry Birds Specific Challenges• Implementing different bird abilities

• Implementing slingshot

• Different damage states for the birds, blocks and pigs

• Level design, balancing physics parameters

Page 7: Porting from PC to XBOX - Technical Challenges
Page 8: Porting from PC to XBOX - Technical Challenges
Page 9: Porting from PC to XBOX - Technical Challenges
Page 10: Porting from PC to XBOX - Technical Challenges
Page 11: Porting from PC to XBOX - Technical Challenges
Page 12: Porting from PC to XBOX - Technical Challenges
Page 13: Porting from PC to XBOX - Technical Challenges

Question?Nihav JainBrian Bennett