Problem about specifying truecolor cData for a patch object
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Hi all,
I'm having trouble with coloring a patch object using cData. My patch object is a triangulated polyhedron, so size(ZData)=[3,12]. When I'm trying to color each face with truecolor, I'm setting size(CData)=[1,12,3] because [1,12] is the dimension of all triangular faces of the polyhedron and 3 is for RGB. However, MATLAB seems to interpret it as colormap indices so I always end up having an ugly blue polyhedron. My guess is MATLAB is misinterpreting the color information because all faces of the patch have 3 vertices, which coincide with the 3 elements for RGB. Is there a way to force MATLAB to interpret cData as truecolor? Or, am I using a wrong dimension of cData for my purpose?
Thanks a lot!
Niko
3 comentarios
Walter Roberson
el 18 de Dic. de 2013
A 12-element cell array as a result suggests that your "handle" might be a vector of handles.
Respuestas (0)
Ver también
Categorías
Más información sobre Polygons en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!