Game Development Community

Pixel Shaders???

by Marco Meier · in Torque Game Engine · 06/10/2002 (4:35 am) · 18 replies

Hello All!

Does Torque already support shaders? So, Vertex and Pixel Shader? If not, is someone working on this.
I would love to see this feature in the engine.
So anyone know something about that?

Much thanks!

#1
06/10/2002 (9:08 am)
The Torque uses OpenGL directly so you can just get the vertex extension and start using shaders right now.

None of the current objects use shaders to render. It will be at least another 2-3 years before a majority of game players have shader compatible cards and we can start writing games that requires shaders. Then we’ll be worry about what version of the shader spec the card can handle …it never ends does it?

Until then if you decide to use shaders you will also need to provide a fixed function pipeline fallback: 2x the work for a very small percentage of your audience.

--Rick
#2
06/10/2002 (10:01 am)
The only released PC game I know of to use pixel shading is (the very recent) Morrowind... and only in very select spots... the pixel shader for the water looks pretty nice, but I also saw the game running on a GForce2 (no pixel shading) and it wasn't missed all too much...

Once DoomIII is out and people see some magic... they may desire it more... right now, the average gamer doesn't have the hardware... nor do they even know what they are missing...

It'll all work itself out, including the way they are programmed... right now, it's a bit of a buzzword... most of what I have seen are demos which hog waaaaay too many frames to be practical...

I want to use pixel shaders once there are some funky design tools & premade effect libraries... been there and done that with low level rendering code, pixel shaders are kind of like going back to the days of handmade rasterizers... if that's your bag you will have a blast... I want to work a bit higher level

Very very cool stuff and necessary to advance what is possible in realtime...

One thing that Torque could perhaps use is a shader library like QuakeIII ... would be easy to implement and allows some nice effects to be quickly put together by artists... I would guess there is a thread or two already about this...

For now: Gameplay, Gameplay, Gameplay

-J
#3
06/12/2002 (10:50 pm)
Much thanks for your answers and your opinions. I will look into it and decide if i will use them.

Thanks.
#4
06/13/2002 (10:29 am)
I started this thread. Thought you folks may be interested.

www.garagegames.com/index.php?sec=mg&mod=forums&page=result.thread&qt=5745

- Melv.
#5
06/17/2002 (1:30 pm)
Hi all,

"It will be at least another 2-3 years before a majority of game players have shader compatible cards and we can start writing games that requires shaders."
"2x the work for a very small percentage of your audience"





The current mind-set of the PC's game industry (developers, programmers, and publishers) is on-par with the above quoted text, and is why the console market is taking off and the PC market is dying. Just check out how many developers over the past few years have switched from PC to console development.

99.9% of PC games are falling way behind consoles such as the Xbox and PS2 (and even compared to the now-discontinued Sega Dreamcast), both in sales and in over-all quality.
Mostly because these consoles are putting to use the intrinsic hardware features, which developers and publishers on the PC are being hard-headed about.

Here's a bit of industry info for developers to chew upon:
(pcvsconsole.com http://www.pcvsconsole.com/pc/news/1159.html)
"... Console and portable software sales rose 8.3 percent in unit sales ..." (2001 vs 2000) THAT'S OVER 2X THE PC INCREASE!
"... while PC entertainment software experienced a unit increase of 3.8 percent ..." (2001 vs 2000)
"... PlayStation 2 accessories led all platforms in accessory sales in 2001 ..."
"... The number one console title ... (PS2 GTA3) ... sold just under two million units ..." (Oct 2001 through Feb 2002 = 5 MONTHS!)
"... The Sims by Electronic Arts was the number one PC entertainment game, it sold over 2.6 million units life-to-date, and debuted more than two years ago. ..." (MORE THAN 2 YEARS TO GET THOSE SALES FIGURES!)

For starters, a huge number of PC users have video cards with advanced (read: shader etc.) capabilities.
The number of higher-end ATI and nVidia cards sold is a large market size (within the game PC market).
And every serious gamer will have one of these cards in their PC... period!

Just look at the various polls and information collected from places such as MadOnion and GameSpy, you'll find that most gamers are running GeForce3/4 and Radeon products.
And the industry pundits who state that these are still less than XX% of the total PC marketshare, I say: who are you selling the games to? Business people? No, Gamers!

I also don't understand the PC developers mind-set that follows that (all) PC games should support the entire world's legacy hardware set and use every available input device including every complex set of keystrokes that they can twist our fingers into. If you are developing simulators for aero-space, fine, but this is gaming folks.
The PC game developers need to take a hard look at the console game market.

I guess that's why I recently switched from PC gaming to owning both an Xbox and a Dreamcast.
The only stuff I'm looking forward to on the PC is UT2003 and Doom3. Virtually everyone else developing is either stalled or stuck.

Unless PC game developers get with it, the PC game market is going to continue to shrink.

David
#6
06/17/2002 (1:48 pm)
David,

You seem to be missing the point. The PC market for games is SIGNIFICANTLY smaller than the console market.

A typical AAA game for PC sells 200-250k units. A typical AAA title on console sells 1million or more.

Also, its almost impossible for a non-best-selling PC game to achieve break even sales figures (i.e. cost of development).

Cutting your market space in ANY way on PC (i.e. requiring shader capable hardware) is just ensuring your title isnt viable.

If doom 3 came out by another company than ID, its likely that it would have almost no sales. Because its ID perhaps some of the hardcore will upgrade to be able to run it at a decent rate.

As it is, these hardware advances make development significantly easier and faster (you dont have to be as clever about what youre rendering, you just have to streamline the throuput) however its almost impossible for a company to do this because effectively you leave anything below a GF3 to die. Most companies couldnt afford to cut thier market so much.

Phil.
#7
06/17/2002 (1:52 pm)
And obviously all thats required to make a great game is using the latest hardware to produce the best graphics possible.



No amount of shader code is going to make or break a game. Period. Its just not that important. Maybe to the FPS crowd where that might be the only thing to set your game apart from the rest, but to the rest of the industry thats not the most important thing.

Sure pixel and vertex shaders are nice, and you can get some really nice effects with them, but like they said above it is really quite a bit more work for a rather small percentage of the total possible audience. Especially for indy developers, that time might be better spent on gameplay, more/better features, story, etc.

The reason console games can push the technology to the limits is the same reason that they can (and do) optimize the hell out of it. Consoles are a target that stands still, and you know that anything you do will benefit everyone who plays the game. On the PC side, if only 5% of your audience will see the benefit from something, then maybe its not worth the time just yet.
#8
06/17/2002 (2:20 pm)
Phil and Dave,

No argument or flaming meant...

Phil, I get your point, but perhaps you missed mine?

Perhaps if the PC developers put more work into games that competed with (and beat out) the consoles, then perhaps the PC market would grow. Instead, they continue to put out mediocre quality titles, so people are switching, and the PC market is dwindling.

Only a few short years ago, the console market was virtually nothing, and the PC ruled. Poor developing and marketing ideals has submarined the PC for gaming.

DoomIII is not even in the arena yet.
There are already a few PC games out that utilize extra video hardware features (Serious Sam for one). There's no reason why others cannot (except laziness and the hard-headed attitude of supporting every legacy device).

People go out and spend $300-500 on an Xbox and a few games because the game graphics beat-out their home PC.
That's more than enough money to equip your PC with an nVidia or ATI -- but what are you going to play on it? There's virtually nothing for titles that have competing quality.
It seems that Epic/DE and id are the only ones who see this.


Dave, it's more than just the hardware, as my previous post stated. I was using shaders as one example of where consoles are beating PCs.
Compare virtually any driving game on the Xbox (a 733MHz PIII/GeForce3) with PCs -- everything from true reflections to bump-mapping on roads etc. to water-shaders.
There is *no* reason why this cannot be done on the PC, as most hardware *in use by gamers now* supports it.
And Dave, only 5%? Perhaps you better go do some research (I have).

Again, look at the MadOnion and GameSpy polls, most gamers have the hardware.
Those who don't are simply switching to consoles because the developers aren't giving them a reason to upgrade.

David
#9
06/17/2002 (2:27 pm)
PC Gaming is smaller than console... yup

Hardcore gamers hit Gamespy and MadOnion (the reason people hit MadOnion is to test their new spanky video card)

Hardcore gamers are a segment of the smaller PC market... they are also hard to please...

There is a much larger segment of casual gamers... find a niche these people enjoy (like Deer Hunting, Paintball, CIA/Cop stuff... etc)... and you have a good chance...

Getting into Walmart/Target etc doesn't hurt either... most large publishers have a budget software division now...

Just some thoughts... no absolutes...

-J
#10
06/17/2002 (2:42 pm)
Hi,

"PC Gaming is smaller than console... yup"

Didn't use to be...
I guess I'm telling my age cuz I still have my Magnavox Oddysee and I fondly remember the fall of Intellivision and ColecoVision and the console market. That's about when the PC took over as leader (for a time).

"Hardcore gamers are a segment of the smaller PC market..."

Release a few games like Brute Force or Halo (FPS), Dead or Alive 3 (Combat), Project Gotham Racing, etc., and casual gamers will upgrade, even those who aren't hard-core.
Gamers want people who look (more) like people (DOA3), not square headed box-men like Max Payne.

I don't classify myself as hard-core and I have an ATI 8500 (replaced a Voodoo5).
The last games I bought were UT, Q3A, and Tribes2. There hasn't been anything else good since then.

Developers also need to get out of the "Counter-Strike" mindset.
I'm sure Jeff (GG) would agree that there are too many "same-old" formula games for the PC. This is mostly due to publishers only taking formula titles. The PC is badly suffering from lack-of-game inspiration.

David
#11
06/17/2002 (3:48 pm)
Well David,

I do agree with you to a certain extent. I just don't think that graphics are really the biggest selling point. I mean look at The Sims, the best selling PC game ever. The graphics are not what one would call "stellar."

You mention the games that are pushing the Xbox to the limits, and thats all well and good. But are they really good games because they have true reflections or bump-mapped roads? No, they're good because they're fun to play.

Now gamer's PCs range from worse than the Xbox all the way to better than it, and thats what the PC developer has to work with. The way I see it is that a game should push the hardware as hard as it can take it, but you gotta be able to scale back to those lower end PCs too. Thus *requiring* video cards that have shader support cuts out a large portion of your possible audience. Making it optionally turned off works to let those lower end cards play too.

The thing is you have to balance those two. It really depends where you are aiming, but the majority of PC gamers are not hard core types that upgrade whenever possible. If 50% of your audience will be able to have the "great new effect" turned on then maybe they're worth it, but if only 15% will get the effects then maybe its not. With a console its *always* worth it 'cause everyone will get the effect. And btw, that 5% that I mentioned above was completely random and not even refering to shader capable cards or anything.

I totally agree that there are many games in the PC market that are just take the mentality that " sold a lot so we'll do something similar." That doesn't mean that a) there aren't good games on the PC, or b) that the same thing doesn't happen on the consoles.

You're obviously focussing on the FPS'ish genre, so you're not noticing all the good RPGs, or Flight Sims, or whatever else. Plus, just as a personal thing, I can't stand FPS's on consoles, not enough control. :-)

Which also brings up the point that the two markets (console and PC) are very different, not only in their hardware and game selection, but also the gamers that they cater to. PC games tend to lean towards the more "advanced" control or realism (or whatever you'd call it), and also tend to be more in depth. Console games tend to cater to the crowd that wants to "Jump in and kill things right now!" Obviously these boundries are pretty blurry tho. This also doesn't take into account the cost of owning the hardware to run these games. When a brand new graphics card costs the same amount or more than a whole console, many people who "don't care" what they play on will go to a console.

My main point is that it isn't the graphics that make the game, its the gameplay.
#12
06/18/2002 (12:04 pm)
And then there are those of us who still use NES emulators to play the old Final Fantasy series because they were good games. Good graphics and good gameplay are mutually exclusive. Right now, shaders are good for cool effects which I will go so far as to call "gimicks". The current use is simply people adding them because they are fun to play with, and they'll look nice if people have the hardware.

The shader thing will really take off is when developers can assume shader hardware on 90% of the PC market. That means when Dell/HP/Gateway/Micron etc have been shipping shader hardware cards for about 2 years. The release of the GeForce 4 MX with no hardware shader support was a serious knock back for that.

The lack of a common shader language is also an issue. If you want a game that supports OpenGL, and DirectX, you need to write 4 versions of each shader. One for ATI OpenGL, ATI DX, nVidia OGL, nVidia DX. Supposidly the Cg from nVidia narrows that down to 3 shaders total, however with Matrox pulling its tri-annual beat-the-crap-out-of-every-card-on-the-market release, that may increase. The shader OGL extension that ATI uses is a extension agreed on by at least 3 OGL vendors on the OGL board, so it's possible that ATI and Matrox use the same shader extensions for OGL.

Also, there's a lot of clamor for shaders I've noticed. "Does this engine support shaders?" "Are shaders in yet?" However I seriously doubt that anyone, if asked, would know exactly what they'd do with the shaders. I'm not talking about, "I'd make water look cool." I'm talking about exactly how they'd do that. I've given it a bit of thought and the only shader I coded was a fisheye and that was easy because there was some colleges CS website that had an implimentation of a 2d version that was used on bitmaps, so it was easy to translate that into a shader.

Shaders are academic right now. It's like CS professors going on about how wonderful of a language Haskell is. Yeah, great. Someone remade ML with a few additions. It's fast, it's lazy, wooptydoo.
#13
06/18/2002 (12:55 pm)
Pat, I'd disagree that shaders arent useful RIGHT NOW, I'd LOVE to have a shader language control my textures and surface attributes. Currently there is FAR too much hard coded state pipeline code in torque that would be so much easier to understand via a shader.

By shader, i mean surface description format. Think Quake3 shader file and thats my definition. Those things are actually VERY useful.

David: Whilst I agree that many PC games simply look poor compared to most console games, thats also down to cost/benefit. Simply put, console games offer more return, therefore they can support longer development cycles (which produce better content).

However, I think poor quality character models is just down to lack of quality control. I must admit to being slightly pissed off myself at the REALLY low quality seen in many PC games. Its just incredible in this age of pushing quarter of a million poly's a frame, that you cant allocate enough to have a nicely rounded model.

How many times have you seen a soul calibre quality model on a PC? never. Never has happened. I dont think thats for any technical reason.

PC's have more grunt than consoles... so its not a technical issue.

Phil.
#14
06/18/2002 (12:55 pm)
Hi all,

I really don't understand the negative responses that most everyone here gives the advanced graphics features... well yeah, I guess I do...
It is difficult for most people to move beyond that which they know and are comfortable with. Complacency is easier.


I think you all need to go and rent an Xbox this weekend with copies of Halo, DOA3, BloodWake, Project Gotham Racing, and OddWorld...


I mean look at The Sims, the best selling PC game ever. The graphics are not what one would call "stellar."

I found the decade-old graphics to be a bit of a downer for the Sims, however, it did bring out sort-of an "80's" feeling to the game.
However, The Sims is not of the class of game that normally benefits from advanced graphics hardware feature support. I'm referring to FPS, RPG, Sports, etc. (UT, Quake, Tribes, Need for Speed, Flight Sims, etc. etc.) Basically every other genre on the PC...

You mention the games that are pushing the Xbox to the limits

Actually, according to MS and Xbox developers, the games I mentioned are only using approximately 30% of the Xbox's full power. To date no one game has pushed the Xbox to its limit. Give them a year or two.

The way I see it is that a game should push the hardware as hard as it can take it, but you gotta be able to scale back to those lower end PCs too

Why?
Everyone seems to be missing the entire point I've been making from the beginning. Everyone seems to be stuck on the "GeForce3 and ATI8500 are only 10% of the whole PC Market"... but 90% of the PC market is business and low-end home PCs!! That 10% of the whole market is 75% of the Gamers!!
Anyone who is playing games such as UT, Tribes2, Q3A is *going* to have higher end gear! And anyone who is looking at purchasing UT2003 and DoomIII already has high-end gear!! How can I get that into people's heads.

I can't stand FPS's on consoles, not enough control

I agree. I found Halo (Xbox) difficult to control compared to the Mouse/Keyboard on the PC.

PC games tend to lean towards the more "advanced" control or realism (or whatever you'd call it), and also tend to be more in depth

A moment earlier you mentioned The Sims on the PC, now your saying PC games lean towards realism?? :-)

If you want games with more realism, start using pixel and vertex shaders, bump mapping, environment reflection, etc. etc.
Compare [Xbox] Project Gotham Racing, Burnout, Wreckless or RalliSport Challenge to [PC] Need For Speed Porsche Unleashed... the difference that having a more realistic environment to move within makes the game considerably more enjoyable.

My main point is that it isn't the graphics that make the game, its the gameplay

I disagree... it's both.
You can't tell me that Q3A's better graphics are not more immersive than the original Castle Wolfenstein... or that even the original Doom wasn't more immersive than the original CW. That's due to the more realistic graphics and environment -- immersion.


Good graphics and good gameplay are mutually exclusive

Sorry, but that's one of the most silly things I've ever heard on a game developer board.

I thought games were supposed to look realistic, be immersive, be fun.
Imagine how much more immersive Tribes2 would be with bump-mapped ground, trees, buildings; vehicles with environment reflection; water with shaders, etc. Shaders are even used for creating better cel graphics (toon) etc.
Come on people...

Right now, shaders are good for cool effects which I will go so far as to call "gimicks". The current use is simply people adding them because they are fun to play with, and they'll look nice if people have the hardware

Another silly comment. See my previous reply.
I guess that having 24-bit color and 24-bit textures are a waste too since graphics are secondary.
Why not pull the 24-bit texture support from Torque and go with 8-bit only? There's no support for 24-bit textures on video hardware such as the Voodoo3 and various other legacy (earlier) models...

The lack of a common shader language is also an issue

DirectX, OpenGL extensions, nVidia CG... would you like a few web links?
I guess you expect everything to be already done for you.
There are already other PC game engines out there using advanced features, but I guess why bother on this engine.
Support for GeForce and Radeon are all that is required.
If developers started actually doing something in this area, then these two extensions would become the standard and any other video hardware developers would have to follow suit to be marketable.

I'm not talking about, "I'd make water look cool." I'm talking about exactly how they'd do that.

Go to ATI's site, MS's DirectX site (MSDN), NVidia's site, and the OpenGL org site... how many examples and white papers do you need?? I'll gather up a bunch of links for you if you like..

Shaders are academic right now

Well, then I guess I'd rather be an academic student.
Sounds to me like people are afraid of the future, and the bit of work it may take to get there...
I strongly suggest that you rent an Xbox and play a few games, then you may realize why advanced video hardware features are the way that games are going to go. Anyone who doesn't get into that area now will be left behind...

David
#15
06/18/2002 (1:06 pm)
Phil,

Just replying to your earlier post...


You seem to be missing the point. The PC market for games is SIGNIFICANTLY smaller than the console market

Actually, I understand that. I mentioned so in one of my replies. The PC market used to be larger, but it's because the games were too flakey, crashy, buggy, and didn't keep up with technology that the consoles took over. People don't want to have to download a patch for the install program just to find they have to download a patch for the game... QC for PC games suck, and the testers need to be fired.

A typical AAA game for PC sells 200-250k units

Actually most go Gold or better (1/2 million copies).

however its almost impossible for a company to do this because effectively you leave anything below a GF3 to die. Most companies couldnt afford to cut thier market so much

The same could be said for the early 3D video hardware that didn't support 24-bit textures. Gamers upgraded their hardware as soon as the developers moved over to 24-bit.
It's less expensive to upgrade your PC than to purchase an Xbox.

David
#16
06/18/2002 (1:42 pm)
This is a bit silly...

XBox = PS2 = $200 (Gamecube=$150) and you can rent the games

Xbox = PS2 = Gamecube = game has a marketing budget or it isn't being made

Xbox = PS2 = Gamecube = unified system to develop for

Xbox = PS2 = Gamecube = Absolute Microsoft, Sony, or Nintendo control

Not sure what the point is exactly?

The strength of PC gaming is in NOT having to create what the console systems are locked into because of budgeting/what have you...

If it comes down to PC games competing with Console on a "level" playing field... GTA3 on PS2 or GTA3 on PC ... I'll sit on my couch and play thanks...

BTW: Xbox is just a loss leading PC hidden inside a game console...

In independant land, you can't count on the big boys playing with you... so you have to play different...

-J
#17
06/18/2002 (2:29 pm)
Joshua,

Not sure what the point is exactly?

I'm still not sure what the point is exactly... it seems a bit off-topic to me since this is a discussion about supporting shaders etc., I am open to debate though...

My prior mentioning of the Xbox console and how it relates to this thread is for two reasons:
1. They are using advanced video hardware features such as pixel and vertex shaders, bump-mapping, etc.
2. It is basically the same hardware and software as what most every gamer's PC is and has been for the past two years, ie: the Xbox is an equal or lesser powered system than what most PC gamers are currently running.


The strength of PC gaming is in NOT having to create what the console systems are locked into because of budgeting/what have you

Then why are 99.9% of PC games below today's standards?
Why are the consoles now out-selling the once top-of-the-market game PC?
Also, why are 99% of PC games "formula" games? Because publishers won't publish anything that's not "locked" into what they feel is marketable (can we say CounterStrike clone?).

(North American) Developers are taking the "wait and see" attitude (waiting for Epic/DE and id) and are falling behind. Meanwhile, other small startups in places like Croatia are writing engines that beat us.
Game developers and publishers need to wake up and start becoming the leaders and innovators in the marketplace, not the followers. If not, the PC game market will continue to get smaller each month.


BTW: Xbox is just a loss leading PC hidden inside a game console

I don't see where this matters to this topic. In fact, it more-so strengthens my points:

The Xbox is a PIII-733/GeForce3/DirectX/8GB-HDD system...
The current low-end PC machine that mommy buys for Timmy so he can play his games is a P4-1.5GHz/GeForce3 or ATI8500/DirectX/40GB+ system...
So why are PC game developers producing titles that lack so far behind the Xbox?
It is not because of the Xbox being a "standardized/unified" platform... where's the difference between it and your common gamer PC? nVidia vs 8500 is minimal at best.

David
#18
06/19/2002 (11:01 pm)
Interesting thread. Sorry if this doesn't directly address the topic, and in no particular order:

1. PC games might be of a lower overall quality presentation-wise because of the lower cost of entry. To be a console developer is saying more than being a PC developer. I didn't have to buy a dev kit to start fiddling with game programming on my PC.

2. Someone mentioned current X-Box games are only using '20% - 30%' of its power. I've played a good deal of Halo, and it has framerate issues, in both single and multiplayer. I'm not an expert on Halo or the X-Box, so take that with a grain of salt. Maybe my eye is trained to expect 60 fps.

3. Consoles are on an upswing right now, and will be for a few years. Three years from now, before the next generation hits, they will seem quite quaint. I don't have enough data to call this a cycle - I'm just recalling how great the original playstation was, along with the N64 (but not the Saturn, heh). Then I got my first 3dfx card and downloaded a copy of glquake.

4. The prettiest released game I've seen is IL-2. Blood Wake? Bah.

Interesting times though, to be sure.

-X