(self, visual=None, **kwargs)
Specify or change the data associated to particular visual
        fields.
        
        Actual data upload on the GPU will occur during the rendering process, 
        in `paintGL`. It is just recorded here for later use.
        
        Arguments:
          * visual=None: the relevant visual. By default, the first one
            that has been created in `initialize`.
          * **kwargs: keyword arguments as `visual_field_name: value` pairs.
Specify or change the data associated to particular visual
        fields.
        
        Actual data upload on the GPU will occur during the rendering process, 
        in `paintGL`. It is just recorded here for later use.
        
        Arguments:
          * visual=None: the relevant visual. By default, the first one
            that has been created in `initialize`.
          * **kwargs: keyword arguments as `visual_field_name: value` pairs.
Specify or change the data associated to particular visual fields . Actual data upload on the GPU will occur during the rendering process in paintGL . It is just recorded here for later use . Arguments : * visual = None : the relevant visual . By default the first one that has been created in initialize . * ** kwargs : keyword arguments as visual_field_name : value pairs .
def set_data(self, visual=None, **kwargs):
        """Specify or change the data associated to particular visual
        fields.
        
        Actual data upload on the GPU will occur during the rendering process, 
        in `paintGL`. It is just recorded here for later use.
        
        Arguments:
          * visual=None: the relevant visual. By default, the first one
            that has been created in `initialize`.
          * **kwargs: keyword arguments as `visual_field_name: value` pairs.
        
        """
        # default name
        if visual is None:
            visual = 'visual0'
        # if this method is called in initialize (the renderer is then not
        # defined) we save the data to be updated later
        # print hasattr(self, 'renderer'), kwargs
        if not hasattr(self, 'renderer'):
            self.data_updating[visual] = kwargs
        else:
            self.renderer.set_data(visual, **kwargs)
            # empty data_updating
            if visual in self.data_updating:
                self.data_updating[visual] = {}
def set_data ( self , visual = None , * * kwargs ) : # default name if visual is None : visual = 'visual0' # if this method is called in initialize (the renderer is then not # defined) we save the data to be updated later # print hasattr(self, 'renderer'), kwargs if not hasattr ( self , 'renderer' ) : self . data_updating [ visual ] = kwargs else : self . renderer . set_data ( visual , * * kwargs ) # empty data_updating if visual in self . data_updating : self . data_updating [ visual ] = { }