displaying RGB colours using SURF.
Ältere Kommentare anzeigen
I am trying to display a rgb colour map on a gridded surface using surf.
I have grids of each rgb colour. How do I combine to give the surf(x,y,z,C)?
thanks
6 Kommentare
Sian Allerton
am 28 Dez. 2020
Image Analyst
am 28 Dez. 2020
For the benefit of others, could you provide a small demo?
I'm attaching mine (which is based Bruno's method below).

Ameer Hamza
am 29 Dez. 2020
It should be "based on Ameer's method" :P
Sian Allerton
am 29 Dez. 2020
Walter Roberson
am 29 Dez. 2020
I suggest using warp()
Image Analyst
am 29 Dez. 2020
Sorry Ameer, you're absolutely right. Sometimes I work on too many problems too close together. I must have gotten confused.
Antworten (1)
Ameer Hamza
am 27 Dez. 2020
You can use texture mapping to display an RGB image on a surface(). See here: https://www.mathworks.com/matlabcentral/answers/91858-is-it-possible-to-perform-texture-mapping-within-matlab. For example
img = imread('pears.png');
z = peaks(100);
surf(z, ...
'FaceColor','texturemap',...
'EdgeColor','none',...
'Cdata',img)
view(3)
1 Kommentar
Image Analyst
am 27 Dez. 2020

Kategorien
Mehr zu Image Arithmetic finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
