Agisoft Metashape

Agisoft Metashape => Feature Requests => Topic started by: Infinite on September 25, 2012, 05:34:47 PM

Title: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: Infinite on September 25, 2012, 05:34:47 PM
**EDIT**

The point of this post, isn't so much to highlight and share workflows (although useful) the point of this post is to find a way to automate the whole process, as it shouldn't have to happen. An automated solution to cut workflow times from 12-15 hours down to a 5-10 minutes is hopeful outcome.

****

Hi, I wanted to put together a complex post explaining the issues currently related to UV mapping and texturing. Specifically Faces and Bodies. This is related to Multi Camera Arrays and Single Camera Capture, as well as capturing Objects and Artefacts.

Currently, Agisoft's best UV Mapping option is Generic (Atlast Mapping) which is OK but can produce very bad optimization of UV spaces:

(http://www.ir-ltd.net/images/agisoft/sml/Atlas-Texture.jpg) (http://www.ir-ltd.net/images/agisoft/Atlas-Texture.jpg)

To solve this you have to go through a very complex process or re-meshing (Dynamesh) and re-uvmapping a highres scan (UVMaster) the only way to do this is in ZBrush (effectively) this takes some time. Or more recently I have been using an external UV mapping application to Cylindrically map a 360 Head Scan with 200% Relax. Not ideal but faster:

(http://www.ir-ltd.net/images/agisoft/sml/uvmapper-01.jpg) (http://www.ir-ltd.net/images/agisoft/uvmapper-01.jpg)

Once this has been complete, you can import back to Agisoft and bake texture keeping UV's. This works great but then there is another issue present. Blurry Average Texturing (Mosaic and other methods wont solve this, as they produce other issues) Average is the best method. But the blending isn't ideal, especially on skin, as edge fresnel can cause clipping.

Custom Unwrap UV:

(http://www.ir-ltd.net/images/agisoft/sml/UV-average.jpg) (http://www.ir-ltd.net/images/agisoft/UV-average.jpg)

Average:

(http://www.ir-ltd.net/images/agisoft/sml/agi-average-01.jpg) (http://www.ir-ltd.net/images/agisoft/agi-average-01.jpg)

So to fix this, you have to bake Average, Left and Right one by one, then masking using layers in Photoshop to get a super sharp, crisp texture

Left:

(http://www.ir-ltd.net/images/agisoft/sml/agi-average-left-01.jpg) (http://www.ir-ltd.net/images/agisoft/agi-average-left-01.jpg)

Right:

(http://www.ir-ltd.net/images/agisoft/sml/agi-average-right-01.jpg) (http://www.ir-ltd.net/images/agisoft/agi-average-right-01.jpg)

PSD built by hand, blended using Masks in Layers:

(http://www.ir-ltd.net/images/agisoft/sml/agi-texture-clean-01.jpg) (http://www.ir-ltd.net/images/agisoft/agi-texture-clean-01.jpg)

Final Sharp Custom UVMapped, Custom Cleaned Texture:


(http://www.ir-ltd.net/images/agisoft/sml/agi-hand-crafted-01.jpg) (http://www.ir-ltd.net/images/agisoft/agi-hand-crafted-01.jpg)

Compare the 2:

(http://www.ir-ltd.net/images/agisoft/agi-average-animate-01.gif)

So this solves the problem, but is time consuming. One FACS scan can take about 45 minutes to 1 hour to process. Multiply that by 90 FACS. Well you get the idea.

I propose two things

1) Better UVMapping tools built in for Humans. Either some kind of Un-wrapping solution or at least Cylindrical UVMapping, similar to UVMapper application. Along with Relax controls by %

2) A better Texture Solution. For Sharper Textures, maybe by allowing the user to specify priority Cameras to force their details over all Camera images, to produce sharper textures:

(http://www.ir-ltd.net/images/agisoft/sml/agi-set-texture-priority.jpg) (http://www.ir-ltd.net/images/agisoft/agi-set-texture-priority.jpg)
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: kris3d on September 25, 2012, 05:42:17 PM
Very good guide. Thank you very much
I noticed that your camera is set to stereo.
Is the stereo setting gives better quality?
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: Infinite on September 25, 2012, 05:45:48 PM
Very good guide. Thank you very much
I noticed that your camera is set to stereo.
Is the stereo setting gives better quality?

This isn't so much a guide as a bug fix, feature improvement request post. But some useful information can be extrapolated.

Some Cameras are stereo others are just witness cameras to improve resolution.
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: Infinite on September 25, 2012, 06:02:00 PM
Proposed method for Average Blending of Priority Photographs for texturing:

Z-Depth calculation and percentage falloff control:

Scan:

(http://www.ir-ltd.net/images/agisoft/sml/agi-mudbox-fbx-scan.jpg) (http://www.ir-ltd.net/images/agisoft/agi-mudbox-fbx-scan.jpg)

Showing aligned projection:

(http://www.ir-ltd.net/images/agisoft/sml/agi-mudbox-fbx-scan-project.jpg) (http://www.ir-ltd.net/images/agisoft/agi-mudbox-fbx-scan-project.jpg)

Useful, Normals:

(http://www.ir-ltd.net/images/agisoft/sml/agi-mudbox-fbx-nm.jpg) (http://www.ir-ltd.net/images/agisoft/agi-mudbox-fbx-nm.jpg)

Z-Depth or Screen Distance Calculation (even possible using a simple fogging technique from Camera position to calculate mesh falloff from Camera position, to average blend textures):

(http://www.ir-ltd.net/images/agisoft/sml/agi-mudbox-fbx-scan-zdepth.jpg) (http://www.ir-ltd.net/images/agisoft/agi-mudbox-fbx-scan-zdepth.jpg)

Falloff Projection techniques:

(http://www.ir-ltd.net/images/agisoft/sml/falloff-projection01.jpg) (http://www.ir-ltd.net/images/agisoft/falloff-projection01.jpg)

(http://www.ir-ltd.net/images/agisoft/sml/falloff-projection02.jpg) (http://www.ir-ltd.net/images/agisoft/falloff-projection02.jpg)

(http://www.ir-ltd.net/images/agisoft/sml/falloff-projection03.jpg) (http://www.ir-ltd.net/images/agisoft/falloff-projection03.jpg)
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: Infinite on September 25, 2012, 09:43:22 PM
With built in Unwrapping tools such as Cylindrical or something similar we could achieve far superior 4D sequencing, with high resolution textures, also useful for tracking:

Mockup 4D mapping with UV viewer:

(http://www.ir-ltd.net/images/agisoft/sml/agi-mapping-4D-01.jpg) (http://www.ir-ltd.net/images/agisoft/agi-mapping-4D-01.jpg)

Example unwrapped texture output of 4D face data:

(http://www.ir-ltd.net/images/agisoft/sml/agi-mapping-4D-02.jpg) (http://www.ir-ltd.net/images/agisoft/agi-mapping-4D-02.jpg)

Related to this research:

http://www.youtube.com/watch?v=JoRhXFoGsXs (http://www.youtube.com/watch?v=JoRhXFoGsXs)

Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: Mr_Curious on October 15, 2012, 07:24:14 PM
+1

I would like to add my vote for what infinite has suggested, it would make life so much better!

Greetings,

Mr. Curious
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: Infinite on October 15, 2012, 07:53:51 PM
+1

I would like to add my vote for what infinite has suggested, it would make life so much better!

Greetings,

Mr. Curious

The Agisoft team have just implemented a new Texture Blending method for Mosaic, it works amazingly well! very sharp and well blended details. I'm not sure if it is Live on the forums yet. Worth checking out.

 All we need now is a new mapping method other than Generic/Atlas. Or something that can at least optimize the texture space properly and evenly.
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: acind on October 17, 2012, 12:59:15 PM

This sounds awesome, is this version with the improved mosaic available somewhere?
I have been doing some reprojection in maya, but this would certainly speed up workflows.
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: Mr_Curious on October 17, 2012, 04:41:55 PM
+1

I would like to add my vote for what infinite has suggested, it would make life so much better!

Greetings,

Mr. Curious

The Agisoft team have just implemented a new Texture Blending method for Mosaic, it works amazingly well! very sharp and well blended details. I'm not sure if it is Live on the forums yet. Worth checking out.

 All we need now is a new mapping method other than Generic/Atlas. Or something that can at least optimize the texture space properly and evenly.

I'm looking for this improved build, any idea where one can find it?

Greetings

Mr. Curious
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: Infinite on October 17, 2012, 05:31:50 PM
+1

I would like to add my vote for what infinite has suggested, it would make life so much better!

Greetings,

Mr. Curious

The Agisoft team have just implemented a new Texture Blending method for Mosaic, it works amazingly well! very sharp and well blended details. I'm not sure if it is Live on the forums yet. Worth checking out.

 All we need now is a new mapping method other than Generic/Atlas. Or something that can at least optimize the texture space properly and evenly.

I'm looking for this improved build, any idea where one can find it?

Greetings

Mr. Curious

It might not have been released yet, as the Agisoft guys have just got back from a tradeshow.
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: kris3d on October 24, 2012, 02:54:19 AM
hello infinite 

what program do you recommend to unwrap.
It actually improves the texture thanks for the tutorial
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: Infinite on October 24, 2012, 08:19:20 PM
hello infinite 

what program do you recommend to unwrap.
It actually improves the texture thanks for the tutorial

You can use UVMaster in ZBrush or Google UVMapper.

Agisoft REALLY needs a better UV Mapping algorithm. Something that can evenly space UV islands. At the moment it is very random and wasteful of texture space  :(
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: Mr_Curious on October 26, 2012, 02:43:07 PM
hello infinite 

what program do you recommend to unwrap.
It actually improves the texture thanks for the tutorial

You can use UVMaster in ZBrush or Google UVMapper.

Agisoft REALLY needs a better UV Mapping algorithm. Something that can evenly space UV islands. At the moment it is very random and wasteful of texture space  :(

+1

I second this.  I'm really hoping that this can be addressed, for many of us this is a matter of critical concern.

Greetings,

Mr. Curious
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: FoodMan on November 10, 2012, 06:31:21 PM
+1

with latest build it's even worse, now for a pretty complex model, Pscan creates only 2 charts (islands) and the texture has artifacts and visible stretches...
f/
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: FoodMan on November 11, 2012, 05:45:03 PM
ermmm... recently I also get a lot of overlapping UV on complex models.. not good..  :-[
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: Infinite on November 12, 2012, 12:25:42 AM
ermmm... recently I also get a lot of overlapping UV on complex models.. not good..  :-[

It might be good to post some examples of what you are finding. Images or files.
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: FoodMan on November 12, 2012, 09:17:43 AM
ok I will today

f/
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: eduardoestrada85 on November 12, 2012, 06:49:48 PM
+1

Improve Texture Feature.
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: Infinite on November 12, 2012, 11:36:07 PM
+1

Improve Texture Feature.

Mosaic texturing has now been greatly improved. The issue currently, is better UV Mapping, which I believe Agisoft LLC are looking into.
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: FoodMan on November 18, 2012, 01:55:50 PM
hello.... see the overlapping polygons in red...

(http://www.divshare.com/direct/20744991-ad0.jpg)

about everywhere

(http://www.divshare.com/direct/20745011-cbe.jpg)
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: Infinite on November 21, 2012, 07:47:21 PM
I think this is a known bug, I have also had this issue.
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: navalguijo on November 30, 2012, 12:22:47 AM
Learning a lot with this post!

Thanx Infinite!!!
Title: Re: Cylindrical UV Mapping (or Unwrap) with Relax solution and Blurry Texture issues
Post by: JarkkoL on April 23, 2013, 09:07:41 AM
The issue currently, is better UV Mapping, which I believe Agisoft LLC are looking into.
I would like more UV mapping options as well.
Cylindrical and cube or box map projection with relaxation would work very nicely for 'simple' objects.
Also orthophoto texturing could use uvw relax option.

Been trying to make proper textures from trees and cylindrical UV mapping would be very good for such work. (Easy to create looping textures.)
Also cube or box mapping would be very nice for a simple objects. (stones etc.)