#include <exploder_cutter.hpp>
Public Types | |
typedef std::map< std::string, mask > | mask_map |
typedef std::multimap < std::string, positioned_surface > | surface_map |
Public Member Functions | |
cutter () | |
const config | load_config (const std::string &filename) |
void | load_masks (const config &conf) |
surface_map | cut_surface (surface surf, const config &conf) |
void | set_verbose (bool value) |
Private Member Functions | |
std::string | find_configuration (const std::string &file) |
void | add_sub_image (const surface &surf, surface_map &map, const config *config) |
Private Attributes | |
mask_map | masks_ |
bool | verbose_ |
Classes | |
struct | mask |
struct | positioned_surface |
Definition at line 23 of file exploder_cutter.hpp.
typedef std::map<std::string, mask> cutter::mask_map |
Definition at line 37 of file exploder_cutter.hpp.
typedef std::multimap<std::string, positioned_surface> cutter::surface_map |
Definition at line 47 of file exploder_cutter.hpp.
cutter::cutter | ( | ) |
Definition at line 23 of file exploder_cutter.cpp.
const config cutter::load_config | ( | const std::string & | filename | ) |
Definition at line 28 of file exploder_cutter.cpp.
References lg::err, find_configuration(), config::error::message, preprocess_file(), read(), and stream.
Referenced by composer::compose(), and main().
void cutter::load_masks | ( | const config & | conf | ) |
Definition at line 45 of file exploder_cutter.cpp.
References cutter::mask::cut, cutter::mask::filename, config::get_children(), get_mask_dir(), cutter::mask::image, make_neutral_surface(), masks_, cutter::mask::name, name, cutter::mask::shift, and verbose_.
Referenced by composer::compose(), and main().
cutter::surface_map cutter::cut_surface | ( | surface | surf, | |
const config & | conf | |||
) |
Definition at line 92 of file exploder_cutter.cpp.
References add_sub_image(), and config::get_children().
Referenced by add_sub_image(), composer::compose(), and main().
void cutter::set_verbose | ( | bool | value | ) |
Definition at line 161 of file exploder_cutter.cpp.
References verbose_.
Referenced by composer::compose(), and main().
std::string cutter::find_configuration | ( | const std::string & | file | ) | [private] |
Definition at line 107 of file exploder_cutter.cpp.
References file_name(), and get_exploder_dir().
Referenced by load_config().
void cutter::add_sub_image | ( | const surface & | surf, | |
surface_map & | map, | |||
const config * | config | |||
) | [private] |
Definition at line 124 of file exploder_cutter.cpp.
References cut_surface(), cutter::positioned_surface::image, cutter::mask::image, cutter::positioned_surface::mask, masks_, cutter::positioned_surface::name, name, cutter::positioned_surface::pos, pos, cutter::mask::shift, utils::split(), verbose_, exploder_point::x, and exploder_point::y.
Referenced by cut_surface().
mask_map cutter::masks_ [private] |
bool cutter::verbose_ [private] |
Definition at line 62 of file exploder_cutter.hpp.
Referenced by add_sub_image(), load_masks(), and set_verbose().
Generated by doxygen 1.5.5 on 23 May 2008 for The Battle for Wesnoth | Gna! | Forum | Wiki | CIA | devdocs |