Package mapnik :: Module _mapnik :: Class Image

Class Image

 object --+    
          |    
??.instance --+
              |
             Image

This class represents a 32 bit RGBA image.

Instance Methods
 
__init__(...)
__init__( (object)arg1, (int)arg2, (int)arg3) -> None :
 
__reduce__(...)
helper for pickle
 
blend(...)
blend( (Image)arg1, (int)arg2, (int)arg3, (Image)arg4, (float)arg5) -> None :
 
composite(...)
composite( (Image)self, (Image)image, (CompositeOp)mode [, (float)opacity=1.0]) -> None :
 
demultiply(...)
demultiply( (Image)arg1) -> None :
 
get_pixel(...)
get_pixel( (Image)arg1, (int)arg2, (int)arg3) -> int :
 
height(...)
height( (Image)arg1) -> int :
 
painted(...)
painted( (Image)arg1) -> bool :
 
premultiply(...)
premultiply( (Image)arg1) -> None :
 
save(...)
save( (Image)arg1, (str)arg2) -> None :
 
set_alpha(...)
set_alpha( (Image)arg1, (float)arg2) -> None : Set the overall alpha channel of the Image
 
set_color_to_alpha(...)
set_color_to_alpha( (Image)arg1, (Color)arg2) -> None : Set a given color to the alpha channel of the Image
 
set_grayscale_to_alpha(...)
set_grayscale_to_alpha( (Image)arg1) -> None : Set the grayscale values to the alpha channel of the Image
 
set_pixel(...)
set_pixel( (Image)arg1, (int)arg2, (int)arg3, (Color)arg4) -> None :
 
tostring(...)
tostring( (Image)arg1) -> object :
 
view(...)
view( (Image)arg1, (int)arg2, (int)arg3, (int)arg4, (int)arg5) -> ImageView :
 
width(...)
width( (Image)arg1) -> int :

Inherited from unreachable.instance: __new__

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Static Methods
 
from_cairo(...)
from_cairo( (object)arg1) -> Image :
 
open(...)
open( (str)arg1) -> Image :
Class Variables
  __instance_size__ = 32
Properties
  background
The background color of the image.

Inherited from object: __class__

Method Details

__init__(...)
(Constructor)

 

__init__( (object)arg1, (int)arg2, (int)arg3) -> None :

    C++ signature :
        void __init__(_object*,int,int)

Overrides: object.__init__

__reduce__(...)

 

helper for pickle

Overrides: object.__reduce__
(inherited documentation)

blend(...)

 

blend( (Image)arg1, (int)arg2, (int)arg3, (Image)arg4, (float)arg5) -> None :

    C++ signature :
        void blend(mapnik::image_32 {lvalue},unsigned int,unsigned int,mapnik::image_32,float)

composite(...)

 

composite( (Image)self, (Image)image, (CompositeOp)mode [, (float)opacity=1.0]) -> None :

    C++ signature :
        void composite(mapnik::image_32 {lvalue},mapnik::image_32 {lvalue},mapnik::composite_mode_e [,float=1.0])

demultiply(...)

 

demultiply( (Image)arg1) -> None :

    C++ signature :
        void demultiply(mapnik::image_32 {lvalue})

from_cairo(...)
Static Method

 

from_cairo( (object)arg1) -> Image :

    C++ signature :
        boost::shared_ptr<mapnik::image_32> from_cairo(PycairoSurface*)

get_pixel(...)

 

get_pixel( (Image)arg1, (int)arg2, (int)arg3) -> int :

    C++ signature :
        unsigned int get_pixel(mapnik::image_32,int,int)

height(...)

 

height( (Image)arg1) -> int :

    C++ signature :
        unsigned int height(mapnik::image_32 {lvalue})

open(...)
Static Method

 

open( (str)arg1) -> Image :

    C++ signature :
        boost::shared_ptr<mapnik::image_32> open(std::string)

painted(...)

 

painted( (Image)arg1) -> bool :

    C++ signature :
        bool painted(mapnik::image_32)

premultiply(...)

 

premultiply( (Image)arg1) -> None :

    C++ signature :
        void premultiply(mapnik::image_32 {lvalue})

save(...)

 

save( (Image)arg1, (str)arg2) -> None :

    C++ signature :
        void save(mapnik::image_32,std::string)

save( (Image)arg1, (str)arg2, (str)arg3) -> None :

    C++ signature :
        void save(mapnik::image_32,std::string,std::string)

save( (Image)arg1, (str)arg2, (str)arg3, (Palette)arg4) -> None :

    C++ signature :
        void save(mapnik::image_32,std::string,std::string,mapnik::rgba_palette)

set_alpha(...)

 

set_alpha( (Image)arg1, (float)arg2) -> None :
    Set the overall alpha channel of the Image

    C++ signature :
        void set_alpha(mapnik::image_32 {lvalue},float)

set_color_to_alpha(...)

 

set_color_to_alpha( (Image)arg1, (Color)arg2) -> None :
    Set a given color to the alpha channel of the Image

    C++ signature :
        void set_color_to_alpha(mapnik::image_32 {lvalue},mapnik::color)

set_grayscale_to_alpha(...)

 

set_grayscale_to_alpha( (Image)arg1) -> None :
    Set the grayscale values to the alpha channel of the Image

    C++ signature :
        void set_grayscale_to_alpha(mapnik::image_32 {lvalue})

set_pixel(...)

 

set_pixel( (Image)arg1, (int)arg2, (int)arg3, (Color)arg4) -> None :

    C++ signature :
        void set_pixel(mapnik::image_32 {lvalue},unsigned int,unsigned int,mapnik::color)

tostring(...)

 

tostring( (Image)arg1) -> object :

    C++ signature :
        _object* tostring(mapnik::image_32)

tostring( (Image)arg1, (str)arg2) -> object :

    C++ signature :
        _object* tostring(mapnik::image_32,std::string)

tostring( (Image)arg1, (str)arg2, (Palette)arg3) -> object :

    C++ signature :
        _object* tostring(mapnik::image_32,std::string,mapnik::rgba_palette)

view(...)

 

view( (Image)arg1, (int)arg2, (int)arg3, (int)arg4, (int)arg5) -> ImageView :

    C++ signature :
        mapnik::image_view<mapnik::ImageData<unsigned int> > view(mapnik::image_32 {lvalue},unsigned int,unsigned int,unsigned int,unsigned int)

width(...)

 

width( (Image)arg1) -> int :

    C++ signature :
        unsigned int width(mapnik::image_32 {lvalue})


Property Details

background

The background color of the image.

Get Method:
unreachable(...)
Set Method:
unreachable(...)