Create an account


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Any hack to avoid the limitation of 1 stage per shader?

#1
As i can read in .shader files and the internet, seems like Darkplaces only render one stage each shader.

It is true?
Im modeling some mapmodels and it is important to achieve some nice looking textures.

In the meantime im assumed this limitation in my WIP's
Reply

#2
it would be easier to help you, if you would say, what are you trying achieve
Reply

#3
This limitation cannot be solved, as it is a totally different renderer. It combines all stages it understands to a single GLSL shader.

Some kinds of texture blending are supported though - which also can be abused for detail textures, if that's what you are after.
BRLOGENSHFEGLE (core dumped)

The Bot Orchestra is back! | Xoylent Easter Egg | 5bots1piano
My music on Google Play and SoundCloud
Reply

#4
(10-19-2011, 06:56 AM)Morphed Wrote: it would be easier to help you, if you would say, what are you trying achieve

Its not something in particular, its only to know how far can i go with the shader scripting.

A easy solution to make 3 stages in one plane brush is... stack 3 brushes pretty close with one shader each brush Big Grin

Thanks for the answers.
Reply

#5
Yes, that often works.

Anyway: to see full capabilities of the shaders, best is to read engine source (model_shared.c).

Some details in comparison to Q3:

- DP only REALLY cares for one stage.
- Lightmap stage is ignored and only checked if it exists. It is not counted as shader stage.
- There is ONE occasion where DP uses two shader stages. Namely, when the first stage uses no blendfunc, and the second stage uses alpha blending (blendfunc blend).
- The following DP specific shader keywords exist, with no explanation here: dpshadow, dpnoshadow, dpnortlight, dpreflectcube, dpmeshcollisions, dpshaderkillifcvarzero, dpshaderkillifcvar, dpnoshaderkillifcvarzero, dpnoshaderkillifcvar, dppolygonoffset, dprefract, dpreflect, dpcamera, dpwater, dpwaterscroll, dpglossintensitymod, dprtlightambient, dpoffsetmapping
- dppolygonoffset allows arbitrary offsets, and thus can be used to stack multiple shaders on one place
BRLOGENSHFEGLE (core dumped)

The Bot Orchestra is back! | Xoylent Easter Egg | 5bots1piano
My music on Google Play and SoundCloud
Reply

#6
some examples and a bit more info can be found here: http://dpwiki.slipgateconstruct.com/inde...ion_for_DP
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  (Early Stage) Luma Theme Rework 2022 TheMatrix 5 1,271 02-28-2024, 07:06 PM
Last Post: TheMatrix
  [NEED HELP] Weapon shader isn't doing as I'm intending to do LegendGuard 0 1,049 04-04-2022, 07:23 AM
Last Post: LegendGuard
  Per Weapon Effect Brushes? Antares* 2 2,800 10-15-2017, 07:22 AM
Last Post: Julius
  Xonotic shader manual and tools? Binaryshi 6 6,053 07-22-2015, 12:12 PM
Last Post: tZork
  Can I Make an Edge Shader? MrDetonia 3 4,452 04-16-2015, 02:30 AM
Last Post: zeeshan002
  Shader Issues With Q3A Texture Replacement Packs Orbiter Sunblast 2 5,146 09-06-2013, 03:51 PM
Last Post: Orbiter Sunblast
  Inline GLSL in Q3 shader files? poVoq 3 4,230 06-16-2013, 11:51 AM
Last Post: poVoq
  Scripted Symphony - How we did it #1: The Stage CuBe0wL 5 5,835 10-12-2012, 08:50 AM
Last Post: chooksta
  Toon shader soukaina 10 9,475 10-11-2012, 12:04 PM
Last Post: rocknroll237
  Any ideas how to texture these patches? lamefun 3 4,875 09-08-2011, 03:02 AM
Last Post: BARTUC

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum software by © MyBB original theme © iAndrew 2016, remixed by -z-