Source 2 Viewer is a powerful tool that allows you to browse VPK archives, view, export, and decompile Source 2 assets, including maps, models, materials, textures, sounds, and more.

This open-source project is based entirely on a reverse engineered effort as there is no Source 2 SDK.

All Source 2 projects are supported including Counter-Strike 2, Dota 2, Deadlock, Half-Life: Alyx, SteamVR, and more…

Download Source 2 Viewer
Requirements: Windows 11, OpenGL 4.6
Having issues? Download dev build
Inferno Night by Angel, created by decompiling with Source 2 Viewer.
stars

Command line utility

A cross-platform console application that can export and decompile Source 2 resources similar to the main application.

Download CLI for your OS from GitHub

ValveResourceFormat

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

Get ValveResourceFormat from NuGet | View on GitHub

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.

Get ValvePak from NuGet | View on GitHub

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.

Get ValveKeyValue from NuGet | View on GitHub
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);
View API documentation
View and export files in VPK packages
Preview maps and models in 3D space
View and export textures along with other resources
Use the command line utility

Features

3D Renderer

  • Interactive viewer for Maps, Models, Physics, and Particles
  • Reverse-engineered PBR shaders with real-time lighting
  • Animation playback controls
  • Entity viewer with property inspection
  • WASD camera controls with customizable FOV
  • Debug visualizations and performance monitoring
  • Hardware-accelerated OpenGL rendering

Texture Viewer

  • View Textures and SVGs with isolated channel viewing
  • Color channels, depth layers, and mips support
  • GPU or CPU decoding options
  • Cubemap and HDR texture support
  • Normal map visualization modes
  • Rasterize SVG to image
  • Export exactly what is displayed
  • Zoom and pan controls

VPK Package Files

  • Browse, extract, and manage Valve Package (vpk) archives with full version support
  • Tree view and list view interfaces with file type icons
  • Advanced search system (name, path, regex, content, hex)
  • Sort files by size and other criteria
  • Extract individual files or entire packages
  • Multi-threaded extraction with progress tracking
  • Discover and recover deleted files from VPK archives
  • Create new archives from folders with one click
  • Support all vpk versions (including Source 1)

Export Systems

  • Export Maps, Models, Physics, and Animations to glTF 2.0
  • Convert Source 2 material channels to glTF channels
  • Compatible with Blender and other glTF-supporting software
  • Materials export with correctly split textures
  • Batch export functionality for multiple files
  • Resource dependency tracking and validation

Content Decompilers

  • Maps (vmap_c → vmap) for use in Hammer editor
  • Models (vmdl_c → vmdl) to ModelDoc format
  • Materials (vmat_c → vmat)
  • Produce editable assets for Source 2 Workshop Tools
  • Retain maximum data fidelity

Source 2 Resource Files

  • Read and process Source 2 resource files (_c file extension) with comprehensive support
  • View Resource Blocks in separate tabs
  • Decode data to user-friendly text representation
  • Support for all resource file versions (as early as 2014)

Audio System

  • Built-in audio player with waveform visualization
  • Support for WAV, MP3, and Source 2 audio formats
  • Volume controls and stereo meters
  • Timeline scrubbing and playback controls
  • Auto-play in preview mode

Shader Packages

  • Inspect and analyze Source 2 shader files (vcs extension) with bytecode conversion
  • Read Source 2 shader packages
  • Compiled shader code viewer
  • Inspect shader metadata and bytecode
  • Tree view for static and dynamic combos
  • Convert Vulkan bytecode (SPIRV) to readable shading language
  • Support all publicly available file versions

User Interface

  • Modern, intuitive interface designed for efficient file management and content exploration
  • Tabbed document interface with advanced tab management
  • Dark and light theme support
  • Steam games auto-detection and explorer
  • Recent files and bookmarks management
  • Drag and drop file support
  • Keyboard shortcuts for quick navigation
  • Windows integration with file associations

Additional File Formats

  • NavigationMesh (.nav) and ToolsAssetInfo (.bin) files
  • World nodes (vwnod_c) for streaming world geometry
  • Compiled particle systems (vpcf_c) and effects
  • Sound event files and audio definitions
  • Various image formats (PNG, JPG, TGA, GIF)
  • Hex viewer for binary data inspection
  • Text and binary file viewing with syntax highlighting
  • Complete KeyValues support (KV1, KV2, KV3)
  • Convert binary keyvalues to text format
  • Closed captions file support

Release Notes

Trending workshop items. If you want to appear here, add a link to Source 2 Viewer in the item description: https://valveresourceformat.github.io