• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.
Sign in to follow this  
Followers 0
EmptyVoid

Why do game companies use custom texture formats instead of the DDS format?

85 posts in this topic

Well I've been trying to export the texture data from max in to my models but I'm using maxscript and found out max does not have a way to export cube maps so I'm probably just going to use separate textures but I've been wondering why none of the games I have seen use the DDS format for textures?
0

Share this post


Link to post
Share on other sites
They probably want basic encryption to hide their textures from people or like Valve who have the vtm and vtf files they can then add custom meta/associated data with each texture file like bump amount or mip levels.
(Although the meta in this case is store in a separate file, so I guess they could indeed use plain ol' dds)
0

Share this post


Link to post
Share on other sites

companies use custom format because they write their own file loading modules that they use in their engines.

The real main reason is that they don't want the user's of the games to fiddle around with their data. They make custom format which their own engine can read only, not by something like photoshop & MSpaint. This way they make sure that their data is safe.

0

Share this post


Link to post
Share on other sites
The same question can be asked why people don't all use BMP's or TGA's for textures.

There are a variety of reasons. Often times there is the desire to package certain metadata with a textures, or package strange types of channels [such as embedding a bump map into a texture, instead of just straight ARGB], or perhaps they want special characteristics with respect to how textures are loaded such as usable partially-loaded textures for a game that features a lot of streaming.

Plenty of reasons.

*edit*

Oh, and data isn't safe, and game companies understand this. Simply compressing all the data in it's original form into a archive is typically the extent to which companies go to protect their assets, and even then it is largely for performance reasons. If data obfuscation was the goal, we would see a whole lot more games that encrypted the hell out of everything, which we just don't see. Even then it's just a matter of how much effort the attacker needs to put into getting to the material, since you can't use it encrypted. They just need to wait until the part of the program that puts things in a more simplistic form, and rip it then.
0

Share this post


Link to post
Share on other sites
A game I recently made used sounds from a royalty-free sound library, but the license also said that I had to stop others from just copying those sounds for themselves. Since I like to use .zip files for my pack files, the only solution is to fiddle with the file format itself. Apply to this to a large project with assets from many different places, and it makes sense to just protect all the files securely like this.
0

Share this post


Link to post
Share on other sites
I'll answer your question with another question: what the hell is DDS!?
(Yes, I can guess, but I really don't know what it is - besides being an image format, which is why I personally don't use it. I usually use PNG (if I need transparency) or whatever is convenient at the time. There are many formats to choose from, so I guess people choose one that suits their needs - or the create their own format which suits their needs).
0

Share this post


Link to post
Share on other sites
Quote:
Original post by issch
I'll answer your question with another question: what the hell is DDS!?
(Yes, I can guess, but I really don't know what it is - besides being an image format, which is why I personally don't use it. I usually use PNG (if I need transparency) or whatever is convenient at the time. There are many formats to choose from, so I guess people choose one that suits their needs - or the create their own format which suits their needs).


DDS format is a LOT better then PNG...
0

Share this post


Link to post
Share on other sites
Quote:
Original post by EmptyVoid
Quote:
Original post by issch
I'll answer your question with another question: what the hell is DDS!?
(Yes, I can guess, but I really don't know what it is - besides being an image format, which is why I personally don't use it. I usually use PNG (if I need transparency) or whatever is convenient at the time. There are many formats to choose from, so I guess people choose one that suits their needs - or the create their own format which suits their needs).


DDS format is a LOT better then PNG...


Usually, but not always. If you want a picture without lossing quality, then you cannot use DDS. But PNG is an option.

Quote:
EmptyVoid
Should I use my own format to protect my assets?


There are other options. For instance, store all your assets inside a ZIP file (something like quake/doom) and use a password (you have to decompress them on RAM, because if you do it on disc, somebody can take them). I remember library that do this, something like fszip, fliesystem zip or something like that.

Does anyone remember this library?
0

Share this post


Link to post
Share on other sites
Quote:
Original post by EmptyVoid
Should I use my own format to protect my assets?


No. Using your own format for any other reason is valid, but 'protecting your assets' isn't -- as has been mentioned, it will only deter the most superficial attempts to get at your data. People who actually want to mod your game (unlikely) or attempt to steal your assets (extremely unlikely) will still be 100% successful.
0

Share this post


Link to post
Share on other sites
What features does DDS support? Wikipedia doesn't really have much to say about it.

Does it support any kind of procedural storage, such as "layers" like most image editing software supports? If not, that would be why I wont use it.

As for why I don't use formats that do support some level of procedural content (SVG, for example) is that the primitives they provide are not the ones I need.
0

Share this post


Link to post
Share on other sites
Quote:
Original post by Extrarius
What features does DDS support? Wikipedia doesn't really have much to say about it. Does it support any kind of procedural storage, such as "layers" like most image editing software supports? If not, that would be why I wont use it.
DDS is a special purpose container for ST3C-compressed 1-4 channel images. The only reason to use ST3C (and by extension DDS) is that it is natively supported by a fair amount of consumer graphics hardware.

However, since most of the time you will need to support additional types of compression (RLE, JPEG, PVR, ...), additional layers (bump maps, specular maps, ...), and other metadata, it is typically easier to use a single custom container format.
0

Share this post


Link to post
Share on other sites
Quote:
Original post by swiftcoder
Quote:
Original post by Extrarius
What features does DDS support? Wikipedia doesn't really have much to say about it. Does it support any kind of procedural storage, such as "layers" like most image editing software supports? If not, that would be why I wont use it.
DDS is a special purpose container for ST3C-compressed 1-4 channel images. The only reason to use ST3C (and by extension DDS) is that it is natively supported by a fair amount of consumer graphics hardware.

DDS can contain more than just ST3C compressed data, uncompressed data is supported too. But then people tend to use tga or png instead if they want non-lossy compression.
0

Share this post


Link to post
Share on other sites
Quote:
DDS can contain more than just ST3C compressed data, uncompressed data is supported too. But then people tend to use tga or png instead if they want non-lossy compression.


DDS also supports mip-maps (stored in the file), cube-maps (with mip-maps), volume textures, floating point data (16 & 32 bit) and more. Something that traditional image formats doesn't natively support.

Creating a custom firmat with the same broad functionality is IMO a waste of time.
If you want some basic asset protection, use encryption, custom compression or custom pak files.

0

Share this post


Link to post
Share on other sites
Quote:
Original post by eq
Quote:
DDS can contain more than just ST3C compressed data, uncompressed data is supported too. But then people tend to use tga or png instead if they want non-lossy compression.

DDS also supports mip-maps (stored in the file), cube-maps (with mip-maps), volume textures, floating point data (16 & 32 bit) and more. Something that traditional image formats doesn't natively support.
On the other hand, the average user doesn't have either volume textures or HDR textures as assets, mipmaps stored in file are only worthwhile with very specific usage patterns, and cube maps can easily be stored in a 'vertical cross' (ala SOIL). If you do need all those features, you probably need a bunch of others to - PVRTC and JPEG compression in particular.

I am not saying that DDS doesn't have its uses, but for me at least, it really hits that uncomfortable spot between a specific and a general container.
0

Share this post


Link to post
Share on other sites
We use DDS at work. It's primarily useful if you're going to be storing your textures compressed in VRAM (yes, cards can do that), and want to see what sort of artifacts that compression is going to cause before you load it in to your game. Most of our textures are compressed. If lots were uncompressed, we'd probably store them as PNGs to get the lossless compression benefit to reduce our hard disk footprint.

Having worked with DDSs, I would strongly recommend them to anyone unfamiliar with them. You can reduce the memory footprint (in VRAM I mean) by 4 to 8 times (depending on which DXT format you're using). Which means you can cram more or larger textures into the card, and get better quality results. There might also be a performance benefit if some textures are being stored in AGP memory, since the bandwidth required is reduced. You can get free plugins from NVidia to let you export DDS from photoshop, and there are utilities from Microsoft in the DX SDK to let you open and inspect DDSs (different mip map levels, etc.).

On topic, the only reason a game company would build their own file format would be so they can add extra features to it specific to their game, even up to the 11th hour when things are due. It's more common with 3D models than 2D textures usually, since PNG, TGA, JPG, and DDS really cover most of the bases for what you want from a texture.
0

Share this post


Link to post
Share on other sites
Game companies may use custom format with a ton of meta-data and whatnot to be used in their tool chain but in the end, companies don't have any choice but using the texture formats that the hardware supports, which usually boils down to DXTn, rgb(a) 32 bits, and rgb(a) 16 bits (444 or 565...), with or without swizzling. (Edit: and a bunch of floating point textures)

There is no such a thing as a "custom format that only some engine supports", everything gets processed to the same format at some point. (Unless they are writing a software renderer...;))
0

Share this post


Link to post
Share on other sites
You're being a bit misleading there: of course, the hardware only takes certain pixel formats, but those pixel formats can come originally from a multitude of file formats.
0

Share this post


Link to post
Share on other sites
Quote:
Original post by hh10k
A game I recently made used sounds from a royalty-free sound library, but the license also said that I had to stop others from just copying those sounds for themselves. Since I like to use .zip files for my pack files, the only solution is to fiddle with the file format itself. Apply to this to a large project with assets from many different places, and it makes sense to just protect all the files securely like this.


Doesnt that mean that you just have to state that the resources are not to be copied, are in violation of a ULA for example, with your game. I mean, technically it is physically impossible to actually "stop" them from aquiring information you are communicating with them, its a fundamental requirement of communication lol.

Im sure any court would see that a lincense statement and ULA would be enough of an attempt to stop copying as would be acceptable to satisfy the royaly-free license anti-copying request. Unless its a non-distribution license, in which case, you can change and encrypt it all you want, its still a violation :P
0

Share this post


Link to post
Share on other sites
Quote:
Original post by Numsgil
Having worked with DDSs, I would strongly recommend them to anyone unfamiliar with them. You can reduce the memory footprint (in VRAM I mean) by 4 to 8 times (depending on which DXT format you're using). Which means you can cram more or larger textures into the card, and get better quality results.

While this is true, it has nothing to do with the DDS format. You can obviously also load uncompressed data from a PNG, or some other custom format, and compress it on the fly. That's what we do. It has the advantage that compression can be turned on and off by a user quality preference setting, and that it seamlessly supports other forms of existing or upcoming compression without rebuilding all the assets.

And of course, if we talk about lossless compression, PNG is lightyears ahead of DDS.
0

Share this post


Link to post
Share on other sites
The points to using DDS...

  • Pre-compression: compress your textures at production time, so you can see exactly what compression artifacts will result. Pick the compression algorithm at production time to get better results, for your own definition of "better".
  • Mipmap pre-generation: if you don't like how a given mipmap level looks, replace it with a tweaked version to make it sharper, or fuzzier, or what have you. You can also regenerate the higher mipmapping levels from the newly inserted mipmap, instead of from the base level.
  • Direct DX#Surface support: generate cubemaps, 3D textures, all kinds of specialized surfaces, all from the texture resources in the DDS file, with a single call. Why re-invent the wheel?


You can still use your own archive format, as the loader still supports being given a block of memory and reading it as though it were a DDS file.
0

Share this post


Link to post
Share on other sites
The thing is I already have a format that supports all my needs and it's just a matter of copying and pasting the code. I'm just wondering if there is any reason not to use it?
0

Share this post


Link to post
Share on other sites
Don't waste too much time second guessing such options.

If you've got something that meets all your needs then you may as well be using it rather than looking for problems.

If you've done your research well and it really does meet all your needs then you'll be fine. If not, then you'll quickly learn to do better initial research (not to mention properly figuring out your needs) in future.

As long as you're sure your needs are met don't worry about the reasoning for why other people (or companies) use or do not use a particular technology. A lot of the requirements and restrictions of professional development do not neccesarily apply to hobbyist work, and even when they do, the decisions made by professionals are not always the best ones.
0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0