Declared in module gview
gview.GvRasterLayer
gview.GvLayer
gview.GvData
gtk.GtkData
class GvRasterLayer(GvLayer): def gview.GvRasterLayer.__init__(self, raster=None, creation_properties=None, _obj=None, rl_mode=0) # Create a raster layer. def gview.GvRasterLayer.add_height(self, height_raster) # Adds height to raster layer for 3D effect. def gview.GvRasterLayer.alpha_get(self) def gview.GvRasterLayer.alpha_set(self, alpha_mode, alpha_check_val) def gview.GvRasterLayer.blend_mode_get(self) def gview.GvRasterLayer.blend_mode_set(self, mode, sfactor=0, dfactor=0) # Set blend mode def gview.GvRasterLayer.equalize(self) # Compute a histogram equalized source LUT, and apply. def gview.GvRasterLayer.get_const_value(self, isource) # Fetch source constant value def gview.GvRasterLayer.get_data(self, isource=0) # Fetch the GvRaster for a source. def gview.GvRasterLayer.get_mode(self) # Fetch the GvRasterLayer display mode. def gview.GvRasterLayer.launch_properties(self) def gview.GvRasterLayer.lut_color_wheel_1d_new(self, s=1.0, v=1.0, offset=0.0) def gview.GvRasterLayer.lut_color_wheel_new(self, h_mode, h_param, s_mode, s_param, v_mode, v_param) # Generate 2D LUT def gview.GvRasterLayer.lut_get(self) # Fetch the lut. def gview.GvRasterLayer.lut_put(self, lut=None) # Set the lut. def gview.GvRasterLayer.lut_type_get(self) # Fetch the LUT type. def gview.GvRasterLayer.max_get(self, isource) # Fetch the scaling maximum. def gview.GvRasterLayer.max_set(self, isource, max) # Set the scaling maximum. def gview.GvRasterLayer.min_get(self, isource) # Fetch the scaling minimum. def gview.GvRasterLayer.min_set(self, isource, min) # Set the scaling minimum. def gview.GvRasterLayer.set_source(self, isource, data, min=0, max=0, const_value=0, lut=None) # Set a data source def gview.GvRasterLayer.source_get_lut(self, isource=0) # Fetch the lut for a source def gview.GvRasterLayer.texture_clamp_set(self, s_mode, t_mode) def gview.GvRasterLayer.texture_mode_get(self) def gview.GvRasterLayer.texture_mode_set(self, texture_mode, color) # Set the texture mode. def gview.GvRasterLayer.zoom_get(self) # Fetch zoom mode def gview.GvRasterLayer.zoom_set(self, mag_mode, min_mode) # Set interpolation method # Inherited from gtk.GtkData def gtk.GtkData.__init__(self, _obj=None) # Inherited from gview.GvData def gview.GvData.__init__(self, _obj=None) def gview.GvData.changed(self) # Emit GvData changed signal. def gview.GvData.get_name(self) # Fetch the name of this GvData. def gview.GvData.get_parent(self) # Fetch parent GvData object. def gview.GvData.get_projection(self) # Fetch projection, if any. def gview.GvData.get_properties(self) # Get GvData properties (attributes) as a dictionary. def gview.GvData.get_property(self, name) # Get a GvData property. def gview.GvData.set_name(self, name) # Set the name of this GvData. def gview.GvData.set_projection(self, projection) # Set the projection. def gview.GvData.set_property(self, name, value) # Set a GvData property. # Inherited from gtk.GtkObject def gtk.GtkObject.__cmp__(self, other) def gtk.GtkObject.__getattr__(self, attr) def gtk.GtkObject.__getitem__(self, key) def gtk.GtkObject.__hash__(self) def gtk.GtkObject.__init__(self, _obj=None) def gtk.GtkObject.__setitem__(self, key, v) def gtk.GtkObject.connect(self, name, f, *extra) def gtk.GtkObject.connect(self, name, f, *extra) def gtk.GtkObject.connect_after(self, name, f, *extra) def gtk.GtkObject.connect_after(self, name, f, *extra) def gtk.GtkObject.connect_object(self, name, f, obj, *extra) def gtk.GtkObject.connect_object(self, name, f, obj, *extra) def gtk.GtkObject.connect_object_after(self, name, f, obj, *extra) def gtk.GtkObject.destroy(self, _obj=None) def gtk.GtkObject.disconnect(self, id) def gtk.GtkObject.emit(self, signal, *args) def gtk.GtkObject.emit_stop_by_name(self, sig) def gtk.GtkObject.flags(self, mask=None) def gtk.GtkObject.get_data(self, key) def gtk.GtkObject.remove_data(self, key) def gtk.GtkObject.set(self, dict) def gtk.GtkObject.set_data(self, key, value) def gtk.GtkObject.set_flags(self, flags) def gtk.GtkObject.signal_handler_block(self, id) def gtk.GtkObject.signal_handler_unblock(self, id) def gtk.GtkObject.signal_handlers_destroy(self) def gtk.GtkObject.unset_flags(self, flags) # Inherited from gview.GvLayer def gview.GvLayer.__init__(self, _obj=None) def gview.GvLayer.display_change(self) # Send a display property notification. def gview.GvLayer.extents(self) # Return extents of layer. def gview.GvLayer.is_visible(self) # Check if layer is visible. def gview.GvLayer.launch_properties(self) # Launch a properties panel for this layer. def gview.GvLayer.reproject(self, projection) # Attempt to change view projection. def gview.GvLayer.set_visible(self, visible) # Set layer visibility.
Create a raster layer.
Adds height to raster layer for 3D effect.
Georeferrencing information will be used to place height_raster with respect to layer.
Set blend mode
Compute a histogram equalized source LUT, and apply.
This method is not meaningful for RLM_COMPLEX layers, and will be ignored.
Fetch the GvRaster for a source.
Note that gview.RLM_SINGLE mode has one source (isource=0), gview.RLM_COMPLEX has one source, and gview.RLM_RGBA has four (red, green, blue and alpha). Any source may be None indicating that that source will use the constant value (see get_const_value()).
Fetch the GvRasterLayer display mode.
It will be one of gview.RLM_SINGLE (greyscale or pseudocolored raster band), gview.RLM_RGBA (RGBA composite from individual GvRaster bands), or gview.RLM_COMPLEX (complex GvRaster pseudocolored with 2D lookup table).
Generate 2D LUT
Returns a lut suitable for applying to a RLM_COMPLEX layer with the lut_put() method. See gvrasterpropdlg.py for an example of use of this method.
Fetch the lut.
The returned lut will be a string of 1024 bytes if 1D, or 262144 bytes if the lut is 2D. The data is stored in "RGBARGBA..." format.
Set the lut.
This method will reset the compositing lut on a rasterlayer. The lut should be a string of 1024 bytes for a 1D LUT and 262144 bytes (as a String) for a 2D LUT. The array should be stored in "RGBARGBA..." format.
2D LUTs should only be applied to layers in RLM_COMPLEX mode, and 1D LUTs should only be applied to layers in RLM_SINGLE mode. It is an error to apply luts in any other case.
Fetch the LUT type.
Returns one of RL_LUT_NONE, RL_LUT_1D, or RL_LUT_2D (defined in gvconst.py).
Set the scaling maximum.
This will trigger a redraw via the display-change signal if it changes the scaling value.
Set the scaling minimum.
This will trigger a redraw via the display-change signal if it changes the scaling value.
Set a data source
Sets all the configuration information for one of the data sources of a layer. This method will trigger a display-change signal if any values are altered.
Fetch the lut for a source
This fetches the pre-compositing lut applied to a source. It will be None (if there isn't any in effect), or a String of 256 values between 0 and 255. Source lut's can only be set with GvRasterLayer.set_source().
Set the texture mode.
The default mode is replace in which case the fragment color is ignored. In modulate mode the raster is modulated with the provided fragment color.
Fetch zoom mode
Returns the mag_mode, and min_mode interploation modes as a tuple. See also: zoom_set()
Set interpolation method
I believe mag_mode sets the interpolation mode when zooming in past 1:1 on a texture, and min_mode is the interpolation mode used for downsampling from the texture, but I am not sure. Both default to bilinear, and are normally changed together.
Emit GvData changed signal.
Send a notification that this data has changed, with a NULL change_info value.
Fetch parent GvData object.
This is typically used to get the underlying GvData on which a GvLayer (which is also a GvData) depends.
Fetch projection, if any.
The projection is normally expressed in OpenGIS Well Known Text format or an empty string if no value is available.
Get GvData properties (attributes) as a dictionary.
The properties are returned as a Python dictionary. Note that changes to this dictionary are not applied back to the GvData.
Get a GvData property.
NOTE: Returns None if property does not exist.
Set the projection.
This method won't actually modify the data geometry, only the interpretation of the geometry.
Set a GvData property.
Return extents of layer.
The extents are returned as a tuple (xmin,ymin,xmax,ymax).
Launch a properties panel for this layer.
Returns the dialog object, or None if none can be created.
Attempt to change view projection.
Currently this only works for rasters, but eventually it will modify the display projection of any kind of GvLayer.
Returns 0 on failure, or non-zero on success.
|