Borrar filtros
Borrar filtros

Fix a colormap between two values

4 visualizaciones (últimos 30 días)
Thomas Barbier
Thomas Barbier el 26 de Jun. de 2019
Comentada: Adam Danz el 26 de Jun. de 2019
Dear all,
I am trying to simulatine the imaging of an object from a camera and a depth sensor. I'd then like to plot the simulated image thanks to the scatter tool, specifying depth as colormap. I make a new image at each time step. The camera motion is towards the object (and the object rotates), hence the overall depth diminishes. However, at each time step the colobar is mapped from depth of that time step:
At t = 0:
At t = end:
A video is available: https://youtu.be/ZlcGmUe4qoE
I would like to "fix" the colorbar between two handpicked values [depthMin depthMax], so that the first image is generally blue and the last image is generally yellow (that the colorbar doesn't "slide"). And if possible I'd like to use Matlab embedded colormaps.
Do you know a trick to do that ?
Thanks for your help.
Regards

Respuesta aceptada

Adam Danz
Adam Danz el 26 de Jun. de 2019
"I would like to "fix" the colorbar between two handpicked values [depthMin depthMax], so that the first image is generally blue and the last image is generally yellow "
caxis([depthMin, depthMax])
  2 comentarios
Thomas Barbier
Thomas Barbier el 26 de Jun. de 2019
True heroes don't wear capes.
Thanks!
Adam Danz
Adam Danz el 26 de Jun. de 2019
I'm wearing a lab coat. Does that count?
Glad I could help!

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Blue en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by