Need help with editing a .VMT file

Modelling, Textures, Animating and other general engine asset topics.

Need help with editing a .VMT file

Postby Ashfall_2008 on Tue Mar 08, 2011 10:11 pm

I need to edit the following texture material file...

UnlitTwoTexture
{
$basetexture _rt_Camera
"%tooltexture" "dev/dev_monitor"
$surfaceprop glass

$texture2 "dev/dev_scanline"

$vertexcolor 1
$one 1
$zero 0
$temp 0
$texoffset "[0 0]"
$texscale .25
$tex2offset "[0 0]"
$tex2scale 1
$color_clamp 1
Proxies
{
Sine
{
resultVar "$color[0]"
sineperiod 1
sinemin .9
sinemax .92
}
Sine
{
resultVar "$color[1]"
sineperiod .01
sinemin .9
sinemax 1
}

GaussianNoise
{
mean "-.002"
halfwidth ".001"
resultVar "$texoffset[1]"
}
TextureTransform
{
translateVar $texoffset
resultVar $basetexturetransform
}

Sine
{
resultVar "$tex2offset[1]"
sineperiod 12
sinemin -3
sinemax 3
}
Sine
{
resultVar $tex2scale
sineperiod 2
sinemin .7
sinemax .9
}
TextureTransform
{
scaleVar $tex2scale
translateVar $tex2offset
resultVar $texture2transform
}
}
}

This VMT is a camera output monitor type .vmt with an overlay applied. It outputs the image from the current active point_camera. The overlay is a security camera effect with lines moving back and forth over the camera image. I want to remove the 2nd overlay named "dev/dev_scanline" and the 2nd image movement.

So I simply want a .vmt that will show the "dev/dev_monitor" image.

If anyone can help I'd really appreciate it!

:)
Ashfall_2008
Regular
Regular
 
Joined: Sat Feb 12, 2011 1:39 pm

Re: Need help with editing a .VMT file

Postby MayheM on Tue Mar 08, 2011 10:23 pm

The easiest way i can think of to do this is just replace the dev/dev_scanlines with your own texture. Simple make a completely transparent texture and name it "noscanlines" and put it wherever. Then replace the line "dev/dev_csanlines" with the "foldername/noscanlines".

That should eliminate the lines. The effect may still be running but it will not have an effect shown since it is fully transparent.
Image
User avatar
MayheM
Veteran
Veteran
 
Joined: Tue Oct 16, 2007 7:46 pm
Location: Lancaster SC

Re: Need help with editing a .VMT file

Postby Ashfall_2008 on Tue Mar 08, 2011 10:35 pm

Isn't it odd.. that was my first thought lol. I tried it. I may have screwed up the texture creation however. not sure how to make a properly transparent texture. will try that again.

thanks for the suggestion mate.
Ashfall_2008
Regular
Regular
 
Joined: Sat Feb 12, 2011 1:39 pm

Re: Need help with editing a .VMT file

Postby Ashfall_2008 on Tue Mar 08, 2011 11:20 pm

Oooh further advice.. will try...
Last edited by Ashfall_2008 on Tue Mar 08, 2011 11:25 pm, edited 1 time in total.
Ashfall_2008
Regular
Regular
 
Joined: Sat Feb 12, 2011 1:39 pm

Re: Need help with editing a .VMT file

Postby MayheM on Tue Mar 08, 2011 11:23 pm

It would just be an image with a fully black alpha channel. If you are converting a TGA file you want to save it as a 32bit TGA to save the alpha channel into he file. Normally when you reference an overlay or something you don't need to have a VMT for the overlay or effect. At least thats how it is with normal maps and spec maps. But since this is looking at something that has an alpha, you may need to create a VMT and just make sure you add "$translucent" "1"


I could be way off on this, but it should work...
Image
User avatar
MayheM
Veteran
Veteran
 
Joined: Tue Oct 16, 2007 7:46 pm
Location: Lancaster SC

Re: Need help with editing a .VMT file

Postby Ashfall_2008 on Tue Mar 08, 2011 11:42 pm

No dice.. I shall keep tinkering! Will get you an update when I make a breakthrough... :)
Ashfall_2008
Regular
Regular
 
Joined: Sat Feb 12, 2011 1:39 pm

Re: Need help with editing a .VMT file

Postby Ashfall_2008 on Wed Mar 09, 2011 12:39 am

Oh lord just shoot me in the head right now... I was being a fool!

I was altering the texture files in my mod folder rather than the game folder... have cleaned the image up by changing the vmf to the following...

UnlitGeneric
{
$basetexture _rt_Camera
"%tooltexture" "dev/dev_monitor"
$surfaceprop glass
}

Now get clear image with no overlay...

Thanks for all your help man. Sorry I was being a numpty!
Ashfall_2008
Regular
Regular
 
Joined: Sat Feb 12, 2011 1:39 pm

Re: Need help with editing a .VMT file

Postby MayheM on Wed Mar 09, 2011 8:37 pm

I would accept your apology if I knew what a numpty was...

But yeah I guess that makes sense that all you had to do was clear all the other stuff out. Glad you got it working...
Image
User avatar
MayheM
Veteran
Veteran
 
Joined: Tue Oct 16, 2007 7:46 pm
Location: Lancaster SC

Return to Art Creation

Who is online

Users browsing this forum: No registered users