Quake3World.com https://www.quake3world.com/forum/ |
|
Decals https://www.quake3world.com/forum/viewtopic.php?f=10&t=47628 |
Page 1 of 1 |
Author: | Eraser [ 05-22-2012 01:29 AM ] |
Post subject: | Decals |
Ok, bit of a newbie question, but what does a decal shader and texture look like again? I want to create a set of decals I can place in my map on existing surfaces to break up the monotony of a large textured face a bit. You know, stuff like stains and blood spatters and such. |
Author: | cityy [ 05-22-2012 01:38 AM ] |
Post subject: | Re: Decals |
Here you go: http://www.tabun.nl/dl/tab_decals_a.zip |
Author: | Eraser [ 05-22-2012 01:44 AM ] |
Post subject: | Re: Decals |
That is awesome bro. Thanks a lot! |
Author: | obsidian [ 05-22-2012 06:05 AM ] |
Post subject: | Re: Decals |
http://q3map2.robotrenegade.com/docs/sh ... ricks.html |
Author: | Eraser [ 05-22-2012 06:43 AM ] |
Post subject: | Re: Decals |
Just a tip for those wishing to use the decals in cityy's ZIP file. The decal shaders in there will causes your brushes to cast shadows. Just add "surfaceparm trans" to fix that. Also, obsidian suggested adding q3map_bounceScale 0 to prevent the brush from reflecting radiosity light: Code: textures/_MAP_/tab_decal_stain_a { noPicMip polygonOffset surfaceparm nonsolid surfaceparm nomarks surfaceparm trans q3map_bounceScale 0 { map textures/_MAP_/tab_decal_stain_a.tga blendFunc GL_ZERO GL_ONE_MINUS_SRC_COLOR } } There's also some great decal textures over at cgtextures. Note that you'll have to invert the colors and add a black background before you can use them with the supplied shaders though. |
Author: | CZghost [ 05-22-2012 07:18 AM ] |
Post subject: | Re: Decals |
Wow, thanks for the decal textures, maybe I'll use it in my next map for MavComp#4... EDIT: If I use the _decal projection, the range is from _decal patch and info_null entity but as the _decal patch is large or small, the decal will be also projected only in this size or the patch size is unimportant? |
Author: | CZghost [ 05-22-2012 08:49 AM ] |
Post subject: | Re: Decals |
Tried the _decal projection in my EP testing map for tagret_gravity, doesn't work... I've captured few screenshots from a game and two from editor, how it looks like. Editor screenshots: In-game screenshots: In the robotrenegade page is written: Quote: Make a simple patch mesh (it can be bent, but the quads in Radiant must be rectangular), select it and use the right-click context menu to turn it into a _decal entity. Target an info_null below the _decal entity and compile. Everything between the decal patch and the info_null will have a decal projected onto it. Dou you can to specify what axis should be in use and how is calculated the distance? |
Author: | obsidian [ 05-22-2012 09:33 AM ] |
Post subject: | Re: Decals |
If it's just a flat wall, just paste a normal decal patch on it and be done with it. Decal entities are only if you want to project a decal onto complicated/multiple geometry that would normally be restrictive with a single patch. You have the entire entity/target facing the wrong way, the patch can "float" anywhere it and it targets an info_null that should be placed behind the surface you want it to project onto. The texture will be projected on everything between the patch and the info_null. There is no distance value, it will literally project on every surface between the patch and target. You specify axis by moving the target/rotating the patch. |
Author: | Eraser [ 05-22-2012 10:28 AM ] |
Post subject: | Re: Decals |
Is there some benefit to using a patch instead of a nodraw brush that has one face textured with the decal shader? |
Author: | obsidian [ 05-22-2012 11:58 AM ] |
Post subject: | Re: Decals |
No, that will work too. Patch is maybe easier to move around, identify and filter as a decal. Some textures (like the blood streaks used in Doom 3) are easier to stretch and bend as a patch. |
Author: | Theftbot [ 05-22-2012 12:12 PM ] |
Post subject: | Re: Decals |
Dont forget to make brush detail if you do |
Author: | CZghost [ 05-23-2012 12:20 AM ] |
Post subject: | Re: Decals |
So I've done it wrong. the target_null may be behind surface to project and distance doesn't matter... If it's brush, it may be detail. Patches are detailed automaticaly? I'll try it as I'll get home from school... |
Author: | Eraser [ 05-23-2012 01:24 AM ] |
Post subject: | Re: Decals |
CZghost wrote: Patches are detailed automaticaly? The short answer is yes. |
Author: | CZghost [ 05-23-2012 05:34 AM ] |
Post subject: | Re: Decals |
Eraser wrote: CZghost wrote: Patches are detailed automaticaly? The short answer is yes. And the long answer? Because when I've tried to add a detail keyword to the decal shaders, it was floating in air and displaing dummy texture. Then I've removed the detail keyword. Shaders now was displaing right textures, but again floating in air... So I'm asking, what's wrong? The target_null is now behind the decals and the _decal before the decals... _decal patch have nodraw common texture, is it this wrong? Will the _decal entity display in game when use solid texture? If it's possible, make me please screenshot from editor and from game with and without tris, how it may look like... I'm using Radiant 1.5 In the robotrenegade page are in-game screenshots, but not the radiant sceens... Does ydnar still develope the q3map2 and make maps? |
Author: | Eraser [ 05-23-2012 05:54 AM ] |
Post subject: | Re: Decals |
- Create a brush. - Place an info_null entity behind it. - Place a patch in front of it and give this patch the decal shader you want. - Turn the patch into a _decal entity - Have the patch target the info_null entity. - Compile. As I understand it, that is what you need. The shader applied to the patch will be projected on the brush between the patch and the info_null entity. I'm not sure what the difference is between the "detail" surfaceparm and the "trans" surfaceparm. The shader manual says basically the same thing about both of them. I don't think you ever need to use the "detail" surfaceparm as you can make brushes detail in the editor (hit CTRL+M when having a brush selected). I know that the "trans" surfaceparm stops the surface from blocking light, so maybe it does both or perhaps it has no effect on VIS and the shader manual is wrong. Someone should test this. But I digress. What you need to do is follow the steps I put at the beginning of this post and forget about detail brushes because patches have no effect on the VIS stage of compiling your map so in that sense, patches are similar to detail brushes. |
Author: | obsidian [ 05-23-2012 06:11 AM ] |
Post subject: | Re: Decals |
Author: | CZghost [ 05-23-2012 07:03 AM ] |
Post subject: | Re: Decals |
Very thx, it's functionable now... I'll sketch the _decal usage |
Page 1 of 1 | All times are UTC - 8 hours |
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group http://www.phpbb.com/ |