1. Forums
  2. Discord
  3. About Mapcore
  4. Patreon Supporters
  • Login
  • Register
  • Search
This Thread
  • Everywhere
  • This Thread
  • This Forum
  • Articles
  • Pages
  • Forum
  • More Options
  1. Mapcore
  2. Discussions
  3. Level Design

Source shaders preview?

  • Latka X-treme
  • September 22, 2007 at 4:20 PM
  • Latka X-treme
    • September 22, 2007 at 4:20 PM
    • #1

    Hi guys!

    I'd like to know if there is an other method for checking Source ingame grafics, without opening any Source games? Let me describe:

    I'd like to make a model for a Source mod. As all you know the textures (along with shaders) are controlled by vmt files. To make the model look as good as possible, I need to play around with the vmt files. But everytime I want to make sure how the model looks like, I need to place the model in a map, open the mod, and check the model there (if the model is small, I also need to zoom in). This is pain in the ass everytime I do it, and I'm not even sure if it looks alright. I wonder if there is a tool, or if you can set the Source Model Viewer to display the model as it will appear in-game.

    (Note: some modifications' models (such as Fortress Forever, or Age of Chivalry) can be displayed in the Model Viewer as it appears ingame - so with normalmaps and such, but I cant display my models that way.)

    Can someone help me?

    Thanks

  • Wunderboy
    • September 22, 2007 at 4:58 PM
    • #2

    Err, HLMV uses the same engine as the game so what you see in HLMV *is* how it will appear in game (although the lighting is just a simple single light).

    The alternative is to just put your model in a map and use the various console commands, i.e. if you reload the textures it updates it from any changes you made to the VMT.

    Failing that, use GMOD to drop the model into a map and reload the textures when you change them.

    Thought some of you might find these useful for testing models and checking performance issues with big textures, etc. Most of them require sv_cheats on to work.

    The texture memory display might be good for comparing just how much memory those lovely 2048x2048 diffuse+bump+phong textures take up and the model stats overlay for checking how long your models take to draw, etc.

    Shader Control

    These control parts of the material shader system. Mostly they allow you to turn on/off different features in the engine.

    mat_bumpmap 0/1- Turns off/on bump mapping (normal maps).

    mat_fastnobump 0/1 - Turns off/on bump mapping (normal maps) quickly without reloading materials.

    mat_diffuse 0/1 - Turns off/on diffuse textures (kinda pointless to use!).

    mat_drawwater 0/1- Turns off/on water.

    mat_fullbright 0/1 - Turns off/on fullbright lighting.

    mat_hsv 0/1 - Turns off/on Huse, Saturation, Value colour space (in mose cases, makes B&W).

    mat_specular 0/1 - Turns off/on specular mapping (reflective surfaces like glass).

    mat_fastspecular 0/1 - Turns off/on specular mapping quickly but wont reload materials.

    mat_mipmaptextures 0/1 - Turns off/on mip map textures.

    r_phong 0/1 - Turns off/on phong lighting (doesn't work?).

    Diagnostic

    These provide info about the graphics system and graphics hardware.

    mat_configcurrent - Dumps the current graphics config to the console.

    mat_info - Dumps the current spec, properties and support of the graphic hardware.

    mat_fillrate 0/1 - Shows density of fillrate for pixels (of limited use, pretty cool though!)

    mat_luxels 0/1 - Shows density lightmap grid

    mat_showhistogram 0/1 - Show histogram of colour distribution in the frame.

    mat_show_texture_memory_usage 0/1 - Show current memory useage in kilobytes for the current frame.

    Textures

    These related mostly to textures and materials. Useful if you edit a texture and need to reload it without re-starting the game.

    mat_picmip 0...4 - Sets the quality of textures by using lower mipmap levels instead of the larger. Doesn't give much of a FPS increase but doesn't reduce texture memory useage.

    [Blocked Image: http://img100.imageshack.us/img100/4030/matpicmipnf7.th.jpg]

    mat_crosshair - Shows the name of the texture currently under the crosshair.

    mat_show_ab_hdr 0/1 - Turns off/on splitscreen display of Non-HDR/HDR comparison.

    mat_reloadallmaterials - Reloads all the materials. (VMT)

    mat_reloadmaterial - Reload material(s) with in its name. (VMT)

    mat_reloadtextures - Reloads all textures. (VTF)

    mat_texturelimit - Sets the limit in kilobytes the material system will use per frame. -1 = infinite.

    +mat_texture_list - Toggle showing a list of all textures including name, type and memory size (bind to a key)

    mat_wireframe 0/1 - Shows a wireframe overlay on map surfaces and shows models as wireframe only.

    Models

    These are useful for debugging and testing model issues such as performance, types and collision hulls.

    r_colorstaticprops 0/1 - Shows static prop models in different colours.

    r_drawdetailprops 0/1 - Draw detail prop models.

    r_drawothermodels 0/1/2 - Draw non static models. 0 off, 1 on, 2 wireframe.

    r_drawmodelstatsoverlay 0/1/2 - Draws and info overlay non-static models you can see. 0 off, 1 on, 2 measured.

    r_drawmodelstatsoverlay 0/1/2 - Show info overlay for non-static models you can see. 0 off, 1 on, 2 measured.

    r_drawmodelstatsoverlaymin - Minimum time in milliseconds a model needs to take to draw to be displayed when the stats overlay mode is "measured".

    r_drawmodelstatsoverlaymax - Maxumum number time in milliseconds a model can take to draw before it is displayed red in stats overlay mode is "measured"

    vcollide_wireframe 0/1 - Draws the collision model wireframe for models. Static are blue, physics, red.

    vcollide_wireframe_axis 0/1 - Draws the orientation and origin axis for collision models.

  • Latka X-treme
    • September 22, 2007 at 6:42 PM
    • #3

    Interesting... I see my latest model's normalmaps inside Model Viewer.

    I think it's because I exported my tgas into vtf from Photoshop properly...

    (You can take a look at the HL2 models in Model Viewer and you cant see the models' normalmaps, even if you turn that display on...

    A better example is Fortress Forever's Sentrygun models: while level1 and level3 displays the normalmaps, level2 doesnt...)

    But thanks for the long info you showed there... I bet I get that useful

  • Buddy
    • September 22, 2007 at 6:49 PM
    • #4

    Models with wrong scale are not properly displayed in HLMV, if you change scale (ie scale down), normal maps will be visible.

  • Latka X-treme
    • September 22, 2007 at 7:53 PM
    • #5

    What do you mean by wrong scale?

    Mine is 1024×1024 which works, while on another model the same resolution doesn't work...

  • Buddy
    • September 22, 2007 at 8:30 PM
    • #6

    Model/Mesh/Geometry Scale not the texture.

  • mjens
    • September 22, 2007 at 10:34 PM
    • #7
    Quote from buddy the designer

    Model/Mesh/Geometry Scale not the texture.

    Reply my PM

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!

Register Yourself Login
Discord

The Mapcore Discord is our lively IRC channel of the 2000s reborn. Chat about level design, gaming, and more.

Latest Posts

  1. Custom Gamemodes Contest

    Angel
    July 20, 2026 at 11:46 AM
  2. FAQ

    Angel
    July 20, 2026 at 10:14 AM
  3. Tangerine

    Harry Poster
    July 18, 2026 at 11:10 AM
  4. Any of the old guard still around? D:

    Warby
    July 12, 2026 at 8:23 PM
  5. About our archived forums

    Thrik
    June 30, 2026 at 2:12 PM
  6. Mapcore Discord

    mason_fan123
    June 24, 2026 at 8:52 PM
  7. [CS2] Valley

    Serialmapper
    June 22, 2026 at 11:56 AM
  8. Free Music / SFX Resource - Over 2500 Tracks

    Eric Matyas
    June 18, 2026 at 12:32 PM
  9. Pango [WIP]

    Elowen
    June 11, 2026 at 10:13 AM
  10. [CS2] Dvina

    Jeremy Rivera
    June 11, 2026 at 10:03 AM

Users Viewing This Thread

  • 1 Guest
  1. Privacy Policy
  2. Contact
Powered by WoltLab Suite™