Using Data to reconstruct an image
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
David Harra
el 17 de Ag. de 2022
Respondida: sudobash
el 19 de Ag. de 2022
I have 2 images of grains, one that contains smaller and one that contains significanlty larger. Each material is achieved via a rectilinear grid of coordinates. I want to merge the 2 images into one, in such a way I can remove an area of smaller grains and replace them by one of the larger features. I am wondering if anyone knows any methods or has came across examples like this? The end goal would be to have large features surrounded by all the smaller ones. The two images can be seen below to visualise it better
Any help would be greatly appreciated.
Dave :)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1100845/image.png)
0 comentarios
Respuesta aceptada
sudobash
el 19 de Ag. de 2022
Hello!
As per my understanding, the output image needs to have some large blobs of the second image with all the other pixels from the first image.
You could segment out the large blob from the second image and superimpose it onto the first image.
Approach 1:
If all the colours on the second image are unique, then you could simply create a mask and set the pixel value of the mask to your desired colour on the first image.
Approach 2:
If all the colours on the second image are not unique, you could use watershed segmentation to obtain each region. After which, create a mask and set the pixel value of the mask to your desired colour on the first image.
Hope this helps!
0 comentarios
Más respuestas (0)
Ver también
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!