Creating 2D Digital Art Assets for XNA Game Studio

Total Page:16

File Type:pdf, Size:1020Kb

Creating 2D Digital Art Assets for XNA Game Studio Creating 2D Digital Art Assets for XNA Game Studio Mark Thompson, [email protected] Department of Computer Science San Diego State University Spring 2010 Intended Audience The content of this document is directed towards digital artists (referred to as artist for rest of document) who charged with creating digital art assets for games, or applications, programmed using the Microsoft XNA Game Studio. However, some XNA programmers may also find this document useful, especially if they are creating digital assets themselves, or implementing a menu or Heads Up Display (HUD) system. What this document is NOT This is not a tutorial, or “how to”, on using an image editor, e.g. Adobe Photoshop or GNU Image Manipulation Program (GIMP). The assumption is that the artist is competent in using such image editing applications. Also, this is not a programming guide that provides the technical details of using and displaying digital art in XNA. There is a variety of resources, both books and Web, which provide extensive tutorials on this aspect of XNA programming. Lastly, this is a not guide for techniques in user- interface design. 1. Introduction No 2D, or 3D, XNA game can be created without an extensive collection digital art assets ranging from PNG images to 3D models. There are many books and articles about XNA game programming which are geared towards the technical aspects of programming. For these books, sample game code is often provided via the Web so that a programmer can download, compile, and then run the sample games. However, many of the digital art assets, specifically 2D assets, are simply just provided as is, with little background on why or how they were created. This article is to provide artists with little or no programming experience some background on creating usable 2D digital art for XNA. 2. The XNA Game Studio and Framework The Microsoft XNA Game Studio (currently version 3.1) is a set of programming tools based on supported versions of Microsoft Visual Studio, with C# as its programming language. These tools allow student and hobbyist programmers to build games for Microsoft Windows, the Microsoft Xbox 360, and the Microsoft Zune[1]. The XNA Framework is built on Microsoft’s Direct X technology, with its graphics system using core Direct3D 9 graphics technology. So, what does this mean to an artist? XNA is a very powerful and complex programming toolset for creating highly-interactive, graphically intense, 2D and 3D games for the above mentioned platforms. File Formats for 2D Digital Artwork Figure 1 lists the file formats which are acceptable for use with XNA. This information was collected from [2, 3, 4, 5]: .bmp Windows bitmap for graphics files within the Microsoft Windows; typically uncompressed; a simple format with wide acceptance in Windows programs [2]. .dds DirectDraw Surface file format by Microsoft; stores graphical textures and cubic environment maps as a data file. [ 5] ; uncommon outside of 3D programming; specifically designed for Direct X. .dib Device Independent Bitmap file; Generic Windows or OS/2 bitmap graphic; similar to a .BMP file [3]. .hdr High Dynamic Range Image File; Raster image or digital photo; uncommon. .jpg JPEG (Joint Photographic Experts Group) is a lossy compression method; JPEG-compressed images are usually stored in the JFIF (JPEG File Interchange Format) file format; JPEG/JFIF; also will see it as .jpeg .pfm Printer Font Metrics File; Adobe Type 1 font for Windows; uncommon. .png Portable Network Graphics file format; created as the free, open-source successor to the GIF. .ppm Portable Pixmap Image File; 24-bit color image that is formatted in text format .tga Targa Graphic file format; Bitmap image format ; has become a ubiquitous format for storing textures and screenshots from video games due to its ease of implementation and lack of encumbering patents. Figure 1. List of acceptable 2D image formats for the XNA Graphics Frameword. Although XNA accepts a variety of formats, it is not necessary to have knowledge of them all. Much of the artwork for menus and HUD’s is created using the PNG format. The next two sections will show examples which were taken from the game Rocket Commander, a free XNA sample game as described in the book “Professional XNA Programming : Building Games for Xbox 360 and Windows with XNA Game Studio 2.0” , 2nd Edition, by Benjamin Nitschke. 3. Technical Overview of Using 2D Art Assets in XNA Before continuing onto examples, there are some technical details that need mentioning. First, on how XNA handles 2D art work. All digital art assets artwork are “loaded” when the XNA application is started. This means that a given PNG will be available to the programmer throughout the lifetime of the application, that is, until the user quits. (NOTE: the programmer could release the PNG resource during runtime to save memory. However, for small games this may be less of an issue). Second, The XNA Graphics Framework provides some common operations for manipulating 2D images, namely: screen position, color tint, rotation, origin, and scale. In addition, the order in which the 2D images are drawn, as implemented by the programmer, may also be used for effect. For instance, you can layer multiple PNG’s to build menu screens since the PNG format contains transparency information. Third, drawing text can be accomplished in one of three ways: i) A PNG file can have text in it, e.g. a start button with “START” on it; ii) artist can provide an image file with a custom designed font; iii) use XNA’s native string drawing facilities, which is restricted to fonts installed on a user’s system, as well as font licensing restrictions. However, XNA does have a set of freely distributable fonts to distribute with games. Lastly, determining whether or not a user can interact (e.g. a mouse rollover) with a given 2D element, is a coordinated effort for the artist, and programmer. A designer may determine what buttons and when can be interacted with, an artist may actually create the button in an image editor, and finally the programmer will write the C# code to place and draw the 2D image to screen. All this may sound rather complex in order to just draw a 2D image to screen. XNA is extremely powerful and capable of making commercial quality games. With great power, comes complexity. Remember that XNA is not a toy programming environment, but a full-fledged graphics and game programming environment. 4. Example: Start Screen with Rollover Buttons Figure 2 is a screenshot of the initial screen when Rocket Commander is started. Although not visible in this static picture, the space scene with asteroids in the background is animated and gives the illusion of moving through space (this animation is a completely separate feature from the screen buttons). Figure 3 shows the two PNG files that make up this screen. Notice that the PNG images have transparent backgrounds, which is very common when using them in this context. Figure 2: The main menu for Rocket Commander running on a monitor at 1280 x 800. .
Recommended publications
  • Digital Photo Editing
    Digital Photo Editing Digital Photo Editing There are two main catagories of photo editing software. 1. Photo Organizers - Programs that help you find your pictures. May also do some editing, and create web pages and collages. Examples: Picasa, XNView, ACDsee, Adobe Photoshop Elements 2. Photo Editors - Work on one picture file at a time. Usually more powerful editing features. Examples: Adobe Photoshop, Gimp, Paint.Net, Corel Paint Shop Photo Organizers Organizers tend to have a similar look and functionality to each other. Thumb nail views, a directory tree of your files and folders, and a slightly larger preview of the picture currently selected. A selection of the most used editing tools, and batch editing for making minor corrections to multiple pictures at once. The ability to create slide shows, contact sheets, and web pages are also features you can expect to see. XNView Picasa ACDsee Some of the editing features included in Photo Organizer software are: Red Eye Reduction, Rotate, Resize, Contrast, Color Saturation, Sharpen Focus and more. Many of these can be done in batch mode to as many pictures as you select. Picasa has added Picnik to it's tool set allowing you to upload your photo to the Picnik website for added editing features. Here is an example of Redeye removal in Picasa. Crop, Straighten, and Fill Light are often needed basic fixes. Saving and converting your picture file. In Xnview you can import about 400 file formats and export in about 50. For the complete list goto http://www.xnview. com/en/formats.html . Here is a list of some of the key file formats your likely to use and / or come across often.
    [Show full text]
  • Forcepoint DLP Supported File Formats and Size Limits
    Forcepoint DLP Supported File Formats and Size Limits Supported File Formats and Size Limits | Forcepoint DLP | v8.8.1 This article provides a list of the file formats that can be analyzed by Forcepoint DLP, file formats from which content and meta data can be extracted, and the file size limits for network, endpoint, and discovery functions. See: ● Supported File Formats ● File Size Limits © 2021 Forcepoint LLC Supported File Formats Supported File Formats and Size Limits | Forcepoint DLP | v8.8.1 The following tables lists the file formats supported by Forcepoint DLP. File formats are in alphabetical order by format group. ● Archive For mats, page 3 ● Backup Formats, page 7 ● Business Intelligence (BI) and Analysis Formats, page 8 ● Computer-Aided Design Formats, page 9 ● Cryptography Formats, page 12 ● Database Formats, page 14 ● Desktop publishing formats, page 16 ● eBook/Audio book formats, page 17 ● Executable formats, page 18 ● Font formats, page 20 ● Graphics formats - general, page 21 ● Graphics formats - vector graphics, page 26 ● Library formats, page 29 ● Log formats, page 30 ● Mail formats, page 31 ● Multimedia formats, page 32 ● Object formats, page 37 ● Presentation formats, page 38 ● Project management formats, page 40 ● Spreadsheet formats, page 41 ● Text and markup formats, page 43 ● Word processing formats, page 45 ● Miscellaneous formats, page 53 Supported file formats are added and updated frequently. Key to support tables Symbol Description Y The format is supported N The format is not supported P Partial metadata
    [Show full text]
  • Download App Png Png Viewer
    download app png Png viewer. Best viewer for psd design or png web template presentation tool because it has the slideshow feature. PSD Viewer. PSD file extension represent image file types that are created with the most commonly used professional image editing program, Adobe Photoshop. Similar choice. › Png to ico converter software.exe › Png to dds convert › Png to icon converter .exe › Png ico converter .exe › Png image to icon converter .exe › Png creator free download. Programs for query ″png viewer″ CDR Viewer. CDR Viewer is free for use software tool. This viewer can be used to open/display CorelDRAW image files and gives you and options to convert . jpg, .gif, . png , .tiff and . Except viewing and converting . , CDR Viewer supports resizing . Free Photoshop PSD Image Viewer. A free Photoshop® PSD image viewer, you can open, view PSD image and save PSD into BMP, JPEG, GIF or PNG. ® PSD image viewer , you can . open, view PSD image . , GIF or PNG . DDS Viewer. DDS Viewer is a free for use software tool. DDS Viewer can be used to open Microsoft DirectDraw Surface files . tool. DDS Viewer can be . .jpg, .gif, . png and others . ), Bitmap(.bmp), PNG (. png ), GIF(.gif . AI Viewer. Ai file type is associated as “Illustrator” by Adobe Systems Inc. PDF. Ai viewer is free . , Bitmap, GIF, PNG and other . formats, AI viewer supports resizing . ViewCompanion Pro. ViewCompanion Pro can be used to view, print, and convert Adobe PDF, Autodesk DWF, PLT, CGM, TIFF, CALS, PNG, HPGL/2, and many other formats. used to view , print, and . , TIFF, CALS, PNG , HPGL/2, and .
    [Show full text]
  • IDOL Connector Framework Server 12.0 Administration Guide
    Connector Framework Server Software Version 12.0 Administration Guide Document Release Date: June 2018 Software Release Date: June 2018 Administration Guide Legal notices Copyright notice © Copyright 2018 Micro Focus or one of its affiliates. The only warranties for products and services of Micro Focus and its affiliates and licensors (“Micro Focus”) are set forth in the express warranty statements accompanying such products and services. Nothing herein should be construed as constituting an additional warranty. Micro Focus shall not be liable for technical or editorial errors or omissions contained herein. The information contained herein is subject to change without notice. Trademark notices Adobe™ is a trademark of Adobe Systems Incorporated. Microsoft® and Windows® are U.S. registered trademarks of Microsoft Corporation. UNIX® is a registered trademark of The Open Group. Documentation updates The title page of this document contains the following identifying information: l Software Version number, which indicates the software version. l Document Release Date, which changes each time the document is updated. l Software Release Date, which indicates the release date of this version of the software. To verify you are using the most recent edition of a document, go to https://softwaresupport.softwaregrp.com/group/softwaresupport/search-result?doctype=online help. You will also receive new or updated editions of documentation if you subscribe to the appropriate product support service. Contact your Micro Focus sales representative for details. To check for new versions of software, go to https://www.hpe.com/software/entitlements. To check for recent software patches, go to https://softwaresupport.softwaregrp.com/patches. The sites listed in this section require you to sign in with a Software Passport.
    [Show full text]
  • Dds to Tga Converter Download Конвертер DDS В TGA
    dds to tga converter download Конвертер DDS в TGA. Сконвертируйте ваши dds-файлы в tga онлайн и бесплатно. Image Document Ebook Audio Archive Video Presentation Font Vector CAD. abc abw csv dbk djvu dng doc docm docx erf ebm ewm emw gzip kwd odt oxps ppt pptx pdf rtf rar txt wps xls xlsx zip. Image Document Ebook Audio Archive Video Presentation Font Vector CAD. abc abw csv dbk djvu dng doc docm docx erf ebm ewm emw gzip kwd odt oxps ppt pptx pdf rtf rar txt wps xls xlsx zip. Microsoft DirectDraw Surface. Изображение Truevision TGA (Targa) Как сконвертировать DDS в TGA. Загрузите dds-файл(ы) Выберите файлы с компьютера, Google Диска, Dropbox, по ссылке или перетащив их на страницу. Выберите «в tga» Выберите tga или любой другой формат, который вам нужен (более 200 поддерживаемых форматов) Загрузите ваш tga-файл. Позвольте файлу сконвертироваться и вы сразу сможете скачать ваш tga-файл. Convert image to TGA format. Use this free online image converter to convert your image to the TGA (Targa) format. Optionally apply enhancements and digital effects to alter your image. Error: the number of inputs exceeded the limit of 3 . In order to continue you need to upgrade your account: Error: the total file size exceeded the limit of 100 MB . In order to continue you need to upgrade your account: Error: the total file size exceeded the absolute limit of 8GB . For paid Accounts we offer: Up to 8GB total file size per conversion 200 files per conversion High priority conversion speed Completely adfree pages Money back guarantee.
    [Show full text]
  • COMPUTER MIXED Text Files • .Doc
    COMPUTER MIXED Text Files .doc - Microsoft Word Document .docx - Microsoft Word Open XML Document .log - Log File .msg - Outlook Mail Message .odt - Open Document Text Document .pages - Pages Document .rtf - Rich Text Format File .tex - LaTeX Source Document .txt - Plain Text File .wpd - WordPerfect Document .wps - Microsoft Works Word Processor Document Data Files .csv - Comma Separated Values File .dat - Data File .efx - eFax Document .epub - Open eBook File .pps - PowerPoint Slide Show .ppt - PowerPoint Presentation .pptx - PowerPoint Open XML Presentation .sdf - Standard Data File .xm - XML File Audio Files .aif - Audio Interchange File Format .iff - Interchange File Format .m3u - Media Playlist File .m4a - MPEG-4 Audio File .mid - MIDI File .mp3 - MP3 Audio File .mpa - MPEG-2 Audio File .ra - Real Audio File .wav - WAVE Audio File .wma - Windows Media Audio File Video Files .3g2 - 3GPP2 Multimedia File .3gp - 3GPP Multimedia File .asf - Advanced Systems Format File .asx - Microsoft ASF Redirector File .avi - Audio Video Interleave File .flv - Flash Video File .mov - Apple QuickTime Movie .mp4 - MPEG-4 Video File .mpg - MPEG Video File .rm - Real Media File .srt - SubRip Subtitle File .swf - Shockwave Flash Movie .vob - DVD Video Object File .wmv - Windows Media Video File 3D Image Files .3dm - Rhino 3D Model .max - 3ds Max Scene File .obj - Wavefront 3D Object File Raster Image Files .bmp - Bitmap Image File .dds - DirectDraw Surface .gif - Graphical Interchange Format File .jpg -
    [Show full text]
  • IDOL Keyview Viewing SDK 12.4 Programming Guide
    KeyView Software Version 12.4 Viewing SDK Programming Guide Document Release Date: October 2019 Software Release Date: October 2019 Viewing SDK Programming Guide Legal notices Copyright notice © Copyright 2016-2019 Micro Focus or one of its affiliates. The only warranties for products and services of Micro Focus and its affiliates and licensors (“Micro Focus”) are set forth in the express warranty statements accompanying such products and services. Nothing herein should be construed as constituting an additional warranty. Micro Focus shall not be liable for technical or editorial errors or omissions contained herein. The information contained herein is subject to change without notice. Documentation updates The title page of this document contains the following identifying information: l Software Version number, which indicates the software version. l Document Release Date, which changes each time the document is updated. l Software Release Date, which indicates the release date of this version of the software. To check for updated documentation, visit https://www.microfocus.com/support-and-services/documentation/. Support Visit the MySupport portal to access contact information and details about the products, services, and support that Micro Focus offers. This portal also provides customer self-solve capabilities. It gives you a fast and efficient way to access interactive technical support tools needed to manage your business. As a valued support customer, you can benefit by using the MySupport portal to: l Search for knowledge documents of interest l Access product documentation l View software vulnerability alerts l Enter into discussions with other software customers l Download software patches l Manage software licenses, downloads, and support contracts l Submit and track service requests l Contact customer support l View information about all services that Support offers Many areas of the portal require you to sign in.
    [Show full text]
  • Imageio Documentation Release 2.9.0
    imageio Documentation Release 2.9.0 imageio contributors Jul 06, 2021 Contents 1 Getting started 3 1.1 Installing imageio............................................3 1.2 Imageio usage examples.........................................3 1.3 Transitioning from Scipy’s imread....................................8 2 Reference 9 2.1 Imageio’s user API............................................9 2.2 Imageio formats............................................. 15 2.3 Imageio command line scripts...................................... 19 2.4 Imageio environment variables...................................... 20 2.5 Imageio standard images......................................... 20 3 Developer documentation 23 3.1 Imageio’s developer API......................................... 23 3.2 Creating imageio plugins......................................... 29 Python Module Index 33 Index 35 i ii imageio Documentation, Release 2.9.0 Imageio is a Python library that provides an easy interface to read and write a wide range of image data, including animated images, volumetric data, and scientific formats. It is cross-platform, runs on Python 3.5+, and is easy to install. Main website: https://imageio.github.io Contents: Contents 1 imageio Documentation, Release 2.9.0 2 Contents CHAPTER 1 Getting started 1.1 Installing imageio Imageio is written in pure Python, so installation is easy. Imageio works on Python 3.5+. It also works on Pypy. Im- ageio depends on Numpy and Pillow. For some formats, imageio needs additional libraries/executables (e.g. ffmpeg), which imageio helps you to download/install. To install imageio, use one of the following methods: • If you are in a conda env: conda install -c conda-forge imageio • If you have pip: pip install imageio • Good old python setup.py install After installation, checkout the examples and user api. Still running Python 2.7? Read here.
    [Show full text]
  • Imageio Documentation Release 2.9.0
    imageio Documentation Release 2.9.0 imageio contributors Sep 08, 2021 CONTENTS 1 Getting started 3 1.1 Installing imageio............................................3 1.2 Bird’s eye view on ImageIO.......................................3 1.3 Imageio Usage Examples........................................4 1.4 ImageResources............................................. 10 1.5 Imageio Standard Images........................................ 12 1.6 Imageio command line scripts...................................... 13 1.7 Imageio environment variables...................................... 13 1.8 Upgrading to ImageIO.......................................... 14 2 Supported Formats 15 2.1 Known Formats............................................. 15 2.2 Formats by Plugin............................................ 32 3 API Reference 35 3.1 Core API (Basic Usage)......................................... 35 3.2 Plugins & Backend Libraries (Advanced Usage)............................ 42 4 Developer documentation 59 4.1 Imageio’s developer API......................................... 59 4.2 Creating ImageIO Plugins........................................ 59 4.3 Developer Installation.......................................... 63 Python Module Index 65 Index 67 i ii imageio Documentation, Release 2.9.0 Imageio is a Python library that provides an easy interface to read and write a wide range of image data, including animated images, volumetric data, and scientific formats. It is cross-platform, runs on Python 3.5+, and iseasyto install. Main website:
    [Show full text]
  • High Dynamic Range Image Formats Bernhard Holzer Matr.Nr
    High Dynamic Range Image Formats Bernhard Holzer Matr.Nr. 0326825 Institute of Computer Graphics & Algorithms TU Vienna Abstract HDR-image formats are able to encode a much greater range of colors and light intensities than standard 24-bit formats do. The latter were designed to be conveniently displayed with 20 year old monitor technology, i.e. CRT monitors. Since high-fidelity digital imaging has become more and more important in the last years, so has the need for the use of HDRI-technology. This document gives an overview of available HDRI-formats, their history and applications. The most relevant formats are compared and their advantages, disadvantages, capabilities and features are discussed. 1. Introduction 1.1 Human perception Naturally, real-world scenes can include both very low and very The human visual system is capable of perceiving roughly 4 high light intensities at the same time. This difference between orders of magnitude of intensities at any one moment. It can the brightest and the darkest parts of an image is called contrast adjust another 6 orders up and down through a process called ratio or dynamic range. The perceived brightness of a scene is adaptation. This process does not work instantaneous and may take some minutes, for instance, in the case of entering a dark also referred as luminance, measured in candela per square environment [4]. meters [1]. The sun for example has a luminance level of a about 10 8 cd/m². An outside scene, only lit by starlight, has an intensity However, only covering that enormous range of intensities does of about 10 -3 cd/m² [2].
    [Show full text]
  • Directx 11 First 3D Objects Cartesian Coordinate in the Real World, Objects Exist in 3D Space
    DirectX 11 First 3D objects Cartesian coordinate In the real world, objects exist in 3D space. system This means that to place an object in a particular position in the world, we would need to use a coordinate system and define three coordinates that correspond to the position. In computer graphics, 3D spaces are most commonly in Cartesian coordinate system. In this coordinate system, three axes, X, Y, and Z, perpendicular to each other, dictate the coordinate that each point in the space has. Left & Right handed systems This coordinate system is further divided into left-handed and right-handed systems. In a left-handed system, when X axis points to the right and Y axis points to up, Z axis points forward. In a right-handed system, with the same X and Y axes, Z axis points backward. Left & Right handed systems 3D spaces In 3D, a space is typically defined by an origin and three unique axes from the origin: X, Y and Z. There are several spaces commonly used in computer graphics: ▹ Object space, ▹ World space, ▹ View space, ▹ Projection space, and ▹ Screen space. Object space Object space, also called model space, refers to the space used by artists when they create the 3D models. Usually, artists create models that are centered around the origin so that it is easier to perform transformations such as rotations to the models. That models are stored on disk are also in object space. Vertices in the vertex buffer will usually be in object space. This also means that the vertex shader receives input vertex data in object space.
    [Show full text]
  • Version 1 Last Updated 5/03/2018 Updated by Amanda Fairholme
    Version 1 Last Updated 5/03/2018 Updated By Amanda Fairholme Updated to match VE 9.0 Comments FP4 MP2 release Capabilities, Known restriction and comments by Processing Basic support by Product Workflow Category File Format Type Extension(s) VE Author 9.0 VE Author Version support Import Export Known restrictions and comments Primary CAD Design Web Format 3D/2D DWF 0.36 up to 7.7 Yes Yes No known limitations Formats (Autodesk) For import and export limitations, see the attached document: AutoCAD DWG Drawing Publishing Limitations_FP4.pdf. 1. Semantic PMI not supported - Text is imported as geometry AutoCAD Drawing R11/ R12 up to R27 2. Parametric object import is limited to the following types: circles, 3D /2D DXF Yes Yes Interchange (2014-2018 ) circular arcs, ellipses, elliptical arcs, text. 3. Per-face normals 4. Per-face transparency Note: This is also a 2D file format For import and export limitations, see the attached document: R11/ R12 up to R27 AutoCAD DWG Drawing Publishing Limitations_FP4.pdf AutoCAD Drawing Object 3D /2D DWG, DXF Yes Yes (2014-2018 ) Note: This is also a 2D file format For import and export limitations, see the attached document: AutoCAD DWG Drawing Publishing Limitations_FP4.pdf AutoCAD Sheet Set File 3D /2D DST Versions 7 and earlier Yes No Note: This is also a 2D file format 1. 2D vector data not supported ACIS Assembly and Part 3D SAT, SAB Versions 14 up to 21 Yes No 2. Animations not supported 3. Textures not supported 1. If a model is made up of surfaces, results sometimes have wrong DLV, normals, and holes in the joint of patches MODEL, 2.
    [Show full text]