Jump to content
The Dark Mod Forums

Recommended Posts

Posted
  • I was using a completely flat patch.
  • what do you mean, I assume your not refering to the texture/scale controls in DR as thats not possible.

  • whether the patch is flat or not does not play any role
  • I mean shader parameters to be included in the material definition, for example

{
 blend diffusemap  //blend mode
 map texturename  //name of the image to apply
 scale 2,2  //decrease size by factor 2 in both x- and y-direction
 rotate 90  //rotate the texture by 90 degrees
 vertexColor  //apply vertex coloring
}

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

Posted

Ok, having a problem. Im trying to put the ambient stage into the material def, but no matter what I try it breaks the blend script.

 

textures/common/blend
{
 description  "a texture that is used on brushes to vertex blend two textures"

qer_editorimage textures/common/blend.tga
noshadows
}
textures/blend/grass_stone_blend
{
surftype15
description "grass & stone blend texture"
bumpmap textures/darkmod/nature/grass/short_dry_grass_local

// TDM blend Method Related - author Obsttorte

{
blend diffusemap		   //blend mode
map textures/darkmod/nature/grass/short_dry_grass_dark  //name of the image to apply
//scale 2,2			 //decrease size by factor 2 in both x- and y-direction
//rotate 90			 //rotate of the texture, as this can't be done in DR
VertexColor		    //apply vertex coloring
}

 // TDM Ambient Method Related
{	  
 if (global5 == 1) 
 blend add   
 map    textures/darkmod/nature/grass/short_dry_grass_dark 
 scale   1, 1 
 red    global2
 green   global3
 blue   global4
}	  
{	  
 if (global5 == 2) 
 blend add   
 program ambientEnvironment.vfp
 vertexParm  0  1, 1, 1, 1  // UV Scales for Diffuse and Bump
 vertexParm  1  1, 1, 1, 1 // (X,Y) UV Scale for specular 
 vertexParm  2  global2, global3, global4, 1

 fragmentMap  0  cubeMap env/gen1   
 fragmentMap  1  textures/darkmod/nature/grass/short_dry_grass_local   // Bump   
 fragmentMap  2  textures/darkmod/nature/grass/short_dry_grass_dark   // Diffuse  
 fragmentMap  3  _black   // Specular  
}
bumpmap textures/darkmod/stone/cobblestones/blocks_mixedsize02_multicolour_local
// TDM blend Method Related - author Obsttorte

{
blend diffusemap			   //blend mode
map textures/darkmod/stone/cobblestones/blocks_mixedsize02_multicolour  //name of the image to apply
//scale 2,2				 //decrease size by factor of 'x' in both x- and y-direction
//rotate 90				 //rotate of the texture, as this can't be done in DR
inverseVertexColor			   //apply vertex coloring
}

// TDM Ambient Method Related
{
 if (global5 == 1)
 blend add
 map    textures/darkmod/stone/cobblestones/blocks_mixedsize02_multicolour
 scale   1, 1
 red    global2
 green   global3
 blue   global4
}
{
 if (global5 == 2)
 blend add
 program ambientEnvironment.vfp
 vertexParm  0  1, 1, 1, 1  // UV Scales for Diffuse and Bump
 vertexParm  1  1, 1, 1, 1 // (X,Y) UV Scale for specular
 vertexParm  2  global2, global3, global4, 1
 fragmentMap  0  cubeMap env/gen1
 fragmentMap  1  textures/darkmod/stone/cobblestones/blocks_mixedsize02_multicolour_local   // Bump
 fragmentMap  2  textures/darkmod/stone/cobblestones/blocks_mixedsize02_multicolour   // Diffuse
 fragmentMap  3  _black   // Specular
}
}

bhm_banner.jpg

Posted

Oh yeah, having vertex colored ambient blend stages was actually missing from the initial forst-map release. Now if I could just remember where I posted the corrected material definition...

  • 3 months later...
Posted

Tried following my own instructions as show here, but when I try to export ist isnt working as the resuliting model looks as follows -

 

post-496-0-73225400-1389649950_thumb.jpg

 

 

And ideas whats going on as this should work as it did when I created the tut linked above, nothing has changed that I can see.

bhm_banner.jpg

  • 3 weeks later...
Posted

Tried following my own instructions as show here, but when I try to export ist isnt working as the resuliting model looks as follows -

post-496-0-73225400-1389649950_thumb.jpg

And ideas whats going on as this should work as it did when I created the tut linked above, nothing has changed that I can see.

@Obs, any idea on the above..?

bhm_banner.jpg

  • 2 weeks later...
Posted

It seems you've accidently exported the model with the default ase exporter, as the blend exporter does not export surfaces textured with the common/blend texture.

 

Using the Ase blend exporter gives me this result:

post-11230-0-44989200-1392141671_thumb.jpg

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

Posted

Regarding the textures you would have to change the material file (exchanging vertexColor and inverseVertexColor) or place the blend brushes differently.

 

However, as said the blend exporter does not export the blend surfaces, therefore you must have used the wrong exporter.

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

  • 1 year later...
Posted

No idea. This normally only happens if patches get stretched very strong, which isn't the case here.

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

Posted

I've seen this too when I made some modules. Sometimes a vault arch looked okay in DR as ordinary geometry, but when I made it into an .ase model, sometimes some parts were darker.

 

From Blender model making I,have the feeling it has something to do with extra vertices in a model: cleaning extra vertices fixed the darkening. Or wait, maybe it was because of incorrect smoothing groups? (I'm no specialist, but Arcturus or someone else modeling specialist would probably know the cause off-hand.)

 

In DR, however, we cannot just go and manually remove vertices, or manually adjust smoothing groups.

 

If it is because of vertices, you could play with the patch inspector. If you have manual tessellation, set it to auto for the patch and try exporting again. If you have it already on auto, switch to manual tessellation and test different settings. Perhaps you will find a setting where the black spots are minimal?

 

Also, what if you just move some of the vertices in the patch mesh, just a bit, near or at the blackened spots. Perhaps slight adjustment fixes the black posts when new vertices are generated?

Clipper

-The mapper's best friend.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recent Status Updates

    • JackFarmer

      "The Year of the Rat." 
      😄

      Al Stewart must be proud of you!
      Happy testing!
      @MirceaKitsune
      · 2 replies
    • datiswous

      I posted about it before, but I think the default tdm logo video looks outdated. For a (i.m.o.) better looking version, you can download the pk4 attached to this post and plonk it in your tdm root folder. Every mission that starts with the tdm logo then starts with the better looking one. Try for example mission COS1 Pearls and Swine.
      tdm_logo_video.pk4
      · 2 replies
    • JackFarmer

      Kill the bots! (see the "Who is online" bar)
      · 3 replies
    • STiFU

      I finished DOOM - The Dark Ages the other day. It is a decent shooter, but not as great as its predecessors, especially because of the soundtrack.
      · 5 replies
    • JackFarmer

      What do you know about a 40 degree day?
      @demagogue
      · 4 replies
×
×
  • Create New...