cnr-isti-vclab / relight

A RTI library for creating and visualizing Reflectance Transformation Imaging
GNU General Public License v3.0
70 stars 13 forks source link

What is relight-merge for? #65

Closed BeebBenjamin closed 7 months ago

BeebBenjamin commented 8 months ago

Hey I am teaching myself how to use Relight in place of RTIBuilder and RTIViewer, I was wondering what is the use case for the application called relight-merge.

ponchio commented 8 months ago

Ciao, relight-merge has been created to make rti panoramas. It brings 2 or more RTI (in the same base: ptm or hsh) in the same quantization space, so that the coefficient planes can be combined. I am working on the new interface for relightlab and will integrate rti panorama functionality in it.

If you need any advice, have some feature request, want to test the new interface, contact me at @.*** and we can have a chat about it.

On Tue, Mar 5, 2024 at 5:00 PM Richard Benjamin Allen < @.***> wrote:

Hey I am teaching myself how to use Relight in place of RTIBuilder and RTIViewer, I was wondering what is the use case for the application called relight-merge.

— Reply to this email directly, view it on GitHub https://github.com/cnr-isti-vclab/relight/issues/65, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAUDV2Y5NMM573QQLMMUU4DYWXTYZAVCNFSM6AAAAABEHNEX3GVHI2DSMVQWIX3LMV43ASLTON2WKOZSGE3DSNJZGU4DENY . You are receiving this because you are subscribed to this thread.Message ID: @.***>

BeebBenjamin commented 8 months ago

Thanks for the clarification. I have been merging RTIs using Metashape, so if I am able to do this using Relight, it will be much better. I cannot see your email, GitHub has censored it. So I will find it online for the VCL at Pisa.

BeebBenjamin commented 7 months ago

I cannot get relight-merge to work.

What does Rti basis for /home/richard/tool-216/photos1/chunk_2/rti/info.json is different. mean?

BeebBenjamin commented 7 months ago

OK, I realise relight-merge only works for ptm and hsh, and not rbf.

I am getting another error now: Could not create remapped RTI directory: info.json

How do you specify an output folder?

ponchio commented 7 months ago

The last argument of the command line is the output folder:

relight-merge <first_ptm/info.json> <second_ptm/info.json>

BeebBenjamin commented 7 months ago

I still get the same error Could not create remapped RTI directory

ponchio commented 7 months ago

Please write the command line here... (and then I will clarify error reporting something more informative).

BeebBenjamin commented 7 months ago
./relight-merge /home/richard/tool-216/photos1/chunk_1/rti/info.json /home/richard/tool-216/photos1/chunk_2/rti/info.json /home/richard/tool-216/photos1/chunk_3/rti/info.json /home/richard/tool-216/photos1/chunk_4/rti/info.json /home/richard/tool-216/photos1/chunk_5/rti/info.json /home/richard/tool-216/photos1/chunk_6/rti/info.json /home/richa
rd/tool-216/photos1/chunk_7/rti/info.json /home/richard/tool-216/photos1/chunk_8/rti/info.json /home/richard/tool-216/photos1/chunk_9/rti/info.json /home/richard/tool-216/photos1/chunk_10/rti/info.json /home/richard/Documents/
ponchio commented 7 months ago

Ok, here is the issue: the folder /home/richard/Documents exits, you have to provide the path to a folder that does not (yep, sorry!) for example: /home/richard/Documents/tool-216

BeebBenjamin commented 7 months ago

OK, I am getting Segmentation fault (core dumped) now and then a directory called info.json

ponchio commented 7 months ago

If you can send me the samples I will ingestigate the problem and fix the code. Sorry for the mess, it was just a tool for myself, but thanks for alfa-testing it :)

BeebBenjamin commented 7 months ago

OK, what files do you need? Just the rti files, or do you need the jpgs too?

ponchio commented 7 months ago

Just the rti files, I will fake the jpegs, it could well be a windows related problem, but let's start with replicating functionality in my machine.

BeebBenjamin commented 7 months ago

OK, I have sent you a link to dropbox to your gmail. Thanks for you help!

BeebBenjamin commented 7 months ago

I generated these files using relight-cli command line:

./relight-cli /home/richard/tool-216/photos1/chunk_1/jpg /home/richard/tool-216/photos1/chunk_1/rti -n -m -b ptm -p 3

One thing I did notice is relight-cli doesn't make any files with the extension .ptm.

ponchio commented 7 months ago

relight-cli can generate files both in the 'legacy" formats (.ptm and .rti) if instead of a folder name as an argument you specify a .ptm filename, like this:

./relight-cli /home/richard/tool-216/photos1/chunk_1/jpg /home/richard/tool-216/photos1/chunk_1/rti.ptm -n -m -b ptm -p 3

in general, if you run a command line tool without arguments:

./relight-cli

you get a brief help.

In the meanwhile I have imporoved error management in the relight-merge tool and it now should work. (info.json in the input rti is optional).

BeebBenjamin commented 7 months ago

OK, I have compiled the new version and relight-merge works. I also needed to change the name of the folders to things like rti1, rti2, rti3.