Beginner continued...Standard assets - water

First - Hurray! Finally I was able to purchase Unity Pro today, I am so happy.

If there is anywhere we can put tutorial requests in, I’d like to add one for the standard assests water. I don’t know what to do with it or where to look to get any information that might already exist - All I seem to get at the moment is a flat colour blue plane. A step by step tut on how to make reflective water look nice would be very handy :slight_smile:
Thanks
Boxy

Take a look at the Pro Standard Assets folder.
(If it is not there import the ProStandardAssets package)

There is a scene called Samples.unity which shows the reflective water shader and refractive glass shader.

Do those work for you?

Oh my that looks nice :slight_smile:
Apologies, I didn’t have the Pro Assets installed in my project.
Thanks
Boxy

Attached is how the reflective water looks on my screen. From boxy’s reaction, I assume something is wrong…

Is this a problem with the graphics card, or is there some setting incorrectly set in my Unity install?

NVIDIA GeForce4 MX:

  Chipset Model:	GeForce4 MX
  Type:	Display
  Bus:	AGP
  VRAM (Total):	32 MB
  Vendor:	nVIDIA (0x10de)
  Device ID:	0x0174
  Revision ID:	0x00a5
  ROM Revision:	1510
  Displays:
iMac:
  Display Type:	LCD
  Resolution:	1440 x 900
  Depth:	32-bit Color
  Built-In:	Yes
  Core Image:	Not Supported
  Main Display:	Yes
  Mirror:	Off
  Online:	Yes
  Quartz Extreme:	Supported
Display:
  Online:	No
  Status:	No display connected

You are using 1.2.1? Did you try creating a new project from scratch and then open the samples.unity scene in the pro standard assets?

The water will never look good on a GeForceMX, but it should look better than that!

I’m making water for our next game and will get whatever I come up with into the standard assets as well…

I create a new project with nothing but the pro assets and get the following (and many other) errors:

Shade 'FX/WaterPlane (reflective)': No subshaders can run on this card
Log in file:  at line: -1

The other errors are subshader errors, too, caused by a number of “Hidden/*” shaders. I have also noticed that the screens in the Overwhelmed Arena game are blank – the game screenshot suggests something should be rendered on them. Without reference screenshots, I can’t tell how things are really supposed to look.

I haven’t been able to find any sort of graphics card / Unity feature matrix indicating what graphical features Unity will support on which card. Is something like this out there somewhere? Something like this would be rather important to know what target platforms can be expected to run Unity games with reasonable quality.

Tom

Basically; all shaders should fall back to something dull but workable. The fact that they do not is our bug. Please send me a complete list of shaders that fail.

All source code for the built-in shaders is available here; http://forum.otee.dk/viewtopic.php?t=940

The basic principle is that bumpmapping requires a Radeon9000, GeforceFX or above. The same goes for all bumpmapping shaders EXCEPT the parralax bump.
parallaxbump requires a Radeon 9500, GeForceFX or above

Older cards (Geforce1-4, Rage, Radeon 7500, etc) mainly get only vertex lighting. This is what we shipped in gooball and everybody with these cards were SO impressed that we managed to pull so much out of their cards… weird, really… Must’ve been the glow.

Also

The water reflective shader from the zipped up resource (from the above link), is different from the same shader in 1.2.1. The “old” one does not throw an error. Just from eyeballing the files it looks like the shader in 1.2.1 has a couple subshaders commented out.

So, there may be a configuration management issue with the shaders and the baseline. :wink: (Alternatively, there might be an issue with the Unity installer. However, I don’t recall installing Unity before this year.)

Having the shader compile correctly is certainly a good thing, and the default render looks promising, albeit rotated oddly. (See the first image.) Unfortunately, once I start the demo running, the image goes completely black. (See the second image.) Any ideas on what is going wrong? Could the render script also be an incorrect version?

Tom


7694--295--$running_183.png

That could very well be due to lacking video memory. The mac is pretty bad at just giving you a random texture. When we start renderering, it would then be just black.

Try turning dow texture quality from the preferences, see if that helps.

Or, upgrade you GFX card - we can certainly make the shaders work for your customers with a GefroceMX, but that doesn’t mean you want to develop with it. In your case, its a bit like using a PS1 to develop as PS2 game.

I tried changing the texture quality and got the same results on both a Geforce4 w/32MB and a Geforce3 w/64MB.

If it’s any consolation, I checked it on a Geforce FX 5200 w/128MB and it looks nice. The refraction of the stained glass, the reflectivity and transparancy of the water, and the waves – they all look great.

When I make a game, support to the customer becomes my responsibility. I have to determine whether a shader works or doesn’t work on a particular video card, and the customer shouldn’t need to know what a shader is. The game just needs to work. Programming shaders is new stuff for me, though, and I have an expectaction that the sample shaders provided with Unity are better than anything I can write at this time. Therefore, they become the benchmark determining what systems I can and cannot support.

The technologist in me is happy to work with the latest and greatest, but the business reality is that Apple’s strategy doesn’t work that way. Macs have a very long life, and most of the models do not allow upgrading the video card. I could turn to a Windows user and say “you need XYZ video card to run this,” and there’s an expectaction that many users will go out and upgrade their video card to play the game. That’s the norm in the Windows world. That’s not the norm in the mac world, however, especially when we look at the casual gamer market. (How many women – over 35, married, with children – are going to try and upgrade the video card in their iMac to play Mahjong?)

There are two philosphies on making games – make the most feature packed game and try to make it degrade gracefully for users of lower-end systems, or make a good core game and then layer on features that get activated on higher-end systems. I personnally prefer the latter approach, because it means core gameplay takes center stage and eye candy is just gravy. I think Darwinia is a recent example that highlights how import the core gameplay is. (It’s also a good case study in the importance of distribution channels.)

So, I’m trying to decide where to draw the line on what to support or not support. I have already made the decision to support both Mac and Windows. (And I thank you for making that possible. :wink:) I’m not terribly concerned about minimum system requirements for Windows users because they are used to (and expect) to be pushed to upgrade by new software. However, I really don’t think the general Mac population accepts the notion that their hardware becomes obsolete every year. Ultimately, then, I need to generate a table that shows which Macs I will support. That table is derived from 1) what I can support with Unity, and 2) an analysis of the market share of those Macs within the total Mac market space.

Kind of long winded, and off the topic of shader details, but I hope this helps explain where I’m coming from.

Tom

Hi Tom. Thanks for your mail on what works and what doesn’t. I’ve included the list you sent me here for reference:

The “Hidden” effects you should not worry about. They are part of our image-based effects, and the scripts that use them detect this and disables the effect. The rest I will fix (which mainly involves figuring out which shaders they should fall back to)

My main concern is that you don’t hold back your development or get scared away by a feeling that “this junk doesn’t work”. I can see from your post that is not the case.

We’re currently developing an educational title (see www.seriousgames.dk ), and have many of the same concerns (schools are not really up to date either). Here’s how we approach it:

We develop everything with for a baseline of a GeForceFX5200. This card has all features, but low performance. For lower cards we use the fallbacks. Since we Know shaders (I made the shader system), we will use custom shaders for a lot of things. I can help you with that once you get further into production.

I would recommend you go for a baseline of any GeForce or a Radeon7500. That’s what we did with GooBall, and it worked out well. We got a few requests for older cards, but they were not many. The main thing about that baseline is that you can count on hardware T&L* - this means that the graphic guys can expect decent polygon budgets (GooBall had a rule-of-thumb of 40.000 tris onscreen).

You can author with bumpmaps, but don’t count on end users having access to it. Strictly in the eye candy department. Again, doing the full bumpmapping thingy means a lot of asset production, so there IS a budget concern there as well. Losing bumpmaps is nowhere near as hard on your graphic artists than having to do a lower LOD for all ingame graphics.

Just out of interest, what are you planning to do with Unity?

  • T&L: On the PC side there is an “interesting” problem: Intel Extreme graphic cards. They have hardware pixel shaders but only software T&L. This goes quote a bit against the 40.000 poly count, but I don’t know enough about it to really be sure how big an issue it is.

Nicholas wrote,

Make games, of course. :wink:

The most immediate project (once I’m comfortable in the environment) is a multiplayer underwater game. There are a few other projects that have been on the back burner for some time, but the underwater one is currently at the top of the list.

Tom