Exporting displacements from Blender

From Valve Developer Community
Jump to: navigation, search
Icon-broom.png
This article or section should be converted to third person to conform to wiki standards.
Left: A displacement mesh in Blender. Right: The exported result in hammer.


Warning.pngWarning:This tutorial, like the addon required to follow it, is now deprecated. Please refer to the [SourceOps' user guide] for a more reliable alternative.

Requirements

Installation

  • Download or save the addon as mesh_disp.py
  • Install the addon through Edit > Preferences > Addons > Install from file, selecting the addon's .py file.
  • Activate the addon.

Setting up and exporting the displacement

An example of how to divide your mesh for displacement export.


To set up the displacement, first denote the borders of your displacements by marking them with Freestyle edges. In the Context menu ('N' by default to open), go to the Source SDK tab, and set up both export path and .vmf filename, then define the collection the displacement mesh is in. After these fields are set up, press Integrate Displacements. A .vmf file with your exported displacements will now be exported to the specified directory.

Export settings example.


Note.pngNote:When creating displacements for export, there's a few things to keep in mind
  • Each displacement may only be power of 2.
  • The plugin uses a 1:32 Blender units to Hammer units scale when exporting. Scaling down your model before exporting is recommended.
  • The UV is also used for exporting the displacement's brushes, so keeping a tidy, and separate UV island for each displacement is recommended.
  • The material used on Blender will also be used in hammer. (Example: If the material is named Dev/dev_measureblend, this will be the texture used on hammer).