Using relative paths and variables in pp3 files

I’m using v5.1 on Windows 10 64bit

I am using RawTherapee in cli mode to batch convert CR2 files to TIFs. I use the following line to process the files:
rawtherapee-cli.exe -o C:\output -p C:\pp3_dir\settings.pp3 -tu -w -Y -c input.CR2
In the pp3 file, I refer to an lcp file for lens correction and an icc file for colour management. Both of these have paths in this format:
LCPFile=C:\\lcp_dir\\lens1.lcp

My questions:

  1. Can this be replaced with a relative path? If so is this relative to the pp3 location or RawTherapee’s location or something else?
  2. Can this be replaced with a Windows environment variable like APPDATA or LOCALAPPDATA ?

Any advice is very much appreciated!

  1. Loading a PP3 with a relative path will work (at least in Linux using RT 5.2), but when you cause RawTherapee to save the PP3 an absolute path will be written instead of keeping the relative one. i.e. it looks like relative path support was unintentional. To have the LCP file key properly support relative paths, you could ask @agriggio very nicely if he would consider doing unto this as he did unto that.
  2. Not in Linux, probably not in Windows. You could just try and see.
  3. I recommend you update to 5.2.

technically, adding support for relative paths is easy. the problem is, relative to what? in the case of film simulations, that was pretty obvious. but not for LCP and/or DCP profiles. for the latter one could argue that the path should be relative to rt’s own DCP profiles path, but is this the intention? other comments/suggestions?

Thanks for the reply! Sorry I’ve been away since I posted.

Could you show me how you load a PP3 with relative path? I’ve tried but not succeeded - RT just ignored the line completely. What is the path relative to?

I also tried using environment variables but to no avail. Any idea what syntax I should try? (i.e. might percentage symbols work, and do I need to use the double backslashes?)

  1. Yes, I just did. Thanks

Thanks also agriggio. I’m not looking for RT to write relative paths, but only to understand them after I write them manually into a PP3 with a text editor. So it looks like RT already does this (albeit unintentionally).

LCPFile=foo.lcp
I tried one LCP next to the photo and one next to the executable, don’t remember now which worked.

Thanks!