Source 2 Viewer

Browse VPK archives, view, export, and decompile Source 2 assets, including maps, models, materials, textures, sounds.

Fully open-source and reverse-engineered.

Download v20.1
Screenshot of Source 2 Viewer displaying a 3D rendered map of Inferno Night with detailed lighting and textures
Inferno Night by Angel, created by decompiling with S2V

One tool for every Source 2 asset

Render, inspect, extract, and decompile files from CS2, Dota 2, Deadlock, Half-Life: Alyx, and every other Source 2 game.

Screenshot of the 3D renderer displaying a Counter-Strike 2 player model on a grid

Models & Animation

Preview any model with its animations, skeleton, and physics.

  • Animation playback with scrubbing, slow motion, root motion, and additive layers
  • Show skeletons, attachments, hitboxes, and physics shapes
  • Switch LODs, mesh groups, and material skins
  • Facial flexes, morph targets, bone constraints, and IK
  • Animation clips and skeletons from AnimGraph 2 (vnmclip, vnmskel)
Screenshot showing the VPK package explorer interface with a file tree and a list view

VPK Viewer & Extractor

Open game archives without unpacking them, and extract single files or whole folders.

  • Open VPK files from any Source 1 or Source 2 game, including VPKs inside VPKs
  • Folder tree with a detail list or a grid of rendered thumbnails
  • Search by name, path, regex, file contents, hex bytes, or asset info
  • Back and forward navigation, path bar, and quick preview
  • Export files as is or decompiled, choosing the output format per file type
  • Background extraction with progress, time estimate, and cancel
  • Recover deleted files left in VPK archives
  • Build new VPKs from folders and files, and verify signatures and checksums
  • Copy vpk: links that open a file directly in Source 2 Viewer
Screenshot of the animation graph viewer showing nodes

Node Graph Viewers

Animation graphs, Pulse scripts, and map entity I/O drawn as node graphs.

  • Animation graphs (vanmgrph, vnmgraph) with expandable state machines
  • Pulse graphs (vpulse) rebuilt from compiled bytecode
  • Entity I/O graph for maps, linked to the 3D view
  • Models and maps show their animation graphs and Pulse scripts as tabs
  • Search, filter, auto layout, and export graphs as images

3D Renderer

  • View maps, models, physics, particles, and materials from CS2, Dota 2, Deadlock, and other Source 2 games
  • Reverse-engineered game shaders with dynamic shadows, lightmaps, light probes, and cubemaps
  • GPU-driven OpenGL rendering with frustum, occlusion, and meshlet culling
  • Tiled light culling for maps with hundreds of lights
  • Bloom, depth of field, auto exposure, and color correction
  • Clutter, decals, and 3D skyboxes in maps
  • Debug render modes, overdraw view, and a performance overlay

Map Viewer

  • Click any entity to inspect its properties, inputs, and outputs
  • Walk around maps with Counter-Strike movement: collisions, ladders, bunny hopping, and surfing
  • First-person CS2 weapon viewmodel and crosshair in walk mode
  • Doors, buttons, triggers, and logic entities work as they do in the game
  • 3D positional sound with soundscapes and sound events
  • Toggle world layers and physics groups, and jump to map cameras
  • Navigation meshes, visibility clusters, and CS2 bomb damage overlays
  • WASD fly camera with orbit mode and customizable FOV

Source 2 Decompiler

  • Maps (vmap_c → vmap) for Hammer with entities, editable meshes, props, overlays, and ropes
  • Models (vmdl_c → vmdl) for ModelDoc with animations, physics, hitboxes, morphs, and cloth
  • Materials (vmat_c → vmat) with textures unpacked to their original inputs
  • Animation graphs, clips, and skeletons
  • Particles, post-processing, Panorama, choreo scenes, and closed captions
  • Sounds with reconstructed lip-sync phonemes
  • Produce editable assets for Source 2 Workshop Tools

glTF Export

  • Export maps, models, physics, animations, and navigation meshes to glTF 2.0
  • Skinned meshes, morph targets, and material skins
  • Root motion, additive animations, and morph weight animations
  • Materials converted to glTF PBR, keeping the original Source 2 parameters
  • Opens in Blender, Unity, and Unreal Engine
  • Batch export whole folders with textures as separate images

Texture Viewer

  • View textures, images, and SVGs per color channel or with all channels side by side
  • Save textures as PNG, JPG, or EXR for HDR, and export SVGs at any scale
  • Mip levels, depth slices, cubemap faces, and equirectangular projection
  • Animated sprite sheet playback with frame scrubbing
  • Normal map, YCoCg, and color space conversion toggles
  • GPU decoding with a software fallback
  • Color correction lookup tables (vpost)
  • UV tiling preview, zoom, and pan

Particles & Materials

  • Particle systems with sprites, trails, ropes, models, decals, and child systems
  • Particle lighting, scene collisions, and detail level selection
  • Operator list that flags unsupported operators
  • Particle snapshots (vsnap)
  • Live material editing with shader-defined parameter ranges
  • Preview materials on different meshes and jump to their shader

Audio

  • Built-in audio player with waveform, seeking, and looping
  • Play WAV, MP3, and Source 2 sounds (PCM, ADPCM, MP3, AAC)
  • Sound events play in the map, model, and particle viewers
  • Volume control and per-tab mute
  • Keyboard controls and auto-play in preview mode

Shader Packages

  • Browse Source 2 shader files (vcs) as a tree of static and dynamic combos
  • Inspect parameters, combos, constraints, and render state
  • Reconstruct VFX source for whole shader collections
  • Decompile Vulkan SPIR-V to readable HLSL or GLSL
  • Open raw SPIR-V files and export shader bytecode
  • Compiled shader versions 58 through 72

Source 2 Resource Files

  • Open vtex_c, vmdl_c, vmat_c, vpcf_c, and all Source 2 file types
  • View every resource block in its own tab
  • Browse external references and open them with a double-click
  • Decode binary data to readable KeyValues3 text

User Interface

  • Tabs with middle-click close, bulk close, and reload
  • Dark and light themes, or follow the system setting
  • Explorer lists VPKs, maps, shaders, and Workshop items from installed Steam games
  • Recent files and bookmarks
  • Drag and drop any file onto the window
  • Keyboard shortcuts, with hints for the active viewer
  • Register as the handler for .vpk files and vpk: links
  • Built-in updater with stable and dev channels

Additional File Formats

  • Navigation meshes (.nav) in 3D, grid navigation (.gnv), and ToolsAssetInfo (.bin) files
  • World nodes (vwnod_c) and visibility data (vvis)
  • KeyValues3 binary and text, binary KeyValues1, and DMX files
  • Closed captions, choreo scenes, and facial animation (.vfe) files
  • PNG, JPG, GIF, and SVG images
  • Hex viewer and text viewer with syntax highlighting

Libraries and command line

Use the same .NET libraries as Source 2 Viewer in your own projects, or export files from scripts with the command line tool.

Command line utility

Export and decompile Source 2 resources from the command line on Windows, Linux, and macOS.

ValveResourceFormat

.NET library that powers Source 2 Viewer (S2V), also known as VRF. This library can be used to open and extract Source 2 resource files programmatically.

ValveResourceFormat.Renderer

.NET library providing an OpenGL-based rendering engine for Source 2 assets. Standalone rendering of models, maps, particles, animations, lighting, and materials with physically-based rendering (PBR).

ValvePak

.NET library to read Valve Pak (VPK) archives. VPK files are uncompressed archives used to package game content. This library allows you to read and extract files out of these paks.

ValveKeyValue

.NET library to read and write files in Valve key value format. This library aims to be fully compatible with Valve's various implementations of KeyValues format parsing.

Screenshot of the command line interface showing DATA block for an audio file
Source2Viewer-CLI printing the data block of a sound file
C#
// Open package and read a file
using var package = new Package();
package.Read("pak01_dir.vpk");

var packageEntry = package.FindEntry("textures/debug.vtex_c");
package.ReadEntry(packageEntry, out var rawFile);

// Read file as a resource
using var ms = new MemoryStream(rawFile);
using var resource = new Resource();
resource.Read(ms);

Debug.Assert(resource.ResourceType == ResourceType.Texture);

// Get a png from the texture
var texture = (Texture)resource.DataBlock;
using var bitmap = texture.GenerateBitmap();
var png = TextureExtract.ToPngImage(bitmap);

File.WriteAllBytes("image.png", png);

Changelog

v20.1

This release adds support for files from the latest CS2 and Deadlock updates.

Library

  • Added support for compiled shaders version 72
  • Added support for KeyValues3 types 26 and 27
  • Added support for R8_UNORM textures
  • Added support for tools asset info version 16
  • Fixed decoding of search path flags, modification times and empty strings in tools asset info

View commits since 20.0

v20.0

Overdraw Debug View

Renders a heatmap of triangle overdraw using the same shader as the Source2 tools, accurate to the game and can be used for optimising maps.

image

3D Sound System

Map and model viewers now play sound. vsndevts events are mixed on their own thread with distance volume curves, stereo panning and per-mix-group levels.

Performance Stats

New "Debug Performance" option showing general renderer stats, allocations and timings.

This (especially stats) can be used as an analogue for real source2 rendering to some degree in order to help optimise maps, things like total drawcalls, materials, etc are accurate.

image

Puddles and Rain

CS2 environment materials render their wet weather state, with puddles, a wetness sheen, scrolling wave normals and procedural rain splashes.

Entity I/O Graph

Entity lumps and maps now have an entity I/O graph tab, drawing every entity as a node with its Hammer editor icon and every connection as a labelled wire. Nodes link with the 3D viewer.

image

Pulse and Animation Graph Viewers

Pulse graphs are rebuilt from their compiled bytecode back into readable node graphs, and AnimGraph 1 graphs draw alongside them, both compiled and straight out of the editor. Every graph viewer shares one canvas with panning, zooming, search, filtering, island focus and image export.

image image

CS2 Bomb Blast Visualization

Mirrors CS2's Baked bomb damage debug view, drawn as animated arrows pointing along the blast direction, coloured from green where a blast is lethal through to red where it is harmless.

Untriangulated Hammer Meshes

Meshes decompiled into Hammer meshes are no longer a wall of triangles: adjacent triangles sharing a material are merged back into quads.

image

GUI

  • Added an entity I/O graph tab to entity lumps and maps
  • Added point_template spawn wires and two-way navigation with the map viewer
  • Added a pulse graph tab rebuilt from compiled Pulse bytecode
  • Added pulse loop nodes, timeline cells and variable hubs
  • Added an AnimGraph 1 graph tab for compiled and uncompiled animation graphs
  • Added a shared graph canvas with a zoom-faded dot grid, Ctrl+0 to fit, and wire gutters between columns
  • Added a graph sidebar with search, filters, a colour legend and image export
  • Added a CS2 bomb blast visualization
  • Added a bomb damage viewer for baked_bomb_damage.vdata_c files
  • Added a render statistics overlay for triangles, draw calls and lights
  • Added a particle snapshot (vsnap) viewer
  • Added a viewer for uncompiled KV3 text files
  • Added back and forward navigation to the package viewer
  • Added a "Level of Detail" dropdown to the model viewer
  • Added an Inputs tab to the entity info panel
  • Added a "Reconstructed phonemes" tab to sounds with lip-sync data
  • Added a plaintext phoneme .txt dump when extracting those sounds
  • Added an "Export image" dialog for SVG-backed images
  • Added a volume slider and per-tab muting
  • Added a Play Endcap button and detail level selector to the particle viewer
  • Improved the AnimGraph 2 viewer with expandable state machines
  • Model viewer
    • Added an "Additive (over bind pose)" checkbox
    • Improved "Show Root Motion" to walk the model through the loop point
  • File previews
    • Added a loading panel with the file icon, name and a progress bar
    • Changed previews to collapse the side panel when too narrow
  • Enabled barn lights by default
  • Changed the map viewer to open at a player spawn
  • Changed camera FOV to horizontal degrees at 4:3 defaulting to 90, and added "Viewmodel FOV"
  • Changed entity focus to avoid camera spots inside geometry
  • Changed "Show Render Timings" into a "Debug Performance" selector, cycled with Tab
  • Changed map loading to warm up shaders up front, removing fly-around stutter
  • Changed the entity properties grid to open resource paths on double click
  • Fixed concurrent OpenGL window creation crashing viewers and thumbnails
  • Fixed the console tab dropping lines when several threads logged at once
  • Fixed extracting a file over a larger one leaving the old tail appended
  • Fixed files added to a VPK being listed twice
  • Fixed models whose LOD0 is empty rendering nothing
  • Fixed the opening fly-in skipping straight to its end position
  • Fixed the FPS counter reading far too high after opening a scene
  • Fixed playback of some MPEG 2.5 MP3 files

Renderer

  • Added a 3D sound system to the map and model viewers:
    • Map ambience from env_soundscape, snd_soundscape, point_soundevent and snd_event_point
    • Animation sound events, following the named attachment
    • Player footstep, jump, landing, gear and fall damage sounds, plus CS2 viewmodel attacks
    • MP3 gapless trimming, 8, 16, 24 and 32-bit PCM, and MS ADPCM
  • Added a simulated entity system running map entities on a fixed 64 tick
  • Added 2.5D tiled light culling, with LightTiles, EnvmapTiles and Subgroups debug modes
  • Added a QuadOverdraw debug render mode painting overdraw as a heat map
  • Added dedicated shaders for Deadlock's pbr.vfx, environment_blend.vfx and citadel_overlay.vfx materials
  • Added wet weather rendering for CS2 environment materials
  • Added subsurface scattering, with per-vertex or computed curvature and per-channel normal softness
  • Added a second specular lobe for materials that author one
  • Added a second sun shadow cascade for sharper shadows near the camera
  • Added adaptive shadow map resolution for dynamic lights
  • Added the legacy light_omni, light_spot and light_ortho entities used by Half-Life: Alyx and SteamVR Home
  • Added real time light_rect area lights
  • Added local post processing volumes, crossfading over an entity's fadetime
  • Added rendering of path_particle_rope cables
  • Added rendering of the effects a model references in its particles_list
  • Added the env_particle_glow entity and particle sound events through C_OP_RenderSound
  • Added a dedicated first-person viewmodel pass, fixing the CS2 weapon clipping into geometry
  • Added a Debug Physics Traces checkbox drawing hulls, swept boxes and contact points
  • Added an opaque refraction pass, so refractive glass draws after the framebuffer grab
  • Added root motion for animation graph clips (vnmclip)
  • Added a Template Entities layer grouping point_template children with their template
  • Added engine-matching wildcard targetname lookups
  • Reworked the particle sprite and trail shaders around the spritecard's compositing model:
    • All fifteen SpriteCardTextureChannel_t channel masks and all seven blend modes in the sprite shader
    • Up to five texture layers, each with its own sprite sheet, plus gradient layers
    • Outlines, HSV shifting, desaturation, fog, and distance and edge-on fades
  • Improved particle trails to stretch along the direction of motion, taper from head to tail, and batch into one draw call
  • Implemented the particle endcap phase, with its eight operators and replaying endcap children
  • Implemented child particle systems honouring start delay, endcap-only and detail tier flags
  • Implemented 29 more particle initializers and operators, covering sequential paths, noise, culling, distance constraints and control point remapping
  • Implemented curved particle paths with the authored midpoint bulge
  • Implemented the F_USE_NEW_BLENDING height band blend for CS2 csgo_environment_blend materials
  • Implemented the normal morph bundle, so lighting on morphed faces follows the deformation
  • Improved nine particle functions to read fields they were ignoring
  • Improved specular shading with a multi-scattering environment BRDF
  • Rewrote walk mode player movement to be framerate independent:
    • Multi-plane collision clipping, stair steps, jump stamina and stuck recovery
    • Surfing and strafe jumping, switched on for bhop, surf, kz and dr maps
    • Brush entity collision, and walking on a model's own physics in the model viewer
    • Esc releases the mouse, and a second press leaves walk mode
  • Changed particle simulation to the engine's timing, instead of banking time and advancing at most one 1/120s step per frame
  • Changed particle randomness to the engine's seeded shared table
  • Changed the particle starting radius to the engine default of 5, from 1
  • Changed the renderer to bind vertex attributes to fixed canonical slots
  • Changed GPU culling to default off on Intel integrated graphics
  • Changed camera dragging to hide and pin the cursor instead of wrapping it at the viewport edges
  • Raised the barn light budget from 128 to 320
  • Removed the legacy CPU occlusion culling path in favour of the GPU depth pyramid
  • Fixed maps rendering far darker than in game
  • Fixed the pre-simulation fast-forward not re-running on restart, so a settled effect comes back relaxed
  • Fixed particle functions reading the wrong schema keys or ignoring authored fields
  • Fixed particle bounding boxes culling effects early or keeping them alive off screen
  • Fixed particles spawned in a sphere bunching toward its centre
  • Fixed untextured particle renderers drawing the error checkerboard
  • Fixed material textures landing on the wrong shader input
  • Fixed samplers left on texture 0 reading an incomplete texture
  • Fixed Multiply falling through to the additive blend function, and gave ModThenAdd its own
  • Fixed NaN pixels from pow(0, 0) in fog, vignette and levels adjustment
  • Fixed the MSAA resolve turning NaN samples into white that blew out bloom
  • Fixed directional lightmaps not normalizing their decoded light direction, and softened it on flat surfaces
  • Fixed cloth materials losing energy in both the direct and indirect lobes
  • Fixed lights pointing at the mirror image of their pitch
  • Fixed a vertical light_environment producing NaN sun shadow matrices
  • Fixed env_sky ignoring its brightnessscale
  • Fixed washed out RGBM light probes and cubemaps in SteamVR Home
  • Fixed unbound bone transforms making models render wrong on Intel drivers
  • Fixed aggregate fragments drawn with another fragment's transform
  • Fixed out-of-range tints such as a renderamt above 255 wrapping around
  • Fixed shadow, atlas and histogram buffers leaking when a tab was closed
  • Fixed animation graph clips (vnmclip) playing back too fast
  • Fixed procedural cloth bones staying at bind pose in the skeleton overlay
  • Fixed flex values and root motion leaking into the next animation
  • Fixed invisible playerclip hulls blocking ray traces
  • Fixed loading an asset with no physics parts crashing
  • Fixed the model viewer crashing when toggling mesh groups

CLI

  • Added a --game argument pointing at a gameinfo.gi file, so assets outside the game folder resolve
  • Improved the glTF animation filter to match by leaf name and report entries that matched nothing
  • Changed --output to write to the exact filename given for a single --vpk_filepath match
  • Fixed textures decompiled from a VPK not writing their image files
  • Fixed glTF exports from nested VPKs colliding at the output root
  • Fixed --stats on VPKs skipping .vcs, .nav, .vfe, .vfont and .uifont entries
  • Fixed --vpk_list silently extracting when combined with --output, which is now an error

Library

  • Added root motion to glTF animation exports, so a walk cycle travels instead of running in place
  • Added more of a model to glTF and DMX exports:
    • Morph target weight animation, so facial and flex animation plays
    • Additive animations as delta tracks, or composed with --gltf_compose_additive
    • The clips a model's animation graphs reference, plus secondary skeletons
    • Material groups (skins), local hierarchy overrides, and vnmclip float curves
  • Added writing of binary KV3 version 5, with LZ4 and Zstandard compression
  • Added a public entity simulation API in ValveResourceFormat.Renderer.Entities
  • Added typed entity I/O with EntityLump.Connection and EntityIOTargetResolver
  • Added untriangulated Hammer meshes to decompiled maps
  • Added animation graph clips to the animation API: AnimationGraphLoader, AnimGraphModelInfo and SkeletonRetargeter
  • Added typed vdata parsing in the new ValveResourceFormat.ResourceTypes.GenericData namespace
  • Added nav mesh data previously skipped as unknown bytes
  • Added a particle API for building systems without a resource, including PathParticleRope
  • Added eight members to ParticleField and the ParticleDetailLevel enum
  • Added ModelLodInfo describing a model's LOD levels and switch distances
  • Added the navmeshcustomdata1, modeldoc41 and vpcf66 KV3 format ids
  • Added the MSLT meshlet block, Texture.RadianceCoefficients and the remaining texture metadata
  • Added ShaderRegistry for mounting your own shader directories
  • Added support for version 71 compiled shaders
  • Implemented writing Panorama blocks back out
  • Improved NTRO parsing, printing enum fields as their enumerator name instead of a raw number
  • Improved decompiled animation graph layout to match the graph viewers
  • Improved tools asset info parsing
  • Improved decompiled shader output:
    • Dynamic expressions resolve more variable hashes to their real names
    • Eight more parameter UI types are named
  • Changed glTF export to bake the Source-to-glTF conversion into rest poses, vertices and keyframes instead of a root node
  • Changed map decompilation to fold duplicate point_template children into a single entity
  • Fixed decompiled angles collapsing when an object points straight up or down
  • Fixed misaligned lightmaps in glTF map exports
  • Fixed baked per-vertex lighting written into the glTF vertex colour attribute
  • Fixed the light_environment sun pointing the wrong way in glTF exports
  • Fixed extracted vnmclip clips coming out rotated
  • Fixed exported DMX files being rejected by Blender Source Tools
  • Fixed animations of different models overwriting each other on export
  • Fixed procedural cloth bones duplicated on model round-trips
  • Fixed models with more than 32 mesh groups
  • Fixed Hammer meshes ignoring their scene object transform
  • Fixed signed Integer64 entity properties printing as huge positive numbers
  • Fixed local addons not resolving their loose files or the other addons they depend on
  • Fixed a crash extracting an HDR cubemap that has no material unpack info
  • Fixed sprite sheet rectangles losing their last row and column
  • Fixed sounds carrying emphasis data losing all of their lip-sync phonemes
  • Fixed the clamp(x, 0, 1) to saturate(x) rewrite almost never firing in decompiled shader source
  • Fixed compiled shader texture channel mappings and dynamic combo ids
  • Public API moved around a lot this release:
    • Animation split into SequenceAnimation and ClipAnimation, with playback through one AnimationPlayer per skeleton
    • Camera speaks Source QAngles, and its pitch now measures positive downwards
    • ValveResourceFormat.Utils.GraphLayout was removed outright, with no public replacement
    • The EntityTransformHelper methods were renamed after what they return
    • Renderer.EnableBarnLights replaces the ViewConstants.ExperimentalLightsEnabled field
    • Formats use the engine's ImageFormat enum, removing Framebuffer.Stencil and the attachment format records
    • Vertex buffers share a VertexInputLayout API, removing DrawCall.VertexArrayObject
    • RenderMaterial owns MaterialInputs<T>, removing DepthOnlyProgram and collapsing Shader.SetUniform1-4
    • The legacy CPU occlusion and shadow binning APIs were removed, and IFileLoader now requires GetFileStream
    • A long tail of renames across textures, nav meshes, panorama, shaders and tools asset info

View commits since 19.2

v19.2

CS2 First-Person Viewmodel

Available on CS2 maps, walk mode now renders the CS2 first-person viewmodel alongside first-person legs, with weapon and leg animations driven by a new animation mixer. Includes multi-dimensional blend spaces, additive breathing, bone masks, muzzle flash, and perspective correction.

image

AnimGraph 2 Decompilation

Added decompilation of AnimGraph 2 (NmGraph) files back to editable source documents, covering node specifications, type definitions, variations, and virtual parameter types. Round-trip fidelity is preserved across global transitions and animgraph variation overrides.

GUI

  • Added skybox material rendering to thumbnails, and rotated cubemap thumbnails upright
  • Fixed application hang when creating a screenshot with Ctrl+C
  • Fixed crash when double-clicking an output target without a targetname

Renderer

  • Added a CS2 first-person viewmodel and first-person legs in walk mode, with a new animation mixer, IK, and tilt-twist constraint solver
  • Improved particle simulation timing with min/max simulation time and by carrying excess frame time over to the next tick
  • Improved walk mode movement to run at a fixed 64Hz, buffer jump input, and refine step-move collision precision
  • Improved physics collision traces to consistently resolve corner-triangle and axis-aligned edge-edge cases
  • Separated vr_unlit into its own shader, mainly for SteamVR Home
  • Normalized envmap visualization brightness in vr_standard
  • Enabled the "No layer" world layer by default
  • Fixed fog in SteamVR Home and Robot Repair
  • Fixed F_TRANSMISSIVE_BACKFACE_NDOTL for three-layer parallax materials
  • Fixed value wrapping in particle remap and curve-fitting operators
  • Fixed screenshot transparency in the MSAA resolve pass
  • Fixed texture debug display
  • Fixed several particle operator typos

Library

  • Added AnimGraph 2 (NmGraph) decompilation
  • Added secondary skeleton linking and improved sync tracks in exported .vnmclip files
  • Added DMX skeleton writing
  • Added LODGroupList export to the vmdl decompiler
  • Added bindless texture and sampler output to ShaderExtract
  • Improved SPIR-V shader reflection: matched samplers to well-known names, mapped render state values to enum names, added the RsComparison, RsFilter, and RsTextureAddressMode enums, and fixed binding offsets for older shaders (Half-Life: Alyx)
  • Improved VfxRegisterType enum coverage with renamed and added members
  • Added a missing visibility region bit field to VoxelVisibility
  • Added Name to Skeleton
  • Fixed compute shader buffers being overwritten by globals when decompiling SPIR-V shaders
  • Fixed skybox YCoCg texture colors when exporting and previewing
  • Fixed UV calculation when exporting cubemaps to an equirectangular (lat-long) image
  • Fixed nmclip decompile coordinate system, nmskel root_motion axis, and nmclip glTF export to include the armature
  • Fixed missing last set of joints in glTF exports
  • Fixed glTF mesh list filtering
  • Fixed default bone weights for meshes with 8 bones
  • Fixed modeldoc PhysicsHullFile missing the parent_bone property
  • Fixed unsanitized modeldoc node names in generic game data
  • Fixed modeldoc body group choice names
  • Fixed crash parsing materials that omit dynamic param arrays
  • Fixed VfxEval float formatting on non-English locales
  • Fixed invariant culture handling in more places

View commits since 19.1

v19.1

Thumbnail Grid View

The file explorer now supports a thumbnail grid view with live-rendered previews of models, materials, and textures. Toggle between list and grid layouts, and resize thumbnails with Ctrl+Mouse wheel or the slider. Thumbnails are rendered on a background thread using the full OpenGL pipeline.

Thumbnail Grid

Barn and Omni Light Support

Added rendering of barn (cone-shaped) and omni2 (point) lights. Barn lights support perspective and orthographic projection, cookie textures, soft edge falloff, and dynamic shadows.

Before After
No barn lights With barn lights

GPU-Driven Culling

Scene rendering now uses a GPU-driven culling pipeline. A compute shader tests every meshlet AABB against the camera frustum, a hierarchical depth pyramid
(occlusion culling), and a screen-size threshold. This reduces draw overhead in large scenes. Meshlet level culling is available on most Source 2 maps built 2023 and forward.

S2VMeshletCulling

World visiblity (vvis)

Added support for parsing .vvis files and visualizing the clusters.

World visibility debug

AnimGraph 2 Clip Playback

AG2 animation clips can now be played back directly in the model viewer. Clips are loaded from referenced .vnmclip files, organized by folder name alongside AG1 animations.

Improved AG1 Decompilation

Decompilation of AnimGraph 1 state machines now covers 35+ node types. State machine condition scripts, virtual parameters, and proper node connection mapping are also supported.

GUI

  • When opening another file from disk, it will open in an exiting S2V instance (@Poggicek) (#1121)
  • Added thumbnail previews to package explorer (@Angel-foxxo) (#1110)
  • Added Ctrl+Mouse wheel to change grid size, persisted across sessions
  • Added SVG save button, saves at current zoom level
  • Added bitmap save button for image resources
  • Added controls grouping in renderer sidebar (Render, Model, Camera, Debug sections)
  • Added detailed per-pass render timing viewer option
  • Added searching for tools asset info data in package viewer
  • Added syntax highlighting for TypeScript files, XML highlighting for vsvg (@Poggicek) (#1125)
  • Added mouse sensitivity option that matches source engine behavior
  • Added particle operator list display in the particle viewer
  • Added meshlet, skinning, and VBIB VRAM stats to model viewer
  • Added Discord link to the About window
  • Improved syntax highlighting KeyValues based on actual tokens instead of regexes
  • Improved UV tiling toggle smoothness in the texture viewer
  • Enabled automatic update checks by default
  • Changed model viewer to show tools materials by default
  • Changed shadow resolution option to a shadow quality option
  • Changed to apply VSync and FOV settings immediately when switching to GL tab
  • Changed to allow orbiting in walk mode
  • Changed to start scanning game directories in parallel before main window loads
  • Changed file explorer to persist across tab switches instead of being recreated
  • Changed input handling to accumulate keys so they are not lost at low frame rates
  • Fixed shadow setting not being saved
  • Fixed preview resource being disposed too early
  • Fixed UI and event memory leaks
  • Fixed animgraph viewer crashes
  • Fixed texture viewer stealing focus and not respecting max texture size
  • Fixed image viewer crash when opening Gray8 PNG files
  • Fixed image viewer alpha premultiplication by forcing the alpha codec to unpremultiplied
  • Known issues:
    • Application hangs when capturing screenshot with Ctrl+C. (Fixed in dev build)

Renderer

  • Added GPU-driven frustum, occlusion, and size culling via compute shaders with multidraw indirect (@H7perus, @kristiker) (#1089)
  • Added barn (cone) and omni2 (point) light rendering with shadow atlas (@dr3fty) (#1104)
  • Added compute shader MSAA and depth resolve (replacing blit operations)
  • Skipped outline rendering overhead when nothing is selected
  • Added "Tool Entities" world layer for triggers, nav meshes, etc.
  • Added world layer for entities disabled by default (e.g. CS2 Wingman spawns)
  • Added support for particle snapshots
  • Added particle light rendering using omni2 lights
  • Added more particle operators and initializers, with child systems inheriting control points from parent
  • Added RGBM6 texture decoding to the GPU decoder and texture viewer
  • Added rendering of backfaces into shadow maps
  • Added world visibility cluster visualization
  • Separated vr_standard into its own shader, distinct from complex
  • Implemented csgo_simple_3layer_parallax shader with parallax-mapped triple layer blending
  • Standardized diffuse lobe formula to match Counter-Strike 2 (pure Lambert)
  • Improved fog entity to only copy rotation from env_sky
  • Improved rendering of SteamVR maps (foliage, cubemaps, sun shadows in v1 lightmaps)
  • Improved particle model preview
  • Changed world loader methods to public for granular loading control
  • Fixed IBL color space when LDR based compression is used.
  • Added ability for materials to customize texture address mode (UV Wrap, Repeat)
  • Fixed alpha test to properly utilize alpha-to-coverage
  • Fixed YCoCg skybox rendering
  • Fixed csgo_environment blend color correction and detail overlay
  • Fixed csgo_environment metalness default value
  • Fixed set by feature not handling (not) equal constraint types in VFX evaluation
  • Fixed missing scene object skins
  • Fixed crash when crouching with no physics present
  • Fixed AG2 additive animations not displaying anything
  • Fixed swapped axis in text renderer

CLI

  • Added nav mesh file export to glTF
  • Removed [archive index] log line when dumping

Library

BREAKING: KV3TextSerializer, KeyValues3, KVObject, KVValue have been removed from this library.
KV3 parsing is now powered by ValveKeyValue.

BREAKING: Entity now extends KVObject from ValveKeyValue, and Entity.GetPropertyUnchecked has been removed.

  • Improved AnimGraph 1 node decompilations (@dirtkiller23) (#1060)
  • Added AnimGraph 2 clip playback on models (@kristiker) (#1106)
  • Added world visibility (vvis) support (@dr3fty) (#1132)
  • Added full equirectangular projection for decompiled cubemap textures
  • Added export of NmSkeletonRefs, Animgraph2Refs, and CitadelEventIDToBodyGroupMapping_t (@dirtkiller23) (#1116)
  • Added vpcf65 to KV3 ID lookup (@Artemon121) (#1082)
  • Added enabled combo comment to SPIR-V reflection output
  • Added shader source files to parsed VFX data
  • Added new ObjectTypeFlags values
  • Added new AnimGraph node fields (@dirtkiller23) (#1090, #1130)
  • Added default value parameter to KVObject property getters
  • Named all VfxEval opcodes
  • Changed Texture.Reflectivity from float[] to Vector4
  • Changed LineSceneNode to public
  • Changed MurmurHash2.Hash to be case-insensitive, with HashCaseSensitive added for the previous behavior
  • Added MurmurHash2.Hash version that accepts a single uint
  • Added normal and additive blending methods to FrameBone (CTransform in Source2)
  • Improved shader combo constraint solver
  • Fixed UV mapping on decals in glTF exports (@ifpCD) (#1105)
  • Fixed GetUnsignedIntegerProperty on negative integers (e.g. SteamVR Home m_nDefaultMeshGroupMask)

View commits since 18.0

v18.0

Renderer Project Split

The rendering engine has been extracted into a separate Renderer project, now published as a standalone NuGet package. This enables external applications to leverage all of our Source 2 rendering capabilities. See Misc/RenderTest for an example project.

Bloom and Depth of Field Post-Processing

Implemented bloom and depth of field post-processing effects.

Bloom (New) No Bloom
bloom1 bloom2
Depth of Field Depth of Field
dof1 dof2

Irradiance Color Debug Mode

Compiled maps include a colored representation of the light map, and now it can be viewed directly using the IrradianceDebug render mode.

First-Person Walk Mode

We have added a basic experimental first-person movement controls with world geometry collision support. It is roughly based on Counter-Strike movement, but is not exactly the same.
If you are a movement enjoyer, help us polish and improve this new system.

GUI

  • Enabled single file compression which results in smaller executable size
  • Added experimental first-person walk mode with collision detection
  • Added keybindings display to bottom bar
  • Added icons to entity list
  • Added faceposer_folders support for animation list
  • Added entity info window position memory
  • Added parent folder name to root VPK node names
  • Added ability to export the raw spirv binary from shader treeview
  • Added ability to open spirv binary files, viewed as cross compiled HLSL
  • Improved model viewer to enable orbiting around the model
  • Material viewer property sliders use shader defined range
  • Improved asset info view display
  • Improved window position restoration using SetWindowPlacement
  • Changed external references to tree view display
  • Fixed texture viewer not re-rendering on tab visibility changes
  • Fixed camera interpolation incorrectly going in a circle
  • Fixed Ctrl+plus/minus zoom shortcuts
  • Fixed frame time jump when unpausing
  • Fixed aliased file type icons missing in release builds
  • Fixed app logo blurriness
  • Running in Wine will now use default WM_NCCALCSIZE

Renderer

  • Now a standalone library published on NuGet
  • Added bloom post-processing effect
  • Added depth of field post-processing effect
  • Added auto exposure support
  • Added compute shader support
  • Added irradiance debug mode
  • Improved visual quality for outline and infinite grid
  • Enabled cubemap normalization using a simple formula
  • Scenes without lightmaps will now sample diffuse from IBL
  • Fixed dynamic shadow jitters when moving
  • Improved parallel loading of resources in map viewer for faster load times
  • Changed shader file extension to .slang (.frag.slang, .vert.slang)
  • Fixed some particle operators

CLI

  • Added --gltf_mesh_list parameter to filter out unwanted meshes during export
  • Improved shader extraction to show DXBC shader hash

Library

  • Added support for newer NavMeshFile versions
  • Added OnDiskBufferData.TotalSizeInBytes property
  • Added tools asset info v15 support
  • Added vpcf64 to KV3IDLookup
  • Corrected all VfxEval function names
  • Improved .vmdl animation decompilation:
    • Pose parameters
    • Animation sequences with bind pose extraction
    • Auto-layer nodes
    • Blend layer parameters and nodes
    • Cycle override nodes
    • Secondary animgraph2 animations now export to glTF
  • Improved vmap export to stringify all KV objects
  • Improved vmap folder export filter
  • Fixed nmclip subfile paths
  • Fixed vsnd not being exported to correct folder
  • Fixed crash when decompiling geometry shaders with missing dynamic combos
  • Fixed autolayer flag reading

View commits since 17.0

Older releases on GitHub

Made possible by amazing people

Source 2 Viewer is open-source and built by volunteers. Every contribution helps make it better for everyone.

xPawkristikerw1tcherrrPerryvwkrotter0Angel-foxxoMarlaminPurrspctivSinZ163lewa-jrobert-hoffPoggicekdr3ftymoofMonkeymovexigdirtkiller23BogdanuqmdillernecukLionDogeH7perusyaakov-hAveYoin0finitevermadasArenovasmircokroonKashimuraBakaAnsimistMattFileriwasinminedreamNeoExperiencesdanggui1995TianQiBuTiantimkurversThomasK33r2d2rigoihatecsvDatGuy1Artemon121aoisensiKampfkarrenzndxcvbnifpCDitrisalong0900snowyukittytgrgdsttrebuchonuser8738423YuRaNnNzZZSamboyCodingSTL1tepjoeIOExceptionalgarrynewmanEgezennogniK5377aquaismissingLonswaya