Linux Commandline arguments not working?
Hi, I'm trying to get the commandline arguments to work under Linux, launching from the Terminal.
My goal is to batch export several files, according to the commandline arguments page this should be accomplished by material_maker –export-material –target
"/Path/To/material_maker.x86_64" –export-material –target "Unreal/Unreal Engine 5" -o "/Path/To/ExportFolder/" "/Path/To/PTex.ptex"
However as the above failed (just creates a blank project) I decided to try and simply load an existing .ptex file with the command: "Path/To/material_maker.x86_64" "Path/To/PTexFile"
But this also just loads an empty project. I also tried adding a -i in case this was missing from the documentation example, but the same thing occurs.
Every ptex file I try can be loaded just fine through the File>Load menu, so it's something to do with passing the argument to the program under Linux I presume?
I was using a slightly older version of Material Maker, but I am now using the most current release and the issue still occurs.
Any help would be appreciated,
Thanks.
This works for me on MM 1.3 installed via Nix unstable pkgs material-maker --export-material --target "Godot/G4 Standard" -o ~/Documents stylized_stone_rocks.ptex.
With just 1 dash it opens MM into a blank project, but with 2 dashes before each arg it appears to open the splash screen and gives feedback to the building steps.
Currently for me, hovering over the Export Material option under File causes a seg fault so exporting via cmd is my only hope atm.
Thanks for the reply.
Unfortunately the additional hyphens didn't work for me (still launches just a blank project, and the console shows no build steps).
I did notice that I said the current release, just to clarify this, I was using a 1.4 release and then updated to last weeks 1.4b1 pre-release: https://github.com/RodZill4/material-maker/releases/download/1.4b1/material_maker_1_4b1_linux.tar.gz
and found the problem persisted.
I also have this issue (1.3 & 1.4b1). In the console it says:
Cannot open user://export_targets
(source)
If this is the same case for you, @chiefwhosm, it does seem like this error would prevent the external export targets from being loaded and allowing export to work.
That warning displays every time the program loads, so not just when trying to export via a command.
As an update, I did finally get the program to open project files instead of a blank project, but only if the .ptex file is in the same folder as the Material Maker executable.
It still didn't export though.
I had an issue on 1.4b2 as well (but on Windows) where only positional arguments worked but all flag arguments were ignored so it would always just open the ptex file. Downgrading o 1.3 helped.