Dmxconvert: Difference between revisions
(where is it available) |
(providing an external link to a script I made that automates Dmxconvert for DMX Model files) |
||
(12 intermediate revisions by 4 users not shown) | |||
Line 1: | Line 1: | ||
'''DMXconvert''' is a [[command-line]] SDK tool which converts [[DMX]] files. It can be found in all {{game link|Source 2013}} games, | '''DMXconvert''' is a [[command-line]] SDK tool which converts [[DMX]] files. It can be found in all {{game link|Source 2013}} games, {{game link|Counter-Strike: Global Offensive Authoring Tools}}, {{game link|Left 4 Dead 2 Authoring Tools}}, {{game link|Source Filmmaker}}, as well as in various {{game link|Source 2}} Workshop Tools. | ||
An example usage is: converting regular DMX files using <code>"encoding binary 3 format model 15"</code> into others, such as plain text <code>"encoding keyvalues2 1 format dmx 15"</code>.<br> | An example usage is: converting regular DMX files using <code>"encoding binary 3 format model 15"</code> into others, such as plain text <code>"encoding keyvalues2 1 format dmx 15"</code>.<br> | ||
This new Keyvalues 2 DMX 15 version could then be used in [[Blender Source Tools]] advanced Flex properties tab to copy the face flex rules from. | This new Keyvalues 2 DMX 15 version could then be used in [[Blender Source Tools]] advanced Flex properties tab to copy the face flex rules from. | ||
== Usage == | ==Usage== | ||
dmxconvert -i <in file> [-ie <in encoding hint>] [-o <out file>] [-oe <out encoding>] [-of <out format>] | dmxconvert -i <in file> [-ie <in encoding hint>] [-o <out file>] [-oe <out encoding>] [-of <out format>] | ||
If no output file is specified, dmx to dmx conversion will overwrite the input | If no output file is specified, dmx to dmx conversion will overwrite the input<br> | ||
{{source2}}: -r argument does a recursive search if the in file specifies wildcards<br> | |||
{{source2}}: -upconvert will auto-check out the files. If -i is not specified, it will operate on all DMX files}} | |||
Supported DMX file encodings: | Supported DMX file encodings: | ||
Line 14: | Line 15: | ||
*keyvalues2 | *keyvalues2 | ||
*keyvalues2_flat | *keyvalues2_flat | ||
*keyvalues2_noids {{source2}} | |||
*binary | *binary | ||
*binary_seqids {{source2}} | |||
*actbusy | *actbusy | ||
*commentary | *commentary | ||
*entitylayer | *entitylayer {{not|{{source2}}, {{csgo}}}} | ||
*vmt | *vmt | ||
*vmf | *vmf {{not|{{source2}}}} | ||
*mks {{since|{{csgo}}}} | |||
*tex_source1 {{since|{{csgo}}}} | |||
Supported DMX file formats: | Supported DMX file formats: | ||
*dmx | *dmx | ||
*movieobjects | *movieobjects | ||
*sfm | *sfm | ||
*sfm_settings {{since|{{csgo}}}} | |||
*sfm_session | *sfm_session | ||
*sfm_trackgroup | *sfm_trackgroup | ||
Line 33: | Line 39: | ||
*model | *model | ||
*ved | *ved | ||
*mks {{since|{{csgo}}}} {{not|{{source2}}}} | |||
*vmks {{src}} | |||
*mp_preprocess | *mp_preprocess | ||
*mp_root | *mp_root | ||
Line 43: | Line 51: | ||
*mp_eyes | *mp_eyes | ||
*mp_bonemask | *mp_bonemask | ||
*tex {{since|{{csgo}}}} {{not|{{source2}}}} | |||
*vtex {{source2}} | |||
*world {{since|{{csgo}}}} | |||
*worldnode {{since|{{csgo}}}} | |||
*virtualvolumetexture {{source2}} | |||
*vmap {{source2}} | |||
*vanim {{source2}} | |||
*animflags {{source2}} | |||
== Simple Drag and Drop bat file == | ==Simple Drag and Drop bat file== | ||
As is the case with many Command-Line only tools, usage might be confusing. So here is a simple Drag and Drop .bat file script which automatically converts whatever DMX you drop into the bat into a Keyvalues 2 DMX 15 version, creating a new DMX file with the '''_Keyvalues2''' suffix. | As is the case with many Command-Line only tools, usage might be confusing. So here is a simple Drag and Drop .bat file script which automatically converts whatever DMX you drop into the bat into a Keyvalues 2 DMX 15 version, creating a new DMX file with the '''_Keyvalues2''' suffix. | ||
<source lang=bat>::Game location that has the DMXconvert you want to use. Just main game folder. | <source lang=bat>::Game location that has the DMXconvert you want to use. Just main game folder. | ||
Line 50: | Line 66: | ||
::Don't change anything below here | ::Don't change anything below here | ||
"%Game_path%\bin\dmxconvert.exe" -i %1 -of dmx -oe keyvalues2 -o "%~dpn1_Keyvalues2.dmx"</source> | "%Game_path%\bin\dmxconvert.exe" -i %1 -of dmx -oe keyvalues2 -o "%~dpn1_Keyvalues2.dmx"</source> | ||
==Converting particles== | |||
Porting Particles from new games to old games (Csgo to Hl2) requires you to convert the pcf type.<br> | |||
As example, {{csgo|4}} "Binary 5 PCF 2" to {{hl2|4}} "Binary 2 PCF 1". | |||
{{note|If you do not want to use DMXConvert, you can use {{ent|Sparc}}<br> | |||
It is a unitasker specifically made to convert PCF files. It creates folders with converted files wherever the .exe is located. | |||
However, the drag-and drop bat file is a simpler version, where you can drag a pcf onto it, no matter where it is, and have the pcf be replaced with the version you want.}} | |||
{{warning|New games will have particle functions such as <code>Scalar Random</code> that old games do not have. In those cases you can try editing the particle to use simillar functions.}} | |||
You must use the new game's DMXConvert to turn the particle to raw text file. (DMX/PCF Keyvalues2)<br> | |||
Once that is done, the old game's DMXConvert can turn that raw text into the desired Binary and PCF version. | |||
Save this bat file on your pc, and set the "dmxconv_from" and "dmxconv_to" values.<br> | |||
Then drag and drop your particle onto this bat file. It will convert to Keyvalues 2, wait five seconds and to convert to Binary 2 PCF 1 and then close automatically. | |||
<source lang=bat>SET dmxconv_from=F:\Programme\SteamLibrary\steamapps\common\Counter-Strike Global Offensive | |||
SET dmxconv_to=F:\Programme\SteamLibrary\steamapps\common\Half-Life 2 | |||
::Don't change anything below here | |||
"%dmxconv_from%\bin\dmxconvert.exe" -i %1 -of pcf -oe keyvalues2 | |||
timeout 5 | |||
"%dmxconv_to%\bin\dmxconvert.exe" -i %1 -of pcf -oe binary | |||
</source> | |||
==External links== | |||
* [https://github.com/Blaco/DMX_Model_Utility_Scripts DMX Model Utility Scripts] - Includes a tool to automate encoding Model format DMX files with Dmxconvert without the need for bat files | |||
{{SDKTools}} | {{SDKTools}} |
Latest revision as of 13:07, 16 February 2025
DMXconvert is a command-line SDK tool which converts DMX files. It can be found in all Source 2013 games,
Counter-Strike: Global Offensive Authoring Tools ,
Left 4 Dead 2 Authoring Tools ,
Source Filmmaker , as well as in various
Source 2 Workshop Tools.
An example usage is: converting regular DMX files using "encoding binary 3 format model 15"
into others, such as plain text "encoding keyvalues2 1 format dmx 15"
.
This new Keyvalues 2 DMX 15 version could then be used in Blender Source Tools advanced Flex properties tab to copy the face flex rules from.
Usage
dmxconvert -i <in file> [-ie <in encoding hint>] [-o <out file>] [-oe <out encoding>] [-of <out format>]
If no output file is specified, dmx to dmx conversion will overwrite the input
: -r argument does a recursive search if the in file specifies wildcards
: -upconvert will auto-check out the files. If -i is not specified, it will operate on all DMX files}}
Supported DMX file encodings:
- keyvalues
- keyvalues2
- keyvalues2_flat
- keyvalues2_noids
- binary
- binary_seqids
- actbusy
- commentary
- entitylayer (not in
,
)
- vmt
- vmf (not in
)
- mks (in all games since
)
- tex_source1 (in all games since
)
Supported DMX file formats:
- dmx
- movieobjects
- sfm
- sfm_settings (in all games since
)
- sfm_session
- sfm_trackgroup
- pcf
- gui
- schema
- preset
- facial_animation
- model
- ved
- mks (in all games since
) (not in
)
- vmks
- mp_preprocess
- mp_root
- mp_model
- mp_anim
- mp_physics
- mp_hitbox
- mp_materialgroup
- mp_keyvalues
- mp_eyes
- mp_bonemask
- tex (in all games since
) (not in
)
- vtex
- world (in all games since
)
- worldnode (in all games since
)
- virtualvolumetexture
- vmap
- vanim
- animflags
Simple Drag and Drop bat file
As is the case with many Command-Line only tools, usage might be confusing. So here is a simple Drag and Drop .bat file script which automatically converts whatever DMX you drop into the bat into a Keyvalues 2 DMX 15 version, creating a new DMX file with the _Keyvalues2 suffix.
::Game location that has the DMXconvert you want to use. Just main game folder.
SET Game_path=d:\programme\steam\steamapps\common\left 4 dead 2
::Don't change anything below here
"%Game_path%\bin\dmxconvert.exe" -i %1 -of dmx -oe keyvalues2 -o "%~dpn1_Keyvalues2.dmx"
Converting particles
Porting Particles from new games to old games (Csgo to Hl2) requires you to convert the pcf type.
As example, Counter-Strike: Global Offensive "Binary 5 PCF 2" to
Half-Life 2 "Binary 2 PCF 1".

It is a unitasker specifically made to convert PCF files. It creates folders with converted files wherever the .exe is located.
However, the drag-and drop bat file is a simpler version, where you can drag a pcf onto it, no matter where it is, and have the pcf be replaced with the version you want.
Scalar Random
that old games do not have. In those cases you can try editing the particle to use simillar functions.You must use the new game's DMXConvert to turn the particle to raw text file. (DMX/PCF Keyvalues2)
Once that is done, the old game's DMXConvert can turn that raw text into the desired Binary and PCF version.
Save this bat file on your pc, and set the "dmxconv_from" and "dmxconv_to" values.
Then drag and drop your particle onto this bat file. It will convert to Keyvalues 2, wait five seconds and to convert to Binary 2 PCF 1 and then close automatically.
SET dmxconv_from=F:\Programme\SteamLibrary\steamapps\common\Counter-Strike Global Offensive
SET dmxconv_to=F:\Programme\SteamLibrary\steamapps\common\Half-Life 2
::Don't change anything below here
"%dmxconv_from%\bin\dmxconvert.exe" -i %1 -of pcf -oe keyvalues2
timeout 5
"%dmxconv_to%\bin\dmxconvert.exe" -i %1 -of pcf -oe binary
External links
- DMX Model Utility Scripts - Includes a tool to automate encoding Model format DMX files with Dmxconvert without the need for bat files
|