Forum

Author Topic: Texture is mangled  (Read 9269 times)

vfxman222

  • Newbie
  • *
  • Posts: 26
    • View Profile
    • Vimeo
Texture is mangled
« on: January 29, 2017, 03:28:56 AM »
This is the first time I've come across this issue. My texture is crazy mangled when using no matter what mapping mode I choose. I really need to use "Keep UV" though.

My pipeline:

- Do standard solve in PhotoScan.
- Export Raw mesh as OBJ.
- Import OBJ into Wrap3
- Import Base mesh from C4D (It is a quad mesh 26k polys)
- Do Wrap3 wrapping function
- Export the new OBJ
- Import the new clean obj mesh into PhotoScan (seems it doesn't like quads and retriangulates the mesh to 52k)
- Run Texture process with Keep UV, Mosaic, and Enable Hole Filling

I attached a screen cap of what I get. Any thoughts on the cause?
--
David Torno

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 14813
    • View Profile
Re: Texture is mangled
« Reply #1 on: January 30, 2017, 12:12:47 PM »
Hello David,

First a small comment regarding the quad mesh, if you are importing the mesh that contain only quad faces and are not removing any polygons in PhotoScan or decimating mesh, then the exported mesh after texturing would still contain same quad faces.

As for the texturing, could you please specify if the imported model contain only quad faces or triangles as well?

I can also suggest to check version 1.3 pre-release to see if the issue is still there, since we were fixing some issues with quad mesh support after 1.2.6 release.
Best regards,
Alexey Pasumansky,
Agisoft LLC

vfxman222

  • Newbie
  • *
  • Posts: 26
    • View Profile
    • Vimeo
Re: Texture is mangled
« Reply #2 on: February 01, 2017, 12:08:30 AM »
First a small comment regarding the quad mesh, if you are importing the mesh that contain only quad faces and are not removing any polygons in PhotoScan or decimating mesh, then the exported mesh after texturing would still contain same quad faces.
That's what I was expecting, but it didn't. I swore I've imported quad mesh before in the past. It has been awhile though.

As for the texturing, could you please specify if the imported model contain only quad faces or triangles as well?
The imported model should be 100% quads with a clean UV.

I can also suggest to check version 1.3 pre-release to see if the issue is still there, since we were fixing some issues with quad mesh support after 1.2.6 release.
I'd love to try it out. Point me in the right direction and I get it.

I can certainly send you a link to the three OBJ's (Raw, BaseMesh, final output) as reference if that helps too.
--
David Torno

vfxman222

  • Newbie
  • *
  • Posts: 26
    • View Profile
    • Vimeo
Re: Texture is mangled
« Reply #3 on: February 01, 2017, 12:14:27 AM »
Also here is a PhotoScan import versus Cinema4D import view of the same mesh, so you can see what I'm seeing.
--
David Torno

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 14813
    • View Profile
Re: Texture is mangled
« Reply #4 on: February 01, 2017, 12:31:49 AM »
Hello David,

PhotoScan displays imported quads as pairs of triangles, but the export of unchanged model should be still quad.

Version 1.3 pre-release can be downloaded from the following thread:
http://www.agisoft.com/forum/index.php?topic=5976.0
So let me know how it works in 1.3.

Best regards,
Alexey Pasumansky,
Agisoft LLC

vfxman222

  • Newbie
  • *
  • Posts: 26
    • View Profile
    • Vimeo
Re: Texture is mangled
« Reply #5 on: February 01, 2017, 12:41:54 AM »
Good to know, I didn't realize that the display was different than output.

I will get 1.3 and let you know if anything changes.
--
David Torno

vfxman222

  • Newbie
  • *
  • Posts: 26
    • View Profile
    • Vimeo
Re: Texture is mangled
« Reply #6 on: February 01, 2017, 01:00:08 AM »
Same deal. I will say though that the processing time for 8K texture was screaming fast compared to 1.2.6. As was the importing of the mesh.

The 1.3.0_3745 texture result is attached.

I do find it quite eerie that only the eyes are working though, even in 1.2.6.  :o
--
David Torno

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 14813
    • View Profile
Re: Texture is mangled
« Reply #7 on: February 01, 2017, 01:23:06 AM »
Hello David,

 If you can send the project file with camera alignment and thumbnails and model to be imported to support@agisoft.com, we'll try to find our what is the issue and fix it.
Best regards,
Alexey Pasumansky,
Agisoft LLC

vfxman222

  • Newbie
  • *
  • Posts: 26
    • View Profile
    • Vimeo
Re: Texture is mangled
« Reply #8 on: February 01, 2017, 02:15:03 AM »
Just sent off an email with the Dropbox link to you.
--
David Torno

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 14813
    • View Profile
Re: Texture is mangled
« Reply #9 on: February 01, 2017, 12:13:13 PM »
Hello David,

We have downloaded the data and re-build the texture on the imported quad-mesh, but we are not observing this issue. I've sent you an e-mail with the steps we've followed and produced results.

Can you check if it is not a visualization issue and provide the information how we can reproduce it?
Best regards,
Alexey Pasumansky,
Agisoft LLC

vfxman222

  • Newbie
  • *
  • Posts: 26
    • View Profile
    • Vimeo
Re: Texture is mangled
« Reply #10 on: February 01, 2017, 09:58:32 PM »
Alexey, Thanks so much for getting this to work. I am curious now, because I didn't realize I had packaged the initial source psz file "gaia-mcap07-pose001-hapd.psz" for you to use. I thought it was just the JPG sources.

I was using a duplicate of that file just so I wouldn't save over it by accident, and called it "Gaia_001_TexturingNewRetopo.psx". The file I sent along in the zip.  "Gaia_001_TexturingNewRetopo.psx" file is the one I was having this issue with. I am now seeing too that there are two different file extenstions psx versus psz. Standard versus pro versions of the software I assume. Could this have caused the glitch I was seeing? A possible corruption of data when duplicating the file?

Regardless, I used the steps as you stated in the email and used the same "gaia-mcap07-pose001-hapd.psz" file instead of my "Gaia_001_TexturingNewRetopo.psx" copy and everything worked just fine as expected. (First image "TextureWorksWithOGProject.JPG")


Your exported OBJ and texture were perfectly fine as well. Quad mesh and the material worked. (Second image inside Cinema4D "StillQuadAndTextureWorks.JPG")

Glad it works now.
--
David Torno

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 14813
    • View Profile
Re: Texture is mangled
« Reply #11 on: February 01, 2017, 10:14:29 PM »
Hello David,

PSX file should be accompanied with the .files folder having the corresponding name, can you then also share it, because we haven't found it in the provided data.
Best regards,
Alexey Pasumansky,
Agisoft LLC

vfxman222

  • Newbie
  • *
  • Posts: 26
    • View Profile
    • Vimeo
Re: Texture is mangled
« Reply #12 on: February 01, 2017, 10:53:17 PM »
Apologies, I didn't include those initially. Just uploaded a new ZIP to the same dropbox link. The ZIP is called "Gaia_001_TexturingNewRetopo_AllFiles.zip".
--
David Torno

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 14813
    • View Profile
Re: Texture is mangled
« Reply #13 on: February 02, 2017, 12:38:55 PM »
Hello David,

We've downloaded the PSX data and repeated the operation with Quad import and texture generation using Keep UV - the result is the same as in PSZ file and we are not observing any issues like you have.

The difference between formats is the following: PSZ - is a single file, whereas PSX is related to the project folder structure. The latter one is necessary for additional Pro version outputs, like Orthomosaic, DEM and Tiled model, but may be also useful if working with many chunks, as not the whole project would be kept in memory as it happens with the single project archive.
Best regards,
Alexey Pasumansky,
Agisoft LLC