|
7 registered members (fairtrader, Quad, miwok, Martin_HH, AndrewAMD, alibaba, dpn),
581
guests, and 0
spiders. |
|
Key:
Admin,
Global Mod,
Mod
|
|
|
Re: Terrain multitexturing shader for PS 1.4
[Re: indiGLOW]
#22877
02/07/04 06:51
02/07/04 06:51
|
Joined: Dec 2003
Posts: 1,097 Maryland, USA
Steempipe
OP
Serious User
|
OP
Serious User
Joined: Dec 2003
Posts: 1,097
Maryland, USA
|
@indiGLOW: Thanks for the kind words and stars!
The TGA is here, if needed for investigation: argbmap.rar
So..... up in the vertex shader... the constant declarations #[65],[66], & [67] are where you can assign the values for the u_scale and v_scale. I suppose they could all be set by the vecSkill arguments by just using [64]. I saw how ventilator had added [65] to the 3 texture terrain code and then I decided to use [66] and [67].
vertexShaderConstant[ 64]=<vecSkill41>;
vertexShaderConstant[ 65]=( 20.0f,15.0f ,0.0f,0.0f);
vertexShaderConstant[ 66]=(25.0f,35.0f,0.0f,0.0f);
vertexShaderConstant[ 67]=(25.0f,20.0f,0.0f,0.0f);
In the vertex shader we use them here:
mul oT0.xy,v7.xy,c 64.xy
mul oT1.xy,v7.xy,c 64.zw
mul oT2.xy,v7.xy,c 65.xy
mov oT3.xy,v7.xy
mul oT4.xy,v7.xy,c 66.xy
mul oT5.xy,v7.xy,c 67.xy
////////////////////
You have a good idea about using "maps" to place objects. It would be very useful to me as well.
This weekend I will spend alot of time reading about these shaders. Much is very confusing to me and I need to get some of the basics figured out. I also want to make fallbacks for PS1.1-1.3 and no shaders before I move along too far down the road.
//////////////////
**I would be very interested to see screenshots of your, and anyone else's, results.
|
|
|
Re: Terrain multitexturing shader for PS 1.4
[Re: Steempipe]
#22878
02/09/04 02:00
02/09/04 02:00
|
Joined: Oct 2003
Posts: 1,550 United Kingdom
indiGLOW
Serious User
|
Serious User
Joined: Oct 2003
Posts: 1,550
United Kingdom
|
Just to let you know where I am up too.....
I have altered your multi-terrain multi-shader's tiling and illumination settings, to create the effect I have been looking for.
I have used 512x512 images for the textures, and then used a 1024,1024 alpha,rgb, skin for tiling settings. I know understand TGA's and alphas and channels far more than i ever did!
I am creating a demo level that will include all of my progress so far, including a nice rain effect that looks fantastic [IMHO]...especially with the super realistic terrain texturing, and sky environment.
I am working on the waving grass shader, and double sided polies to create realistic foilage, bushes, plants and tree branches. Once that is done I will start work on some kind of distribution system, using a multichannel tga. Theoretically using the same process 4-6, (maybe more) , different models/sprites could be populated according to the map. There would then be a random element to the distrubution, a negative factor, but for grass it could work very well.
I dont want to sidetrack this thread to much, so I will leave that thought alone for now, maybe someone will know how to do what we are talking about, and when I return to this puzzle I will start a new thread, (if theres not one already)
I will try to post some screen shots of my terrain over the next few days.
Keep fighting the good fight!
The Art of Conversation is dead : Discuss
|
|
|
Re: Terrain multitexturing shader for PS 1.4
[Re: Kevin_Ross]
#22882
02/09/04 09:36
02/09/04 09:36
|
Joined: Dec 2003
Posts: 1,097 Maryland, USA
Steempipe
OP
Serious User
|
OP
Serious User
Joined: Dec 2003
Posts: 1,097
Maryland, USA
|
Quote:
How much video memory does this consume when you do this many passes?
I have not figured out any of the math on that. But I will give you whatever info that I can and maybe you can "decode" it.
I have two flavors of the exact same project. One build with PS one without.
Here is an F11 shot using the terrain multitex shader:
My images for the passes and rendering: (5) images are bitmaps at 256x256x24 and each has a mipmap chain. (1) image is the argb TGA and it is 512x512x32
Here is an F11 shot using just 1 base texture and detail texture in MED
There is one entSkin as base 256x256x24 BMP w/mip There is one entSkin as detail 128x128x24 BMP w/mip
Quote:
Also are the TGA maps the same size as the skin?.
Right now, in my project... no. The TGA is 512x512 while the skins are 256x256. I had no problems with using a TGA that was 256x256 instead, tho.
Quote:
Is is possible to post code example. We been so much in A5 and porting to A6 we are now going into shaders for final effects and found this thread very interesting to combat a few terrain skin problems we been having to do outdoors with.
If my job is not too demanding this week I hope to get the resources and code avail at my website. I mainly just need to clean up the work folder, some code, and also figure out where I give credit for the textures.
Eric
|
|
|
Re: Terrain multitexturing shader for PS 1.4
[Re: Steempipe]
#22883
02/09/04 22:58
02/09/04 22:58
|
Joined: Jul 2003
Posts: 1,563
blaaaaa
Expert
|
Expert
Joined: Jul 2003
Posts: 1,563
|
Bei mir siehts echt gut aus im vergleich zu detail mapping : vorher :  und mit dem multitexture shader : ich find nur das das terrain jetzt etwas dunkel ist aber das lässt sich ja ändern. also jetz fehlt nur noch schatten auf terrain und das man im wed das terrain auch texturiert sieht und nicht nur blau und dann bin ich glücklich  aber ich find das sch***** das es nur auf neueren grafikkarten geht schliesslich wollen ja auch andere leute mit schlechteren grafikkarten meine spiele spielen also von daher muss ich mir noch was einfallen lassen. es ist nunmal so das noch längst nich jeder eine directX9 grafikkarte hat und die anderen können das dann nicht anzeigen. gibt es nicht sowas wie eine fallback funktion die dann das terrain mit detail maps auf non-directX9 grafikkarten anzeigt und mit den besseren mit shader multitexturing ?? ps : es läuft bei mir so mit 70-80 fps ( 3 1024x1024 texturen und 5041 vertices ( vorher waren es 30,000 aber ich hab das terrain doch lieber "etwas" reduziert  ) man sieht das terrain jetz geil aus ich glaub ich bekomm gleich nen orgasmus  *loool*
|
|
|
|