Developing a Content Pipeline for a Video Game
Total Page:16
File Type:pdf, Size:1020Kb
Antti Veräjänkorva Art Is A Mess: Developing A Content Pipeline for A Video Game. Metropolia University of Applied Sciences Master of Engineering Information Technology Master’s Thesis 7 July 2020 PREFACE I have a dream that I can export all art asset for a game with single button press. I have tried to achieve that a couple times already and never fully accomplished in this. This time I was even more committed to this goal than ever before. This time I was deter- mined to make the life of artists easier and do my very best. Priorities tend to change when a system is 70% done. Finding time to do the extra mile is difficult no matter how determined you are. Well to be brutally honest, still did not get the job 100% done, but I got closer than ever before! I am truly honoured for all the help what other technical artists and programmers gave me while writing this thesis. I especially want to thank David Rhodes, who is a long- time friend and colleague, for his endless support. Thank you Jukka Larja and Kimmo Ala-Ojala for eye opening discussions. I would also like to thank my wife and daughter for giving me the time to write this thesis. Thank you, Hami Arabestani and Ubisoft Redlynx for giving me the chance to write this thesis based on our current project. Lastly thank you Antti Laiho for supervising this thesis and your honest feedback while working on it. Espoo, 06.06.2020 Antti Veräjänkorva Abstract Author Antti Veräjänkorva Title Art is a mess: Developing A Content Pipeline for A Video Game Number of Pages 47 pages + 3 appendices Date 7 Jul 2020 Degree Master of Engineering Degree Programme Information Technology Instructor(s) Hami Arabestani, Project Manager Antti Laiho, Senior Lecturer The topic of this thesis was to research how to improve exporting process in a video game content pipeline and implement the improvements. Games have numerous visual assets which all must be exported. Doing that manually every time is time consuming. Optimizing the export process can significantly save time and auto- mating the exporting process makes exporting easy and simple. The faster the exports, the more iterations can be done and number of iterations equals better quality games. In order to create an export tool which work also in batches and is stable and automatic, the tool alone will not be enough. There must be a supporting system or a base system to pro- vide additional meta data for the asset so that the computer can autonomously execute the export process without human interaction. The base system was written first in order create required meta data. The base system was written mostly with Python programming language and some smaller parts were written with Mel and Batch languages. All data was stored in JSON data format. Using meta data provided by the base system, a fully automated export tool which does not require human interaction was written in order to export asset to the game. The export tool was written into two content creation applications, Blender and Maya. In both applications, export tools were written with Python programming language. Creating the system included research, solution proposal and implementation of it. Research heavily relay on interviews since there is not much of descriptions of similar systems as written articles. However many companies do create similar system and best to find infor- mation about them was to ask from the people who made them. There was three interviews in total and interviews confirmed that companies do create similar systems and gave lot of implementation tips and tricks. The base system and exporter completed during this project successfully improve the effi- ciency of the export process by nearly 6 000 %. The base system improved data quality and reduced the number of human made mistakes. Automated exporting also improved working quality for artists by removing flow breaking manual exporting. Keywords Export assets, Plugin development, Automated Processing, Maya, Blender Abstract Antti Veräjänkorva Tekijä Taide on sotkuista: sisällöntuotannon automaatio videopelin Otsikko kehityksessä. Sivumäärä 47 sivua + 3 liitettä Päivämäärä 22.8.2020 Tutkinto Master of Engineering Tutkinto-ohjelma Information Technology Ohjaajat Projektipäällikkö Hami Arabestani Lehtori Antti Laiho Opinnäytetyön tarkoituksena oli tutkia, miten optimoida peliresurssien vientioperaatiota ja implementoida parannukset. Peleissä on useita visuaalisia resursseja, jotka jokainen pitää viedä peliin erikseen. Tämän tekeminen käsin vie aikaa. Vientiprosessin optimointi ja automaatio voi nopeuttaa vientiprosessia ja tehdä siitä vaivattoman. Nopea vienti ja iteraatioiden suuri määrä parantaa pelin laatua. Sellaisen vientityökalun luominen, joka toimii useille resursseille ja toimii vakaasti ja automaattisesti, vaatii tukijärjestelmän tai pohjajärjestelmän, joka antaa tarvittavaa lisätietoa vietävästä resurssista. Lisätiedon perusteella tietokone pystyy suorittamaan vientiprosessin täysin itsenäisesti ilman ihmisen apua. Pohjajärjestelmä oli tehtävä ensin, jotta sen tuoma lisäinformaatio olisi ylipäätään luotavissa. Pohjajärjestelmä kirjoitettiin pääosin Python-ohjelmointikielellä, joskin osia siitä on kirjoitettu myös Mel- ja Batch-kielillä. Tiedon tallennukseen käytettiin JSON-dataformaattia. Pohjajärjestelmän tarjoaman lisätiedon avulla luotiin täysin automaattinen vientityökalu, joka ei tarvitse ihmistä pystyäkseen viemään mallin peliin. Vientityökalu kirjoitettiin kahteen sisällöntuontuotanto-ohjelmistoon, Blenderiin ja Mayaan. Työkalu kirjoitettiin molemmissa ohjelmissa Python-ohjelmointikielellä. Järjestelmän luominen vaati tutkimusta, ehdotuksen järjestelmästä ja sen implementoinnin. Tutkimus tehtiin pitkälti haastattelujen varassa, koska artikkeleja aiheesta oli hyvin hankala löytää. Kuitenkin yritykset usein luovat vastaavia järjestelmiä ja paras tapa saada niistä tietoa oli kysyä ihmisiltä, jotka ovat ne tehneet. Haastatteluja oli yhteensä kolme, ja niistä kävi ilmi, että muutkin yritykset luovat vastaavia järjestelmiä omiin projekteihinsa, ja lukuisia yksityiskohtia niiden toiminnasta. Valmis pohjajärjestelmä ja vientityökalu onnistuneesti nopeutti vientiprosessia liki 6 000 %. Järjestelmä paransi resurssien laatua ja vähensi ihmisen tekemien virheiden määrää. Automaattinen vientiprosessi myös parantaa taiteilijoiden työpäivän mielekkyyttä, koska ei ole taidetyötä katkaisevaa monimutkaista vientiprosessia tehtävänä. Avainsanat Resurssien vienti, laajennusten kehitys, prosessiautomaatio, Maya, Blender Contents Preface Abstract List of Abbreviations 1 Introduction 1 1.1 Art Techincal Guideline 2 1.2 About Ubisoft Redlynx 3 1.3 About Ubisoft 4 1.4 About this study 5 2 Research 6 2.1 Initial discussions with artists 6 2.1.1 Autodesk Maya 8 2.1.2 Blender 8 2.2 Content Pipeline Breakdown 8 2.2.1 Export mesh 10 2.2.2 Assign material 10 2.2.3 Create materials 10 2.2.4 Export maps 10 2.2.5 Import to Unity 10 2.2.6 UV Mapping 11 2.3 Asset Postprocessor 11 2.4 Breakdown the export step 11 2.5 Timing the export step 15 2.6 External interviews 16 2.6.1 Remedy 17 2.6.2 Housemarque 17 2.6.3 Frozenbyte 18 2.6.4 Custom exporter 19 2.6.5 Digital content creation tools 19 2.6.6 Version control 19 2.6.7 Programming language 20 2.7 Conferences 20 2.7.1 GDC 22 2.7.2 Ubisoft Developer Conference 23 2.8 Literature study 23 2.9 Other sources 23 3 Solution Proposal 24 3.1 Purpose 24 3.2 Redlynx DCC Tools 24 3.3 Application 24 3.4 Multiple Projects 25 3.5 Programming Languages 25 3.6 Version Control 26 3.7 Custom File Structure 26 3.8 Custom File Formats 26 3.9 Installing the Redlynx DCC Tools 27 3.10 Application Versions 28 3.11 Redlynx Object 28 3.12 Automated Export 28 3.13 Outsourcing 29 4 Solution Implementation 30 4.1 Redlynx DCC Tools 30 4.1.1 Access to the Redlynx DCC Tools 30 4.1.2 File structure 30 4.1.3 Start-up logic 32 4.1.4 Loading global projects 33 4.1.5 Loading local projects 34 4.1.6 Application specific start-up 34 4.2 Application specific code 35 4.2.1 Project specific start-up for Maya 35 4.2.2 Project specific start-up for Blender 35 4.3 Redlynx Object 35 4.3.1 Maya’s Redlynx Object 36 4.3.2 Blender’s Redlynx Object 36 4.4 Export Tool 37 4.4.1 Export Process with Maya 38 4.4.2 Exporting Process with Blender 38 4.5 Future Improvements 39 5 Results 41 5.1 Speed 42 5.2 Improved Data Quality 42 5.3 Logical File Locations 43 5.4 Simpler export process 43 5.5 User feedback 44 6 Conclusion 46 References Appendices Appendix 1. Interview of David Rhodes Appendix 2. Interview of Jukka Larja Appendix 3. Interview of Kimmo Ala-Ojala List of Abbreviations MB Project name for the Redlynx project where the system in this thesis is de- veloped for. FBX FilmBox file format. Commonly used to store 3D data. KPI Key Performance Indicator. 1 1 Introduction A video game usually uses audio-visual elements, which we later in this study call assets, to communicate to a player what is happening in the game. Communication can some- times be merely functional when the quality of the art asset is not as important as seen in figure 1. Figure 1. Screen capture from a game Papers, Please [1] In Papers, Please player is an immigration officer who decides if a person can get through the border or not. Each applicant’s background must be checked to know if this person comes with good intensions. The art style is simple since the game is made by a single person, but still the game has plenty of assets. This kind of small, but often inno- vative games are sometimes called Indie Games. In Papers, Please art assets are much simpler than in games made by big companies such as Rockstar which tend to make AAA-titles. AAA-title refers to big games, made by hundreds, if not thousands, of developers. These kinds of games use visual assets to emerge the player into the game world such as Red Dead Redemption 2 in figure 2.