Forum

Author Topic: Strange artifacts when baking surface scans onto a flat plane  (Read 6578 times)

loggie24

  • Newbie
  • *
  • Posts: 36
    • View Profile
Strange artifacts when baking surface scans onto a flat plane
« on: August 25, 2024, 04:41:18 AM »
Hello, baking bug report nr.2 :)

There is an issue with the way textures are being built when trying to reproject a highpoly surface onto a lowpoly plane, in this case for the purpose of creating tiling textures. The process is as follows:

1. I have scanned a rocky ground surface that I now wish to bake onto a 2D texture to later create a tiling texture
2. Decimate the rocky ground surface scan to just say 100 triangles, then do a heavy smooth operation to "flatten" it
3. Build the texture with the highpoly scan as a source, use either generic or orthophoto mapping, doesnt seem to matter

The problem? Strange artifacts, especially visible on the displacement map. See the pictures attached, better than me explaining it with words. Almost looks as if the reprojection range is not far enough on the Z axis, but I have no clue how Metashape does the baking, there are hardly any settings for this :(

This issue is present on all textures, from displacement to normals etc..

« Last Edit: August 25, 2024, 04:46:16 AM by loggie24 »

loggie24

  • Newbie
  • *
  • Posts: 36
    • View Profile
Re: Strange artifacts when baking surface scans onto a flat plane
« Reply #1 on: September 14, 2024, 03:41:07 PM »
Bump, would be nice of the developers to at least act like they care.

vineg

  • Newbie
  • *
  • Posts: 34
    • View Profile
Re: Strange artifacts when baking surface scans onto a flat plane
« Reply #2 on: September 27, 2024, 03:21:30 PM »
I can guess the problem is in self-overlap of a displacement map.
There are multiple candidates to the displacement value which are switched from pixel to pixel. Probably something like a "z fight" with positive and negative displacement offset.

For a flat surface it could be probably be corrected by shifting simplified model relative to detailed one, but it will introduce a shift in a displacement map texture which I don't know how to easily compensate.

loggie24

  • Newbie
  • *
  • Posts: 36
    • View Profile
Re: Strange artifacts when baking surface scans onto a flat plane
« Reply #3 on: October 13, 2024, 08:47:23 PM »
I can guess the problem is in self-overlap of a displacement map.
There are multiple candidates to the displacement value which are switched from pixel to pixel. Probably something like a "z fight" with positive and negative displacement offset.

For a flat surface it could be probably be corrected by shifting simplified model relative to detailed one, but it will introduce a shift in a displacement map texture which I don't know how to easily compensate.
It was indeed the z location of the plane relative to the source that was causing this issue. The solution is simply making sure the baking target model is covering the source model with no intersections. Thanks for the help :)