<p>Apologies in advance for the poor quality of this answer, but this sounds a little like what an ex-colleague was doing as part of his PhD. The "Free-Viewpoint video" papers listed at the bottom of <a href="https://www.researchgate.net/profile/James_Imber" rel="nofollow noreferrer">https://www.researchgate.net/profile/James_Imber</a> might be useful, or at least a starting point to find related work. </p>

CC BY-SA 3.0
2018-01-29T10:04:27.857Z
2018-01-29T10:04:27.857Z
Simon F
<p>I've not done this, but it seems like you could keep a store of a single image and update it with each new image you receive. For example, you capture the first image and project it onto the scene. It likely won't cover the entire scene. </p>

<p>When you capture the next image, assuming it's not from exactly the same place as the previous, you can combine it with the first image by mixing them 50/50. When you get the next image, you want to mix the existing image at 66.666% and the new image at 33.333%, etc.</p>

<p>So I think you'd need to keep the combined image, and a second image that is the count of how many images have covered each pixel. Then:</p>

<pre><code>for each pixel in the output that the new projection covers {
    existing_pixel = current pixel in the existing image
    num_pixels_mixed = current pixel in the image containing the count of images
    new_pixel = current pixel in the newly acquired image
    mix_amount = num_pixels_mixed / (num_pixels_mixed + 1)
    resulting_pixel = mix_amount * existing_pixel + (1 - mix_amount) * new_pixel
    increment the current pixel in the image containing the count of images
}
</code></pre>

CC BY-SA 3.0
2018-01-30T05:59:28.620Z
2018-01-30T05:59:28.620Z
user1118321
<p>Problem: I'm trying to dynamically texture a mesh of the real world generated by the Hololens over time using photos also captured from the Hololens, perhaps one photo per second. Each of the photos includes positional information of the Hololens from the time when the photo was taken, which allows me to project the images onto the existing mesh and figure out the UV mapping for each image.</p>

<p>In case of a single image, this seems fairly simple, as it is just standard projective texturing of the mesh. But I will be capturing a potentially endless stream of images over a span of time which will be taken from different positions and orientations. For acceptable performance, I cannot simply store and iterate through all photos and do projective texturing for each.</p>

<p>How can I perhaps generate a texture atlas &amp; accompanying UV mapping for the real world mesh and update it after each image?</p>

<texture><projections><uv-mapping>
Projective texturing from many images
TravisG
# Projective texturing from many images

(Asked by: username_0 on 2018-01-25)

Problem: I'm trying to dynamically texture a mesh of the real world generated by the Hololens over time using photos also captured from the Hololens, perhaps one photo per second. Each of the photos includes positional information of the Hololens from the time when the photo was taken, which allows me to project the images onto the existing mesh and figure out the UV mapping for each image.

In case of a single image, this seems fairly simple, as it is just standard projective texturing of the mesh. But I will be capturing a potentially endless stream of images over a span of time which will be taken from different positions and orientations. For acceptable performance, I cannot simply store and iterate through all photos and do projective texturing for each.

How can I perhaps generate a texture atlas & accompanying UV mapping for the real world mesh and update it after each image?

**Tags:** texture, projections, uv-mapping


---

## 2 answers

### Answer by username_1 on 2018-01-29. Score: 1

Apologies in advance for the poor quality of this answer, but this sounds a little like what an ex-colleague was doing as part of his PhD. The "Free-Viewpoint video" papers listed at the bottom of <https://www.researchgate.net/profile/James_Imber> might be useful, or at least a starting point to find related work.


---

### Answer by username_2 on 2018-01-30. Score: 0

I've not done this, but it seems like you could keep a store of a single image and update it with each new image you receive. For example, you capture the first image and project it onto the scene. It likely won't cover the entire scene.

When you capture the next image, assuming it's not from exactly the same place as the previous, you can combine it with the first image by mixing them 50/50. When you get the next image, you want to mix the existing image at 66.666% and the new image at 33.333%, etc.

So I think you'd need to keep the combined image, and a second image that is the count of how many images have covered each pixel. Then:

```
for each pixel in the output that the new projection covers {
    existing_pixel = current pixel in the existing image
    num_pixels_mixed = current pixel in the image containing the count of images
    new_pixel = current pixel in the newly acquired image
    mix_amount = num_pixels_mixed / (num_pixels_mixed + 1)
    resulting_pixel = mix_amount * existing_pixel + (1 - mix_amount) * new_pixel
    increment the current pixel in the image containing the count of images
}

```


---

