Agisoft Metashape

Agisoft Metashape => Agisoft Viewer => Topic started by: Ruben on January 19, 2016, 12:27:27 PM

Title: Agisoft Viewer - Camera path file
Post by: Ruben on January 19, 2016, 12:27:27 PM
Hey there, great software!

I was wondering how a camera path file should look like which can be imported into the Agisoft viewer or from where I can get it?

Cheers
Ruben
Title: Re: Agisoft Viewer - Camera path file
Post by: Alexey Pasumansky on January 19, 2016, 12:57:08 PM
Hello Ruben,

To create camera tracks for Agisoft Viewer we suggest to use Blender application. The workflow steps for the whole operation should be the following:
- export TLS file from the project that should be shown in Viewer,
- export lowpoly model (for example in OBJ format) from the same project without any changes in reference/scale. It can be based on the Sparse cloud and will be used as a reference for track creation in Blender,
- install Blender and open new project there,
- import OBJ (check that Z-up option is specified in the import window!),
- then create a camera track (some simple tracks can be created using basic Blender tutorials),
- in Blender open File Menu -> User Preferences -> Addons -> User -> Install from file -> use python script file for Blender (we can send it to you), make it active by turning on the check box,
- use File Menu -> Export -> OSG Camera Animation (.path) option to save your track,
- optionally you can save Blender project,
- open Agisoft Viewer,
- open TLS file using File Menu -> Open Dataset option,
- right-click on the dataset thumbnail in the Playlist pane and in the opened window specify path the the camera track (.path),
- press F5 to start the slideshow with camera tracks applied.
Title: Re: Agisoft Viewer - Camera path file
Post by: Alexey Pasumansky on January 19, 2016, 01:00:41 PM
Here's the script for Blender that allows to add path export file.
Title: Re: Agisoft Viewer - Camera path file
Post by: Ruben on January 20, 2016, 03:52:08 PM
Thank you Alexey,

do you know why my model sometimes dissapears on a high zoom-in level in the viewer? Tiles are perhaps broken but why are they and how to fix it?

Ruben
Title: Re: Agisoft Viewer - Camera path file
Post by: Alexey Pasumansky on January 20, 2016, 04:32:37 PM
Hello Ruben,

Maybe the point of rotation is farther than the model surface?
Title: Re: Agisoft Viewer - Camera path file
Post by: Ruben on January 20, 2016, 05:25:03 PM
I figured out, that the GPU memory was exceeded and therefore sometimes breaks up the model as the model is quite large.
Title: Re: Agisoft Viewer - Camera path file
Post by: frank.stremke on January 20, 2016, 06:46:02 PM
i was just about to ask the same question abouth the path seems like a very compex process and in most cases very uneccery complicated to. a path creating option like in sputnic or google earth based on curent static views would be grat for most aplications or at least teh possibility to view the object from some angle while it is rotation away.
my landscape models are just very flat from the side also the model is rotating to fast by default any way to change that
frank
Title: Re: Agisoft Viewer - Camera path file
Post by: beh011 on January 31, 2019, 02:19:52 AM
Hello,

Just wanting to know how I can download the python script in order to create the animation

Thanks
Title: Re: Agisoft Viewer - Camera path file
Post by: TMG on April 14, 2019, 04:13:46 PM
Hello,

Just wanting to know how I can download the python script in order to create the animation

Thanks

Ptyhon script is for .path file export from Blender software.

Alexey, when I create in blender path and export them to .path file in PhotoScan is generating only empty animation. In Blender is ok... Any idea?

Regards
TM
Title: Re: Agisoft Viewer - Camera path file
Post by: Alexey Pasumansky on April 17, 2019, 01:40:48 PM
Hello TMG,

Can you please provide the generated path file? I'm not observing this issue with some random animation exported from Blender.

Also note that in the latest version of Metashape it is possible to create the animation track manually via interface by adding the current viewpoint to the track as a keyframe. To enable the display of the keyframes in the Model view turn on the Animation in the Model Menu -> Show/Hide Items section.
Title: Re: Agisoft Viewer - Camera path file
Post by: ferengi on October 26, 2019, 08:31:32 PM
can you please update the script for blender 2.8?

after a lot of research, i fixed it my self

you have to change line 8 to     'blender': (2, 80, 0),

and replace INFO_MT_file_export with TOPBAR_MT_file_export

only problem i have: the path ist rotated 90° (easy to fix in bledner)