#NEWLINE# def _data_changed( self , value ) : #NEWLINE# #INDENT# bw = ( len ( value . shape ) == 2 ) #NEWLINE# if ( ( not bw ) and ( self . cmap is not None ) ) : #NEWLINE# #INDENT# value = N . array ( ( ( ( 0.2989 * value [ ( ... , 0 ) ] ) + ( 0.587 * value [ ( ... , 1 ) ] ) ) + ( 0.114 * value [ ( ... , 2 ) ] ) ) ) #NEWLINE# #UNINDENT# value = N . rot90 ( value , self . rotate ) #NEWLINE# self . data_store [ 'image' ] = self . data = value #NEWLINE# if ( self . _dims != self . data . shape ) : #NEWLINE# #INDENT# self . plot . delplot ( 'camera_image' ) #NEWLINE# self . _dims = self . data . shape #NEWLINE# renderers = self . plot . img_plot ( 'image' , name = 'camera_image' , colormap = self . _get_cmap_function ( ) ) #NEWLINE# self . _image = value [ 0 ] #NEWLINE# #UNINDENT# self . plot . aspect_ratio = ( float ( self . _dims [ 1 ] ) / self . _dims [ 0 ] )