Releases: ValveResourceFormat/ValveResourceFormat
10.0
Improved vmap decompiler
The vmap decompiler now exports various types of geometry and entities, including toolbrushes and world geometry, as editable hammer meshes,
while also maintaining correct physics surface properties with procedural textures and correct tints.
Added path input to package viewer
Similar to regedit, the package viewer now features an address field that updates when
you select a file or folder in the file tree. Additionally, you can type or
paste a path into this field, and it will attempt to select the closest existing file.
Faster render mode switching
Render modes no longer recompile shaders, and switch instantly as a result.
Different modes have also been organized into logical groups.
GUI
- Added path input to package viewer
- Added partial support for baked light maps
- Added bone names when using show skeleton checkbox
- Filtering in explorer now remembers the collapsed state of game nodes
- Draw 2D skybox before 3D skybox translucents
- Fixed old Dota 2 map versions missing from the explorer
- Fixed incorrect shadows in model viewer
- Fixed a crash when
influenceradius
is a string in map loader - Fixed a crash when cancelling package verification
- Fixed save button in texture viewer not actually working
- Fixed quick previews not being disabled when only play audio is checked
- Fixed animated node bounding box becoming extremely large
- Only verify file checksums if archive has no MD5 hashes during package verification
- Render modes are now switched using a shader uniform
- Multiple shader and rendering improvements
CLI
- Dump to folder when output exists as a folder and we're trying to write a file
Library
- Added support for new blocks:
FLCI
andDSTF
- Added support for choreo files version 19
- Improved support for certain vcs file versions
- vmap decompiler improvements:
- vmap decompiler will now export geometry generated from hammer meshes as hammer meshes
- Added support for exporting toolbrushes to hammer meshes
- Added support for exporting mesh entities to hammer meshes
- Added support for exporting world geometry to hammer meshes
- vmap physics mesh is now also exported as a hammer mesh, to make it easily editable
- Added physVertexMatcher to separate hammer geometry out of the physics mesh
- Added procedural physics tool textures so that the exported physics mesh maintains correct physics surface properties
- Added correct tints to exported hammer meshes
- Fixed exporting vertex streams on worldnode models and hammer meshes
- Added automatically generated selection sets that group the different parts of the decompiled vmap
- glTF export improvements:
- Split aggregate meshes into individual mesh fragments
- Allow exporting entity lump (vents) file
- Clamp color and metallic factor
- Fixed unnecessary allocation in ETC2 decoders
- Fixed panorama files to only check CRC if data is not empty
9.2
Optimized package viewer
The file tree is now created lazily, which vastly improves performance and memory usage on large VPKs.
For example, the Dota 2 pak01_dir.vpk contains 325k files (which also create 40k folders).
This VPK now opens 8 times faster, and consumes 3 times less memory.
This also makes closing the tab much faster as it no longer needs dispose every single tree node.
9.1 (Old) | 9.2 (New) |
---|---|
2.43 seconds | 0.29 seconds |
241mb memory (GC) | 74mb memory (GC) |
650mb memory (process) | 193mb memory (process) |
File previews
There is now a setting to preview files right from the package viewer,
including an option to autoplay sounds.
Selecting a file in the tree view will automatically load it in the right pane,
and selecting a folder will show the folder contents as it did before.
This may be slow for certain big files like models with many animations.
Preview-on-click feature can be enabled in settings.
GUI
- Added file previews
- Added an option to automatically open explorer on app start (if no arguments were provided)
- Package viewer tree list is now constructed lazily
- Enabled explorer theme in package viewer and disabled lines (this replaced the plus/minus buttons with arrows)
- Expanding a folder that contains a single folder will now automatically expand that folder for you
- Fixed a couple of issues which prevented Explorer from opening when Steam is not installed or libraries are missing
- Fixed enviroment blending on certain community maps
- Fixed some default values being omitted in shader extract
CLI
- Added option
--gltf_export_extras
to export entity keyvalues as mesh.extras
Library
- Added support for new sound file format (Dota 2)
- Added
DotaVisualNovels
resource type - Fixed support for reading hitboxes in older models
- Added
GltfModelExporter.ExportExtras
9.1
Highlights
Added a .vpk extension icon in Windows Explorer
Icon designed by Gabe Follower
If you have registered file association before, you have to register it again in settings to get the icon.
Added support for animating character eyes in CS2 models 馃憖
GUI
- Renamed unstable builds to dev builds
- Added .vpk file extension icon for the Windows Explorer
- Added message box when detecting settings downgrade on app start
- Added support for CS2 character eyes (#762)
- Improved map/model viewer sidebar to be resizable and scrollable
- Package viewer will now remember tree sidebar width between packages
- Opening workshop files will now skip
core
mod so that game mod ends up with higher priority - Loading bar will now continue displaying until the file is fully loaded and ready (although the progress bar will be frozen)
- Added I8 support for the texture viewer
- Added particle force generators
- Fixed mod2x blending in particles
- Fixed multiple issues with blending overlays and decals
- Fixed multiple issues in particle operators
- Fixed
skybox_reference
transform in map viewer - Fixed hardware texture decoder thread initialization
- Fixed null references in map loader
- Fixed an exception on app start when search path settings contain non existing files
- Fixed different sky texture format in CS2
- Fixed cubemap and light probe flicker on certain maps
- Map viewer: Always put aggregate meshes into opaque drawcalls
- Rendering improvements
Library
- Updated nuget package icon
- Added
FlexSceneFile
to read and export.vfe
files - Added DotaPatchnotes resource type
- Added exporting vmdl body groups
- Remove
[PR#]
prefix from entity values in vmap export - Improved shader extract texture definition
- Fixed null references in model exports
- Fixed
ContinuousIntegrationBuild
not being set for deterministic builds - Fixed shader extraction in s&box
- glTF exporter will now create 1x1 images for missing textures
9.0
Highlights
Added support for dynamic shadows and light probes
Source2Viewer_YH3YWvtVBY.webm
Improved rendering of clip brushes and physics groups
Added support for exporting and rendering hitboxes
As you can also notice, we also have a better lighting setup and background (dark/light) in the model viewer. You can move light by holding Ctrl and left mouse button.
Capture transparent screenshots from model viewer
When you press Ctrl+C, it will copy a transparent PNG to the clipboard.
GUI
- Added support for rendering model hitboxes
- Added support for picking objects in the 3d skybox
- Added support for
idleanim
in animated entities - Added support for SteamVR workshop addon dependencies
- Added support for light probes in map viewer
- Added dynamic shadows
- Added fancier background for model/single-node viewer
- Allows switching to light background
- Removed setting to change background color
- Added a few new asset type icons
- Model viewer now has a static light angle which can be moved with mouse while holding Ctrl and left mouse button
- Opening entity info dialog no longer blocks the main window, switches to other entities upon click
- Improved rendering of physics groups (clips)
- Fixed multiple cameras in map viewer when they have same name
- Fixed VBIB hash collisions
- Fixed drawing occluder meshes in map viewer
- Fixed double click opening files in inner map vpks
- Fixed rendering mod2x overlays
- Fixed not drawing tools materials in material viewer
CLI
- Fixed "Enumeration already finished"
Library
Serialization.NTRO
has been removed, instead all NTRO files are upconverted to KV3- Added vcdlist reading and decompilation (
ChoreoExtract
) - Added
IFileLoader.LoadFileCompiled
- Added more data to vmdl exports
- Fixed a few issues with exporting maps from older games
- Fixed shader files incorrectly disposing stream in some cases
- Fixed broken animations when exporting vmdl
- Fixed Angle Shear Vector for light_barn entity in vmap
8.1
GUI
- Added outline to FPS counter
- Switched OpenGL buffer APIs to more modern direct state access APIs
- Double-clicking particle entity in map viewer will now open the particle itself
- Enabled logging of high severity OpenGL debug messages
- Fixed double-click to expand folders in package tree view opening files incorrectly
- Fixed creating animation texture for models with no bones
- Fixed a couple of rendering bugs on specific graphics drivers
- Fixed compatibility with some old files
Library
- Added
GetArray
support forNTROValue<NTROStruct>
8.0
Highlights
Model viewer now supports morphs
morph.mp4
Texture viewer has been rewritten
It is now more powerful and faster.
textures.mp4
GUI
- New texture viewer with more features
- Hardware accelerated decoding and rendering
- Smoother mooving and scaling experience
- Support SVG files
- Switch channels, opaque, transparent, or opaque with split alpha, mip levels, depth, cubemap faces
- Cubemaps allow switching between individual face, cube projection, and equirectangular projections
- Save (Ctrl-S) or copy (Ctrl-C) to save currently visible texture
- Textures are now decoded with GPU for faster exporting and more correctness
- Creating new vpk now uses rudimentary editing ui where you can add or remove files before saving
- Added morph composite rendering
- Added Ctrl-C keybind for any model/map viewer which copies current viewport to clipboard
- Added confirmation dialog when trying to open over 5 files in the default app
- Improved physics/clip brush rendering
- Fixed cubemap fog rendering on maps like de_inferno
- Partially fixed Half-Life: Alyx character animations to play correctly
- Multiple improvements and fixes to our shaders
- Renderer now uses separate framebuffer for more precise depth buffer
- Renderer now uses reverse-Z and infinite far plane
- Replaced our default HDRi cubemap in the model viewer
- Converted all textures to immutable storage
- 3D skybox is now prescaled to simplify some things and avoid jittering on some maps like de_mirage
- FPS counter is now rendered with OpenGL with addition of CPU and GPU times (can be disabled in settings)
CLI
- Added support for dumping closed captions
- Used array pool during vpk dump for less memory use in certain cases
--vpk_verify
now verifies hashes of every archive (or every file checksum if hashes are unavailable)
Library
- Added model morph flex rules
- Reduced png encoder zlib compression to 4 (from default 6) for faster encodes
- Added
ClosedCaptions.ToString
- Added
Texture.RetrieveCodecFromResourceEditInfo
to get specific decoder instructions - Added Dota herolist resource type
- Added skeleton to vmdl export
- Added animation root motion to vmdl export
- Added extracted animations as simple AnimFile nodes to vmdl export
- Added
mipLevel
parameter toTexture.GenerateBitmap
- Removed
GetDecompressedTextureAtMipLevel(mipLevel)
- Map decompiles now include particle snapshots
- Map decompiles now set aggregate props contribute to vis and disable merging
- Split aggregate draw calls in map export for correct tints
- Renamed
VTexExtraData.DATA_METADATA
toMETADATA
- Optimized
RubikonPhysics.Shapes.Mesh.Triangle
to be a XYZ struct - Fixed game file loader not finding main game vpks when opening a file from {game}_addons folder
- Fixed decoding issues with certain RGBA16161616F textures
- Fixed some textures exporting as 1x1
- Fixed jittery animations caused by
CompressedDeltaVector3
andCompressedAnimVector3
decoder - Added
IHardwareTextureDecoder
which is implemented by the GUI - Switched to
System.IO.Hashing.Crc32
- Optimized memory allocations in multiple places, including
BinaryKV3
reading KVObject
now has a debugger display
7.0
Highlights
This release targets .NET 8. This release is mostly bug fixes.
Exporting a folder now has a dialog asking which file types you want to export
VPK viewer now calculates recursive folder size, and allows sorting by column
GUI
- Added a dialog to select which file types to extract
- Added foliage params rendermode
- Added column sorting in the list view in the VPK viewer
- Folders in VPK viewer now calculate full recursive size
- Improved CS2 texture blending
- Embedded brdf lut texture so files outside of game contexts render correctly
- Fixed model and material viewer to load BRDF texture
- Fixed rendering issue with old AMD drivers (from unbound texture)
- Fixed child entities to load from point_template entity for correct position
- Some performance improvements related to the new text editor
- Insert newly opened tabs next to current selected tab
- Lower camera speed in material viewer
- Double clicking a string in entity dialog will now try to open a file if it exists
- Reload active tab with F5 or Ctrl+R
- Added debug ui to change parameters in material viewer
CLI
- Fixed extraction exiting early after exporting one file
Library
- Added animations exporting in vmdl exporter
- Added a default blendweights stream when VBIB has only blendindices in vmdl exporter
- Changed RnHull Vertices to contain indices, move positions to VertexPositions
- Fixed texture parameters with ChannelCount=0 in shader data provider
- Fixed DMX physics meshes from crashing resourcecompiler by adding some blank vertex normals
- Fixed some bugs in shader parser
- Fixed nested VfxEval branches
- Fixed hammer map decompile issues
6.0
Highlights
The GUI application was renamed to Source 2 Viewer, including a new icon by Gabe Follower, and website was redesigned.
Improved frame times
We have optimized away a lot of heap allocations during frame rendering, which practically removes garbage collection.
We have also reduced memory usage by not keeping some things in memory after loading them.
Register VPK file association
It is now possible to make Windows Explorer open vpk files in Source 2 Viewer with a single click of a button.
This also registers vpk:
protocol handler (used by Source 2 workshop tools), so links like vpk:path/to/pak.vpk:file/inside/thing.vmdl_c
will open directly to that file.
As a reminder, you do not have to look for _dir.vpk
file, if you open any numbered archive (like _001.vpk
), it will correctly open _dir.vpk
Create VPK archives from a folder on disk in a single click
Our ValvePak library gained functionality to pack files into a new VPK archive,
and to dogfood (?) this code, we have added this as a feature in Source 2 Viewer.
Added fog rendering
Fog | No fog (old) |
---|---|
New text viewer
We have replaced our basic text viewer with a more advanced one, it has an improved find window (Ctrl+F), and allows folding matching brackets.
Bookmarks in explorer
You can now add files to bookmarks.
GUI
- Removed a lot of heap allocations during frame rendering
- Stabilizes frame times and FPS due to no garbage collection
- Reduced heap memory size up to 2x in some cases
- Multiple improvements to rendering performance
- Added support for rendering gradient and cubemap fog in map viewer
- Added an option to create VPK archives from a folder on disk (in File menu)
- Added a button to register VPK file association and
vpk:
protocol in Windows Explorer - Added a button to validate VPKs by verifying hashes and checksums (right click on the root vpk)
- Added bookmarks in explorer tab (right on a file)
- Added a button to check for updates
- Added a checkbox to view skeleton in model viewer
- Added panning and zooming in texture viewer
- Added entity lines similar in map viewer similar to Hammer (path_track for example)
- Added basic support for rendering smart prop files (vsmart)
- Added setting to toggle vsync (also enabled by default)
- Added button to clear console history in console tab context menu
- Added a checkbox to render wireframes
- Replaced text tabs with a better text box which has line numbers and folds
- Allow exporting vmap_c into glTF (by loading vwrld)
- Moved
settings.txt
to%LocalAppData%/Source2Viewer/settings.vdf
- Moved recover deleted files button to vpk context menu
- Audio player volume will now be remembered in the settings file
- Improved infinity grid axis lines
- Improved rendering overlays in map viewer
- Cursor will now wrap around the viewport while dragging (similar to Blender)
- Fixed shader variants loading twice in map viewer
- Fixed tinted aggregate meshes in map viewer
- Fixed sun color and brightness
- Display workshop addon title in bookmarks and recent files
- Hide bakeresourcecache.vpk files in explorer
- Multiple
vpk:
are now supported when passed in as arguments to the exe - Improved skybox loading
- Enabled
ServerGarbageCollection
CLI
- Improved file loader to be on par with the GUI, exporting maps to glTF will now discover assets from other VPKs and files on disk
- Added
--stats_vbib
to collect vertex attributes - Expanded tools_asset_info file dump, and
--tools_asset_info_short
to only print filenames
Library
- Added
GameFileLoader
which was only previously available in the GUI- Automatically discovers game content on disk by finding gameinfo.gi files
- Rewritten how glTF attributes are exported (custom accessors are now prefixed with underscores as per the spec)
- If you use Blender, this requires an update (see KhronosGroup/glTF-Blender-IO#2000 for more information)
- Implemented exporting multi-depth and cubemap textures into individual files
- Textures will now extract raw PNG and JPEG data without re-encoding them with Skia
- Simplified prettifying panorama stylesheet (vcss) files
- Added
PanoramaDynamicImages.ToString
(vdpi) - Added
STAT
block - Added
DXBC
andSPRV
block support in s&box shaders - Recreate some nodes from embedded
$keyvalues
andrefAnimIncludeModels
in model extract - Changed model extract to use
modeldoc28
format instead ofmodeldoc32
- Fixed
Texture
keeping a reference to resource stream even after it was disposed - Fixed extracting RGBA16161616(F) formats
- Fixed crash with missing friendly shape name in vphys extract
- Fixed decompressing normals
- Fixed normals exporting in orange color
- Fixed RTX shader parsing
- Fixed "missing texture" reflections by removing compiler-filled properties in relfection probes
- Fixed broken vertex buffers in map decompilation
- Fixed missing bones in glTF export if they were never directly used
5.0
Highlights
We have shifted our versioning scheme, so instead of this release being 0.5.0
, it is 5.0
.
Added vmap decompilation
Improved rendering quality
VRF | CS2 |
---|---|
Improved physics rendering (clip brushes and triggers)
Player clips | Bomb plant |
---|---|
GUI
- Model/map viewer improvements
- OpenGL 4.6 is now required
- Many improvements to the rendering quality, including:
- Improved PBR calculations
- Blended cubemaps
- Better lightmaps
- Cloth shading
- Fixed self illuminated materials
- Fixed mipmaps not working on nvidia
- Skyboxes can now be tinted and rotated
- BRDF table lookup
- Vastly increased support for particle operators and many other fixes to the particle system
- Grid in model and particle viewer is now drawn as an infinite pane
- Added speed trackbar in particle viewer to slow down particles
- Pressing F11 will go into fullscreen view
- Double clicking an entity now opens the entity info dialog
- Double right clicking will open a model in a new tab
- Opening vmap_c files will now open the map viewer, same as vwrld_c
- Selecting cubemaps now draws its bounds
- Multiple nodes can be selected while holding ctrl
- Selected nodes now show their rotated bounding box
- View and lighting constants are now uploaded as uniform buffers
- Known entities will now draw as 16x16 cube instead of obsolete sprite
- Anti-aliasing can now be configured in settings
- Added
setpos
andgetpos
buttons- These reflect the commands in Source games,
getpos
in game, clicksetpos
in VRF and vice versa
- These reflect the commands in Source games,
- Explorer improvements
- All vpk files are now found even for non-Source 2 games
- Games are scanned on a separate thread to improve performance (on slow disks)
- Games now display an icon
- Added a button in material viewer to open relevant shader zframe
- Shader bytecode is now decompiled with SPIR-V reflection
- Bug fixes
- Improved shader situation (for VRF developers)
- Implemented shader hot reloading
- Rewritten how shaders are preprocessed
- Shader error dialog now reports affected error line
Library
- Added vmap_c decompilation
- Added vmdl_c decompilation to modeldoc vmdl
- Fully implemented reading
(readonly_)tools_asset_info.bin
files - Added support for plain-text
vjs
andvts
file formats. - Added support for new normals compression format in Counter-Strike 2
- Fixed keyvalues 3 text serialization not escaping keys
- glTF export improvements
- Fixed a crash in glTF material exporting
- Skip +/-inf bone scales
- Improved CS2 weapon model exporting
0.4.0
Highlights
Added file explorer feature
Map viewer now uses baked lightmaps and paralax corrected cubemaps
Added entity information window (double right-click an entity)
GUI
- Added explorer feature
- Automatically discovers Source 2 game VPK archives from your Steam library
- Discovers workshop content for these games
- Keeps track of recently opened files
- Map viewer improvements
- Renderer now uses baked lightmaps and paralax corrected cubemaps
- Overlays are now rendered
- Skybox texture is now rendered (from env_sky)
- Aggregate meshes are now split into individual scene nodes for better culling
- Group physics nodes by collision attribute groups
- Better support for Counter-Strike 2 maps
- Double right-clicking an entity will now popup a window that displays entity data
- Fixed sprites rendering twice
- Texture viewer improvements
- Texture viewer now draws unwrapped cubemaps
- Added view channels context menu
- Added setting to change field of view
- Multiple fixes to particle rendering
- Search paths in settings now accepts gameinfo.gi which automatically finds all the relevant vpk files
- GUI now targets .NET 7
Library
Texture.GenerateBitmap
now accepts specific depth and cubemap face arguments- Added physics shape parsing in
PhysAggregateData
- Added support for keyvalues3 entity lumps
- glTF exporting improvements:
- Materials and textures are now exported asynchronously which speeds up the export
- Materials now load Valve shaders to get correct texture inputs
- Improved ORM texture packing
- Fixed morph data exporting with incorrect vertex offsets