PlaneShift

Development => Development Deliberation => Topic started by: Yaskina on May 09, 2006, 02:30:32 am

Title: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Yaskina on May 09, 2006, 02:30:32 am
hello all im just trying to get my mac up and running the latest version of this game and it appears there is problems so im trying to run a secound download to solve the problem? long story if you dont use a mac. that aside i was sniffing though the files in the .14 build and see that most files are PNG. I have some 3d art and game dev Exp and i am wondering if all the files driving the color are PNG? ;D
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Karyuu on May 09, 2006, 04:05:10 am
Not all, but I'd say that a good majority of textures that wrap around character models especially are and will be in .PNG format. Not too sure of the specific reasons, but it sure beats .JPGs when it comes to quality :}
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Yaskina on May 09, 2006, 02:04:19 pm
Karyuu i was thinking i would like to batch convert all the graphic/textures in the game to see if i could get a stable frame rate. You see PNG files are much larger than gifs,jpg. I ran some tests on some of the unzipped and i was able to drop the file size as much as 10% of the PNG size without very much loss of image. Im sure if all are PNG and I/We could convert to a smaller footprint format that works with the engine we could remove alot of system bus traffic and RAM/VRAM req and in affect make it a lighter wieght job for the vid card to render. I might have some time to write a 3D App to check for proof of concept, but im thinking that the test would not put the vid card under the same stress as the main world does in the game.

If i could get the information needed to unlock one of the zip files for the main world i could maybe run some tests. I think the quickest test for me would be to batch convert all the textures for the main town by discarding all of the colour information in the PNG. This should drop the files by 40% or more! which should be enough to see if i get a little higher min frame rate.

Anyways if you think you can help out or have done tests or any other information regarding this idea let me know.

thanks all
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Wired_Crawler on May 09, 2006, 04:13:00 pm
Yaskina, images are not uploaded to memory of graphics card in original format (as png or jpg or tga or whatever). They are decompressed to bitmap (well, maybe not exactly bitmap but I hope you know what I mean) and stored in card's memory in quite different format. Changing PNGs to JPGs will not affect framerate. And why do you want to discard all color information ?  ???

Quote
...10% of the PNG size without very much loss of image

That can't be true. PS uses relatively small textures, and EVERY pixel is important. Using compression which throws out part of information would mean loosing many small details. Maybe You would not notice this when looking at buildings from a distance, but closer examination would show difference.

The format, which holds data in similar way to that used by hardware is DDS (maybe there are others, but I haven't heard about them).

BTW: formats like PNG and TGA can carry transparency information, JPG can not.
BTW2: converting all textures to other format would require also making changes to maps (textures definitions).
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: reisio on May 09, 2006, 07:17:42 pm
PNG almost always compresses lower than GIF or high quality JPEG.  Either you've been misinformed, or you're basing your claim solely on PlaneShift PNGs which haven't been compressed, or both.
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Yaskina on May 12, 2006, 09:55:56 am
Well what i am getting at is that i was suspect that alot of the files are larger than they need be. And yes i am correct in that. And i am not missinformed at all as i have worked with graphics for the past 20 years on computers. While at this point i have looked into some of the zip packages and have found jpg tga and png and the later animated version of PNG i forget the suffix atm.

But i have also found that most of these files render perfect in 256 colour with zero loss in image appearance. And in allot of cases i found images that were in tga or png sitting in the zips over 1 meg in file size and they could be saved in a gif or png with 16 colour at maybe 50k with no noticeable loss in image quality that anyone would see rendered in the game. This i m almost 100% sure off. That said!!!! Im sure that if theres no problem using optimized files with the engine, the distro could end up almost a 100 megs smaller with no noticeable loss in quality for the most part. Do the math on download savings/time saved etc. Then after you think about that for awhile and get the real numbers down add loading times and memory req as in most game engine that i have used these files sit unpacked in before it is passed off to the vid card via system bus, oh and not to mention that the file is converted for use by enige. I dont know about you but if i was a computer i would rather deal with a 50k file then a 1 meg file.

While anyways please think about that. I d like to talk about other things i found and some other ideas but im sure you would just try to shoot it down. Oh ya do me a favour what ever your name is dont reply just cause you have a keyboard your reply proves that you have no idea what your talking about. My numbers are rough and done in my head but i can prove what i say, and i was only trying to help. :thumbdown:

thanks and have a greatday, anyone that might want to talk about this idea and is not going to try to flame me for trying to help is more than welcome to contact me as i would be glad to help out if i can. :thumbup:
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Xordan on May 12, 2006, 10:02:24 am
We're looking at a different format to store our textures in. dds seems the most promising so far.
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Yaskina on May 12, 2006, 11:16:48 am
Xordan i think the best way to approach this is to just dev a texture standard with the idea that its going to be used in a game. I think alot of these textures started as a 256k color file then were upconverted. I know most games 3d use 256k colour or less when ever they can. I have also done some life/photo like 3D renders that use 256k color and less in the textues and you would not even know that it was not photo. Anyways its all about optimization when it comes to games.

Maybe some how i could upload one of my optimized zips to a moderator that plays to try and see what they think. To check loading speed, frame rate, zone image quality etc. It would be as easy as renaming the org file for exp deathrealm.zip to something like org_deathrealm.zip then adding the newer zip in the same folder.

While anyways i was thinking on trying to turn the water in the sewer into an animated gif to see if it will animate with out having placed it as an animated at time of model creation. Who knows maybe ill get lucky and the engine well know what to do with it without being told.

thanks for the info, maybe ill get around to looking at this DDS also tomorrow and let you know what i think
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Xordan on May 12, 2006, 11:25:34 am
We know that DDS is the best already. A lot of commercial games use DDS textures, because they're the same format as is what goes into the Vram, so they need no compression/decompression along with mipmap creation(pre created). It's just getting everything to convert correct, work, and look right.
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Wired_Crawler on May 12, 2006, 01:36:21 pm
(I started writing this before last 2 posts)

@Yaskina

    Hey, I think You misuderstood (not everybody here can clearly express his thoughts in english) and You are overreacting a bit. For example - it wasn't so obvious for me, that You had in mind only reducing number of colours (quote: "...by discarding all of the colour information in the PNG"). And where are the flames in above posts ?
   I too sometimes don't understand, why people waste so many resources (memory, disk space, cpu power) and why don't they optimize things; and sometimes that thoughts are reasonable. But it is simply hard to belive in Your statements, because most beatiful, recent 3d games occupy gigabytes of disk space and they use high resolution graphics with 32-bit colour, (plus normal maps, specular maps etc...) Using 16-colour textures in modern game sounds... ridiculous (no offense, and I do not deny the possibility, that in this particular case You are right, but I would need a proof).  You write later about 256k colors, which sounds much more reasonable.

So I ask for concrete example, maybe a screenshots from PS showing no difference in appearance between original and converted graphics? If You don't know how to modify map, or You have no time for this, just tell, which textures to convert and to what format, and I (or somebody else) can make a comparision. I don't want to experiment with all of textures, so Your experience and intuition is welcome here :). I really would like to try it :).

I think You can use any free, public "virtual disk" to share Your files.

Regards

P.S. Please, please, try not to use agument "I was doing this for xx years, so yes, I am right!". These kinds of statements often meet opposition (conscious or subconscious) and... sometimes are untrue. A bit of diplomacy is always good. "I keep track of trends in computer graphics for xx years, so I am convinced I am right" sounds better :)
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Yaskina on May 14, 2006, 05:34:24 am
Wired how do you like your humble pie? I optimized the default gui and its not too shabby seeing how it knocks off over 15 megs from system memory ( and thats a safe low guess ).

 Im almost certain that engine on my system is not upconverting them to 32bit ( which would not ruduce system memory if this is happening ). You see i dont know down to the last nut and bolt how CS handles everything.

But one thing is for sure the zip pack went from about 9.5 megs to 1.4 megs!!!! alought the quality drops a tiny bit it, but it looks tip top for sure. Only thing i see that i might want to do is work on my custom colour pallet a little more which would create nicer down converts.

BTW can you do me a favour and tell my of a game that is using 100% 32 textures, you see im certain allmost 99% use 8bit and things like colour ramping, bumpmaping, vert painting, etc etc are rendered at 32bit using 8bit textures. Yes most games in the last few years include 32b textures but not 100% of there files are, you see it gobbles up ram like mad if you do....... and just maybe the 32bit files in this game ( most of them are really 8 bit files saved as 32bit ) cause the ram and unstable frame rates problems. I could explain how things work in computers core when moving files around but im not an expert so i wont bother beside i hate typing. Bah i hate words period i like pictures!!! lol

Im going to invite a GM in PM to see if they would like to try it out. If they say it ok for me to send to you PM me and i can send via email or via Yahoo msg system. its only one file at 1.4 meg.
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Karyuu on May 14, 2006, 05:38:00 am
Yaskina, we're currently going to try out the DDS format :} Both the sizes of files and loading times have decreased significantly, so we're on the right track for now, with no loss of quality at all.
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Yaskina on May 14, 2006, 05:47:03 am
Yes i tried out the DSS format. Still having problems with this format not to much info regarding macs and the use of these. I know in the past is was mirco only but i almost sure that has changed. It would be a nice format to use if there was more support across systems. maybe in the future, although i might have made an error or had wrong format from the 5 or i need to upgrade to 10.4
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Xordan on May 14, 2006, 01:29:09 pm
Texure formats depend on the graphics card and the drivers. It has nothing to do with the OS. Any card that would support DX7 can use them. Also, we're more concerned about speed rather than size. DDS is the fastest to load, no question about that, as well as being much smaller and with no loss in quality (which is very important). They actually load faster on linux than on windows as well :)
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Yaskina on May 14, 2006, 06:21:15 pm
Xordan they will load faster on hands down on linux or mac because windows is bloat ware. Linux and Mac are much more optimized at a lower level ( mac also being from hardware up ). Its great your looking into DDS and i think this could be a solution, but  i didn't want to say it before but thats not going to solve any gameplay  or any memory issues. Unless the devs make some of these bit 8bit that should be 8 bit. Yes in some cases you may have to remap but why not.

Where you lose quality in Textures by using 256 color textures is by the amount you scale it when setting the mapping on the mesh. From my Exp your better off to use larger Textures at 8 bit when your scaling the texture to much. This will give you a sweet result and you do not have to worry about taking up to much more memory. i have noticed where texture mapping scaling is an issue in PS.

this is below is sorta what im talking about.

Expample: you could have 1 1024x1024 8bit textures for the cost of 1 32 bit 512x512

Which has more pixels? Which file could hold more detail?
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Xordan on May 14, 2006, 09:10:10 pm
Well feel free to convert the maps/models/objects/gui how you think and upload them somewhere, and I'll try them out.
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Wired_Crawler on May 14, 2006, 11:31:57 pm
Wired how do you like your humble pie?

Err... Do You mean -> this humble pie (http://en.wikipedia.org/wiki/Humble_pie) or -> that Humble Pie (http://en.wikipedia.org/wiki/Humble_Pie) ? In either case I don't know, what You are talking about... :P
Never mind.

BTW can you do me a favour and tell my of a game that is using 100% 32 textures, you see im certain allmost 99% use 8bit and things like colour ramping, bumpmaping, vert painting, etc etc are rendered at 32bit using 8bit textures.

You are right. Not 100% are 32bit textures (and I never used "100%" in my replies). Example? I would like to check textures of "Myst V", which is closer to that what I consider as "beautiful recentd 3d games", but they are not so easy to extract and I'm not sure if I have enough free space on disk. Let's try something easier: Doom 3 (which is not a newest game). All textures which are not in DDS format, are stored in TGA files using greyscale, 24- or 32-bit color. Around 30% of those TGAs have less than 256 colors in use, so 70% of images need more than 8-bit for color information. Do You think that creators of Doom 3 made a mistake and they should reduce number of colors in more textures (~40 % use 1k-10k different colors) ?
Unfortunately, I can't check all recent 3d games, I have no money for them. :P

BTW: It looks like Doom 3 has DDS and TGA versions of the same textures, DDS version occupy around 4x less space on disk, so it is good solution for sure.
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: jorrit on May 15, 2006, 12:58:34 pm
Xordan they will load faster on hands down on linux or mac because windows is bloat ware. Linux and Mac are much more optimized at a lower level ( mac also being from hardware up ). Its great your looking into DDS and i think this could be a solution, but  i didn't want to say it before but thats not going to solve any gameplay  or any memory issues. Unless the devs make some of these bit 8bit that should be 8 bit. Yes in some cases you may have to remap but why not.

Where you lose quality in Textures by using 256 color textures is by the amount you scale it when setting the mapping on the mesh. From my Exp your better off to use larger Textures at 8 bit when your scaling the texture to much. This will give you a sweet result and you do not have to worry about taking up to much more memory. i have noticed where texture mapping scaling is an issue in PS.

this is below is sorta what im talking about.

Expample: you could have 1 1024x1024 8bit textures for the cost of 1 32 bit 512x512

Which has more pixels? Which file could hold more detail?

Internally in Crystal Space and on the card textures are ALWAYS stored as 32-bit. So it doesn't help to convert them to 8-bit. You will not gain any memory by doing that.

Greetings,
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: res on May 15, 2006, 04:09:49 pm
Internally in Crystal Space and on the card textures are ALWAYS stored as 32-bit. So it doesn't help to convert them to 8-bit. You will not gain any memory by doing that.

That's not technically 100% correct either. The textures might get stored on the card compressed (ie DXT), which amounts to 4bpp to 8bpp per pixel - however this is not a *paletted* image. The quality is somewhat worse than a full 32bit image, but with a typical game texture the difference is hard to see, and it beats paletted images.

DDS images can store textures in a number of formats, but notably they support the abovementioned DXT. Together with the support for storing mipmaps in DDSes, this removes the need to do any processing of the image after loading; hence the significant speed boost.
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Yaskina on May 15, 2006, 11:11:46 pm
Interesting last 2 posts :detective: Well i have converted quite a few to 8 bit png and im really getting mixed results. Part of my problem is where i load into the game as the game uses many textures over and over on the different zones ( which is great), but not having converted the entire game its causing naming issues etc.

But yes it seems every single file in the game is 32-bit except for a small few that i found as gif maybe 10 so far.

 I have  tried animated gif and it did not work (stayed on first frame), however i am thinking it might be possible if i add a few lines of code to the cal3d file. If anyone has a cal3d file that uses a animated gif please post a snippet of the code text. The animated gif i made was just of the rat blinking his eye 4 frames 10 sec delay on open.

Im now going to run some probes to check memory and vram. I wana see what or what not is being dumped.

The other thing im wondering if the zip packs where 2/3 smaller cause they had optimized files in them. Why not change the zip format from Deflate (high compress) to store ( no compress ). This should speed up loading of the files if they are not packed all up. ( go ahead tell me im wrong LOL ). If anyone knows of a batch converter for mac that can do this please let me know. I would want to do every single zip pack in the ps folder in one pass and in place no mucking around.

I have also been messing around with the particle emitters. I changed the particles from 50 to 10 and size from .025 or .25 (not-sure) to .075 Seems to look almost as good as 50. In fact you probably would not even notice the difference other than it fills out a little more on the torch in the sewers. 50 increased in size a smaller amount than i did would probably look best, but why emit 50 when you can do it in 10. Now i have to get after the smoke stacks and the other fire pits. Only things is i just really really wanna so bad wana hit the delete on all them tiny little steps adding hundreds and hundreds of verts where there should be a 4 vert plane ramp! In fact my guess is there is more power being used to render stairs and steps then anything. Again go ahead and tell me im wrong ! Why make like 40 odd tiny tiny steps when a nicely textured ramp would do. And to boot there is like 7 of these in the court Thats a hell of alot of verts for little or no gain in beauty. Heck why not add on sub surf procedure lol sorry im ranting now. Time to go
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Karyuu on May 15, 2006, 11:16:24 pm
Er... is it even possible to use animated .gifs? We certainly don't use any right now, so you won't find any such code from the PS project.

What other games use animated .gifs?
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Yaskina on May 15, 2006, 11:50:14 pm
I do not know of any off hand that are new that use animated gif per say, but I'm positive that there is a way to perhaps swap numbered textures or possibly even use animated gifs. This may or may not be possible with this engine I don't know a single thing about it, other than what i have learned from reading the world and cal files. I should say i do understand programming some what as i have used real basic, visual basic and done some html and java. Having done some work with 3D going all the way back to the first gens i am able to read threw most of these files and make some understanding of what is what. My guess is a few lines of code in that cal3d file will allow it to appear animated, which could be really sweet if npc's and pc's eyes blinked. But I'm only guessing!!

*edit*

Well i ran some 8 bit vs 32bit too see what was happening with the ram. I ran some controlled tests with a probe running. I ran this test a few times to insure that nothing elese was affecting it, and i will run it a few more to insure results. I stood in same place with out moving just loaded into world ( sewer ) and no npc or pc s were visable ( LOS anyways ) with 8 bit textures in the sewers it was about 1.5 megs less in system memory. Which is about what i expected from one single point of view.

 As i run around the map it appears to collect what it needs and add to memory, as every time there is a hickup in framerate my memory usage for the psclient JUMPS a few meg.

Jorrit i know it says your a developer and all but i think you might wana double check on that 8 bit uped to 32bit store reply because i just ran some more tests up against a fresh install and my optimized copy of ps and it is using 22 megs less than the Orginal copy. And thats only scratching the surface, as i have only touched 6 of the zips there is 48 in my build. Maybe it cause im on a mac! but i doubt it very much

On my mac i hit low 300 Plus usage in ram at times


Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Wired_Crawler on May 16, 2006, 10:21:35 am
Er... is it even possible to use animated .gifs? We certainly don't use any right now, so you won't find any such code from the PS project.

You can't use animated GIFs in CS. -> About animated images in CS (http://community.crystalspace3d.org/tiki-view_faq.php?faqId=5#q11)

What other games use animated .gifs?

I'm not sure if they were animated GIFs, but games like Doom, Doom 2, Heretic, Hexen and other 10-15 years old 3d games were using similar techniques. It was at times, when computers had 2-4 MB of RAM and ~200MB hard disks, so 16 color images were commonly used.

Jorrit i know it says your a developer and all but i think you might wana double check on that 8 bit uped to 32bit store reply because...

Jorrit is creator and leading programmer of Crystal Space. Why are You questioning his competences, and at the same time You are getting mad, when someone is questioning Yours ?
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: jorrit on May 16, 2006, 02:36:46 pm
Er... is it even possible to use animated .gifs? We certainly don't use any right now, so you won't find any such code from the PS project.

What other games use animated .gifs?

Animated gifs are not supported by CS but CS does support animated images in MNG format. I even believe PS uses a few of those in the death realm.

Greetings,
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: jorrit on May 16, 2006, 02:39:55 pm

Jorrit i know it says your a developer and all but i think you might wana double check on that 8 bit uped to 32bit store reply because i just ran some more tests up against a fresh install and my optimized copy of ps and it is using 22 megs less than the Orginal copy. And thats only scratching the surface, as i have only touched 6 of the zips there is 48 in my build. Maybe it cause im on a mac! but i doubt it very much

How do you measure how much ram is being used on the VIDEO card? You were probably measuring RAM on the computer and that is not relevant in this discussion. As to it needing less memory it is very hard to measure memory usage effectively. You could be right that loading an 8-bit image makes PS use less memory during load time but at runtime it will be the same.

Greetings,
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: jorrit on May 16, 2006, 02:41:25 pm
Er... is it even possible to use animated .gifs? We certainly don't use any right now, so you won't find any such code from the PS project.

You can't use animated GIFs in CS. -> About animated images in CS (http://community.crystalspace3d.org/tiki-view_faq.php?faqId=5#q11)

But you can use animated MNG's in CS.

Quote
Jorrit is creator and leading programmer of Crystal Space. Why are You questioning his competences, and at the same time You are getting mad, when someone is questioning Yours ?

Well I *do* make mistakes too :-)

Greetings,
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Yaskina on May 16, 2006, 07:23:23 pm
Wired i can assure you of one thing almost all 3D games, apps, movies etc old and brand new have used animated textures of some sort format does not really matter here. Wired it is very clear to me that your just typing words for the hell of it, My posts are based and research, years of experience and nuts and bolts hands on testing. What are you going to attack next my spelling and grammar. If you don't have anything positive to add like.. here try this..... or i tried that and it did not work.... put the keyboard down!!

This clearly is a development board. You have typed nothing to aid what so ever or add any correct information that could be used to improve the game or my ventures to help. nuff said

Jorrit thanks for the reply kinda stuff I m looking for. Which reminds me i did see 1 mng file in one of the zips. So i will now have some more testing to do thanks a lot!!! lol just joking. I was watching ram, cpu, and system in real time well playing in window mode. Jorrit I am currently under the understanding that textures are loading into ram in the format that they will be transfered to the video card. That said i can tell you that copy of PS that has optimized files used less ram while playing the game, and looked just as good and with a few things cause of my tweaking the image ( via contrast saturation ) even better. I would be more than willing to send you some of the files for the sewer and gui. Send my a pm with your email and i shall email them to you so you can see first hand. I can also send some to Xordan aslo same way :sorcerer: \\o// \\o// \\o// \\o//
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Karyuu on May 16, 2006, 07:26:06 pm
Yaskina, can you please post some screenshots here?
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Xordan on May 17, 2006, 12:25:39 am
Ok, did some testing! Everything is the same in each file except for the textures. (Got Yakinas' zips forwarded to me):

As we have now:

Screenshot + memory usage:
http://curry.cirtexhosting.com/~thekcab/normal.JPG

Load times and zip size:
sewers: 3794ms, 8982kb
hysewers: 142ms, 3362kb

Yaskinas':
Screenshot + memory usage:
http://curry.cirtexhosting.com/~thekcab/yask.JPG

Load times and zip size:
sewers: 3837ms, 3963kb
hysewers: 123ms, 1523kb

DDS:
Screenshot + memory usage:
http://curry.cirtexhosting.com/~thekcab/dds.JPG

Load times and zip size:
sewers: 2427ms, 3756kb
hysewers: 120ms, 1363kb
Title: Re: Is PNG files used for all graphics/uvmapping?
Post by: Yaskina on May 17, 2006, 02:40:31 am
Looks good. So are the DDS files 8bit or 32bit
Could you send me a copy of the DDS files for the sewer. I have been trying to get them to work with no luck, but only have one app which has limited support for them. feel free to email me them Id really like to check them out for sure. And its possible i dont have something just right.

I m also wondering if you have the setting load all maps on. Reason i ask is when i load into the sewer my mem sits at 108 8bit and 134 32 bit. i guess im just checking i assume thats they your ram was at almost 350
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Xordan on May 17, 2006, 07:32:42 pm
Urr, it's not a question of '8bit' or '32bit'...

It works somethinge like this....
32bit textures were converted to DDS with DXT5 compression.
24bit textures were converted to DDS with DXT1c coompression.
Anything other than those two were converted to DDS with DXT3 compression (default), although we can specify for those as well, probably DXT1c is best. There's lots of things we can specify and we're probably not using the best settings right now, but we can improve on that fairly fast.

This is a four-bit compressed color format that allows for opaque, and one-bit alpha textures; that is, textures with no transparency at all, and textures with a single transparent color (masking). The most compression will be put on textures.
DXT1c is colour only (no alpha),
DXT1a has that 1bit alpha.
DXT3 adds support for a four-bit explicit alpha channel, on top of DXT1's color compression. Four-bit explicit alpha allows for sixteen distinct alpha values, making it good for textures with sharply contrasting translucent/opaque areas.
DXT5 ssupports a four-bit interpolated alpha channel. Three bits are used to determine explicit alpha values, and two eight-bit values are used to interpolate gradually between them. This makes the format especially suited for soft gradients and other textures where the alpha areas vary less wildly. The least compressed option.

And no, I didn't have load all maps on. 350mb is normal for loading one map on windows. If I put on load all maps, the ram usage would be closer to 600mb.
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Yaskina on May 17, 2006, 09:33:40 pm
Well it does have everthing to do with 8 bit or 32 bit thats the reason why i started this thread. This game is using 99% percent 32bit files, even on files that should be 2bit black and white. And thats why people are having problems with the game ITS A PIG on memory. Whats the point in making a game for people to enjoy if the only people that are going to be able to play it have 2 gis of ram and 256 meg plus vid card. That in essense was the entire reason that i started to try to help. If we got like a few people and did a mass conversion of the game we would have it done in like 3 days and a working update that would use probally about 100 megs less in ram and cut bus traffic by a third.

1-Are you going to post the sewer zip files with DDS or not?

2-Whats a resonable expected time frame for you to have the entire game converted to .DDS. Im now about 40% complete but im batch converting

3-And is there a loader for these files on mac in the game. Mac uses opengl and from my understanding opengl does not support the DDs format out of the box. But i could be wrong.



Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Xordan on May 17, 2006, 10:38:51 pm
Quote
This game is using 99% percent 32bit files, even on files that should be 2bit black and white. And thats why people are having problems with the game ITS A PIG on memory.

Try reading my last post.

Quote
This is a four-bit compressed color format

beats 8bit, if you use the same logic, ignoring what Jorrit and res (both crystalspace devs) said earlier. My results proved that dds is better than png for memory anyway. dds files are stored pretty much how they are in ram and vram, and used as such.  And yes, this means they undergo no conversion and mipmap generation, which means less bus traffic if you want to compare that as well.

Quote
play it have 2 gis of ram and 256 meg plus vid card.

That's crap. It doesn't need that and it won't.

Quote
1-Are you going to post the sewer zip files with DDS or not?

Once I have time to upload yes. I'm short on time atm because I have a life, and this isn't my top priority.

Quote
2-Whats a resonable expected time frame for you to have the entire game converted to .DDS. Im now about 40% complete but im batch converting

Two days ago.

Quote
3-And is there a loader for these files on mac in the game. Mac uses opengl and from my understanding opengl does not support the DDs format out of the box. But i could be wrong.

You understand wrong. They work fine on mac. If you'd done your research then you'd know that the whole of PS uses opengl, so that isn't an issue, if it works on one platform it'll work on others. (Also note that games like NWN which was released a few years back for windows/linux/mac with opengl uses entirly dds textures afaik.) What matters is that the engine and the graphics card have support for the texture. The first is a yes, and the second is most likely a yes unless you're using quite old hardware (not new enough to run modern games).
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Yaskina on May 18, 2006, 05:51:55 am
so your saying your 32 bit tga's are now in a 4 bit c colour format. If so my software kinda sucks bad or must be broken. Cause when i convert a a 32 bit tga into a DTX with consideration for alpha or not the file still uses exaclty the same amount of memory for a  512 x 512 only thing that changes is File length. i end up with a 32 bit colour channel and a 8 bit alpha channel.

Please just use the service www.yousendit.com and let me try your files send the same 2 you got from me only in your sweet DDS version hysewers.zip and sewers.zip and let me try it out

Also a very close friend of mine works at ATI and i asked him the other day regarding dxt on my card he said its no problem provided the software supports it and is able to load it in. Just thought i would mention this, i live just 5 mins from the main world wide head office. gota love it!

Also i think there is a problem with the arena zips on the mac anyways. not sure which one but i think its an image file thats creating the prob. reason i say this is there is dup images in these zones and the engine/openGL reuses ones already opened in another zone.

When i load into DR and get to hyldaa  then run to arena im ok ( no crash) if i go any other way i get a crash at the arena.
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Xordan on May 18, 2006, 06:09:52 pm
Firstly, most of the textures in the sewers are 24bit (according to windows anyway) with some 8bit and 32-bit textures as well. I checked a few other zips and they show the same thing. What software are you using to check the bit depth? It tells me that in your zips, most (the ones I checked) are 8bit, which is correct I assume.

Secondly, I've sent the maps.

And lastly; I'll see if dfryer will take a look at the arena to see if there's a problem there on mac.

PS: I'm a bit of a nvidia fanboy :P ATI  :thumbdown:
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Yaskina on May 18, 2006, 06:49:50 pm
Where did you send the maps? I checked my mail, pm box and i dont see any link. Please post/mail me a link for the 2 sewer files in dds so i may try them. I am interested in trying them files. I was suspect that you would not post the goods, prove me wrong 5 min job tops.

I have not been through every single file but hundreds and i have not seen one 24 bit file as of yet. i have seen a few 8 bit not many though. Im using software thats been around along time, it gives me a very highly detailed window regarding the file, even better than photoshop. I will open up a few zip packs and open all files and click close check.
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Karyuu on May 18, 2006, 07:30:48 pm
Yaskina... It's rather rude to be so demanding. As Xordan said, he has things he needs to take care of elsewhere in life, and replying here isn't his top priority at the moment. (Studying for finals is more like it.) So why don't you relax a little and stop poking him with a "Gimmegimme!" when he already said he'll give you the files.

Second, he asked you what software you are using, not how old the software is nor what it can do or what it's better than.
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Yaskina on May 18, 2006, 07:51:23 pm
Well it would only take 5 mins to send zips he already has made.

I just checked these zips

hysewers.zip 5 8 bit files and rest are 32 bit - no 24 bit

sewers.zip 3 8 bit and rest are 32 bit - no 24 bit

Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Karyuu on May 18, 2006, 07:55:10 pm
Now I'm also curious as to what software you are using, which you haven't answered yet.
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Xordan on May 18, 2006, 07:58:56 pm
I typed your email (the one that in your forum profile) into the yousendit thing....

Here are the links anyway:
http://www.yousendit.com/transfer.php?action=download&ufid=211FEE5050845072
http://www.yousendit.com/transfer.php?action=download&ufid=CF2B4F7537F1A8B0

And this is what windows tells me....

http://img184.imageshack.us/img184/5526/bitdepth5ow.jpg

And if you're going to be so pushy I can just ignore you and we'll go our own way regardless of what you think.
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Yaskina on May 18, 2006, 09:54:52 pm
We must have different original files.  I noticed you image screen shot shows them at 96 they all report 72 on mine. maybe there are different zip packs being used on mac and pc. oh well its not that great of concern 8 bit still the way to go. Im really glad you sent them files cause im proud to say that they worked. Well i will have to try to figure out why the converts to DDS that i make wont. There is not a whole lot of options for DDS on the mac. I do have windows and linux installed on my mac and can run them at the same time so i should try other os software to try to handle them. my app reports that the dds are all 32 bit colour and 8 bit alpha where alpha applies. When i checked the files for memory usage png 8 bit used  5 megs less ram for these 2 files vs DDS. DDS did seem to load about 2 seconds faster thou.

So if we could go 8 bit colour and 8 or 4  bit alpha DDS files we would be doing really sweet.

And just to say i don't mean to rush you or try to make you use gifs or png 8 bit i don t care what format is used and if i have any point that i am pushing is to use 8bit what ever and use alpha channel only when its a 100% must. Alot of the alpha channel files in the game can be done with trans, i just have to spend a little extra time to not get the halo its a colour pallet thing.
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Xordan on May 18, 2006, 10:14:30 pm
You still haven't said what software you're using. ^^ I've run a few programs which outputs info about the images (png in this case) and they all report the same thing:

http://rafb.net/paste/results/Sd4LJD91.html

And I redownloaded the map from the updater (every platform has exactly the same art), and it reports that.... so I wonder if your app is reporting the correct info. To make sure; can you post what bit depth your app reports the fynnwn chain or leather armour to be?

Edit: hmm, I tried to find out the bit depth of the dds files and different apps are giving me different answers. One says that they're all 32bit, another says they're all 24bit. Will try and find a reliable app which supports them to check with. If, however, it turns out that all the dds are of the same bit size (dxt1c should be 4bpp, and dxt3/5 should be 8bpp), then it doesn't really matter what bit depth they were before converting. There would be no difference in memory usage after conversion. (Just checked that with crystalspace devs).

Edit2: Ok, I checked in photoshop and they are 4bpp and 8bpp. When you open them they default convert to 8bpp anyway and you can choose to convert back to 24 or 32bpp, so there's no point in us converting the textures to 8bpp before converting to DDS. Evidence looks pretty conclusive to me.
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Induane on May 18, 2006, 11:14:29 pm
Yaskina, if you're having trouble with DDS you might try:

http://nifelheim.dyndns.org/~cocidius/dds/

Which is a link to a plugin for The Gimp that handles reading and writing DDS

Since you and I aren't using windows, it will require a compile to get the script working on our platforms, but its worth a shot.
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Yaskina on May 18, 2006, 11:21:34 pm
Ya i was going to try out gimp but i dont have the X11 backbone installed yet on this system. But i will have to as only way im going to be able to create mng files.
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: res on May 19, 2006, 01:18:54 am
DXT1c is colour only (no alpha),
DXT1a has that 1bit alpha.
DXT3 adds support for a four-bit explicit alpha channel, on top of DXT1's color compression. Four-bit explicit alpha allows for sixteen distinct alpha values, making it good for textures with sharply contrasting translucent/opaque areas.
DXT5 ssupports a four-bit interpolated alpha channel. Three bits are used to determine explicit alpha values, and two eight-bit values are used to interpolate gradually between them. This makes the format especially suited for soft gradients and other textures where the alpha areas vary less wildly. The least compressed option.

For the record:
DXT1c/DXT1a are essentially the same format; they compress to 4bits/bixel.
DXT3/DXt5 both compress to 8bits/pixel (hence "The least compressed option" is somewhat misleading; DXT3 is just as "bad").


What matters is that the engine and the graphics card have support for the texture. The first is a yes, and the second is most likely a yes unless you're using quite old hardware (not new enough to run modern games).

And even if the hardware does not support DXT compression, CS will uncompress it to something the hardware understands.



Please avoid posting two or more successive posts before others have replied. Just edit your last post to add new information. --Santiago
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Yaskina on May 19, 2006, 03:59:54 am
Cool stuff i just wanted to post an update regarding the crashing in the arena. I finally got my Toon stuck in the arena trying to find a leather trainer. So basicly it would just lock up on the loading screen no way to load in. tried a few times. So i thought because from all the playing around i did i had figured it was a graphic file that was the problem. So i then opened up the org zip for hyarena.zip and deleted all graphics in the file ( leaving the sound,xml, and cache) zipped it back up and loaded with it. Still no load into the zone same crash on loading screen. I then did the same thing to arena.zip and bingo im in and no crash. Sure i got checker boards for textures but im now unstuck. And i now know that the file thats a problem is in arena.zip and its a dup of a file thats in one of the other maps from hydlaa.

So i guess i should just rebuild that zip replacing all the dup names from hydlaa zips.

yesterday others that run this on pc computer said they had crashes at the 8 way intersection if they go down any of the stairs going down. could be another clue to which file but im not sure.

On the mac if i did not /die DR log in and out then goto arena i could hardly make to the top of the first set of steps going in.

Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Karyuu on May 19, 2006, 04:04:47 am
Something is up with your files, and it's probably just you - no one else has reported crashing when they enter the Arena, on a mac. Make sure you have the most recent files, etc., etc. Take a look at the MacOSX forum for further info.
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Yaskina on May 19, 2006, 04:25:31 am
Well so far i was asking around in the game and others did have a problem. 2 people yesterday say they crash on the stairs going down at the 8 way. And I did hear something about others going in a certain way to get in dont have the whole story on that one thou. And i can assure you I have used an updated version of the older .img and stock of the latest and they both crash fresh out of the box. unless i DR and then go, then im fine. It might be a minor thing that only affects certain hard ware or drivers. Its the only place that does this on Que for me anyways.
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Karyuu on May 19, 2006, 04:29:12 am
Crashing isn't quite the same thing as freezing at loading point, and usually a message comes up during a crash that is very useful for deciphering its origins. You should refer people to the Tech Help forums where they can get answers to their problems :] Let's not steer this further off-topic though.
Title: Re: Is PNG 32 bit used for all graphics/uvmapping?
Post by: Yaskina on May 19, 2006, 04:56:33 am
Sorry about that ya i always frooze up. Only time i crash in this game is when its really warm where i am. Which would normally only happen in the winter months when heat is cranked.