Agisoft Metashape > General

Change photo

(1/3) > >>

chehroma:
In 1.3.4 i use script for change photo

--- Code: ---for i in range(len(chunk.cameras)):
camera = chunk.cameras[i]
photo = camera.photo.copy()
photo.path = firstdir + camera.label
camera.photo = photo
--- End code ---
Now in 1.4 I have an error:

--- Quote ---Error: Can't open file: No such file or directory (2): d:/FTP/1516031537175/firstdir/1
--- End quote ---

Can you help me?

Alexey Pasumansky:
Hello chehroma,

In the version 1.4.0 there's an option in the Advanced preferences dialog that allows to exclude the filename extension from the camera labels when the photos are added to the project. If the option is turned on in your case, you can uncheck it, re-load the photos to the new chunk and try the script again.

chehroma:
Thank, but I have the same problem. This is my advanced preferences dialog. What are items I need to off/on.

Alexey Pasumansky:
Hello chehroma:

Preferences -> Advanced -> Export / Import -> Strip file extensions from camera labels.

chehroma:
Dont work, the same error.

--- Quote ---Error: Can't open file: No such file or directory (2): d:/FTP/1516031537175/first/1

--- End quote ---

Navigation

[0] Message Index

[#] Next page

Go to full version