Go Back   Steam Users' Forums > Steam Game Discussions > # - C > Alien Swarm

Reply
 
Thread Tools Display Modes
Old 06-23-2014, 07:47 AM   #1
_mamorex_
 
 
 
Join Date: May 2014
Reputation: 0
Posts: 3
Parallax mapping shader in Alien Swarm code from SDK - how to use it?

I found uncompiled "parallaxtest" shader in Alien Swarm SDK code directory (SteamApps\common\Alien Swarm\sdk_src\materialsystem\stdshaders) and compiled in Alien Swarm, CS:GO and SFM directories ("shaders" folders) and I hope that will be work. I uploaded a three shaders code at Pastebin, who have a mention about parallax mapping, because it's lot of code and I can't making spoiler.

lightmappedgeneric_dx9.cpp - http://pastebin.com/Gj4NNCs2
lightmappedgeneric_dx9_helper.cpp - http://pastebin.com/Jha24xmg
parallaxtest.cpp - http://pastebin.com/5RS2mp0S

On this video someone used that shaders (I think) and it's work.
http://www.youtube.com/watch?v=UXKviuIeDYQ

My .vmt with parameters from these shaders isn't working.

Code:
"LightmappedGeneric"
{

"$basetexture" "parallax/test"
"$bumpmap" "parallax/test_n"
"$envmap" "env_cubemap"
"$parallaxmap" "1"
"$height_scale" "0.1"
"$bumpframe" "0"

}
Have you any idea, how do this?

From parallaxtest.cpp:
Code:
SHADER_PARAM( BUMPMAP, SHADER_PARAM_TYPE_TEXTURE, "models/shadertest/shader1_normal", "bump map" )
SHADER_PARAM( BUMPFRAME, SHADER_PARAM_TYPE_INTEGER, "0", "frame number for $bumpmap" )
From lightmappedgeneric_dx9.cpp:
Code:
SHADER_PARAM( PARALLAXMAP, SHADER_PARAM_TYPE_INTEGER, "0", "1=treat alpha of bumpmap as height" )
SHADER_PARAM( HEIGHT_SCALE, SHADER_PARAM_TYPE_FLOAT, "0.1", "height map scale for parallax mapping" )

Last edited by _mamorex_: 06-23-2014 at 07:51 AM.
_mamorex_ is offline  
Reply With Quote
Reply

Go Back   Steam Users' Forums > Steam Game Discussions > # - C > Alien Swarm


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



All times are GMT -7. The time now is 03:42 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2017, vBulletin Solutions, Inc.
Site Content Copyright Valve Corporation 1998-2015, All Rights Reserved.