The Battle for Wesnoth  1.15.0-dev
Macros | Enumerations
xbrz.cpp File Reference
#include "xBRZ/xbrz.hpp"
#include "config.hpp"
#include <cassert>
#include <cmath>
#include <algorithm>
#include "utils/functional.hpp"
Include dependency graph for xbrz.cpp:

Go to the source code of this file.

Macros

#define FORCE_INLINE   inline
 
#define DEF_GETTER(x)   template <RotationDegree rotDeg> uint32_t inline get_##x(const Kernel_3x3& ker) { return ker.x; }
 
#define DEF_GETTER(x, y)   template <> inline uint32_t get_##x<ROT_90>(const Kernel_3x3& ker) { return ker.y; }
 
#define DEF_GETTER(x, y)   template <> inline uint32_t get_##x<ROT_180>(const Kernel_3x3& ker) { return ker.y; }
 
#define DEF_GETTER(x, y)   template <> inline uint32_t get_##x<ROT_270>(const Kernel_3x3& ker) { return ker.y; }
 
#define a   get_a<rotDeg>(ker)
 
#define b   get_b<rotDeg>(ker)
 
#define c   get_c<rotDeg>(ker)
 
#define d   get_d<rotDeg>(ker)
 
#define e   get_e<rotDeg>(ker)
 
#define f   get_f<rotDeg>(ker)
 
#define g   get_g<rotDeg>(ker)
 
#define h   get_h<rotDeg>(ker)
 
#define i   get_i<rotDeg>(ker)
 

Enumerations

enum  RotationDegree
 
enum  BlendType
 

Macro Definition Documentation

◆ a

#define a   get_a<rotDeg>(ker)

Referenced by editor::editor_action_chain::action_count(), ai::readonly_context_impl::add_aspects(), ai::composite_aspect< T >::add_facet(), theme::add_object(), unit::apply_builtin_effect(), editor::context_manager::apply_mask_dialog(), battle_context::better_combat(), blend_surface(), BOOST_AUTO_TEST_CASE(), gui2::generator_base::build(), gui2::policy::placement::table::calculate_best_size(), characterization_distance_direction(), editor::mouse_action_paste::click_left(), editor::mouse_action_fill::click_left(), editor::mouse_action_fill::click_right(), ai::ai_default_rca::move_to_targets_phase::compare_groups(), ai::default_recruitment::recruitment::compare_unit_types(), computesizes(), movetype::terrain_info::data::config_has_changes(), ai::composite_aspect< T >::create_facet(), editor::context_manager::create_mask_to_dialog(), wfl::builtins::DEFINE_WFL_FUNCTION(), unit::describe_builtin_effect(), ai::ai_default_rca::aspect_attacks_base::do_attack_analysis(), editor::brush_drag_mouse_action::drag_generic(), editor::editor_action_chain::editor_action_chain(), unit_filter_impl::unit_filter_compound::fill(), sdl::fill_surface_rect(), ai::composite_aspect< T >::find_active(), theme::find_element(), findsetreg(), campaignd::format_addon_feedback_url(), font::from_cairo_format(), help::generate_ability_topics(), editor::context_manager::generate_map_dialog(), help::generate_trait_topics(), theme::get_action_item(), game_config::config_cache_transaction::get_active_map(), ai::default_recruitment::recruitment::get_cached_combat_value(), config::get_diff(), gui2::dialogs::addon_manager::get_name_filter_visibility(), ai::register_stage_factory< STAGE >::get_new_instance(), ai::register_goal_factory< GOAL >::get_new_instance(), ai::register_aspect_factory< ASPECT >::get_new_instance(), ai::register_lua_aspect_factory< ASPECT >::get_new_instance(), get_noise(), gui2::dialogs::addon_manager::get_status_filter_visibility(), gui2::dialogs::addon_manager::get_type_filter_visibility(), getnum(), ai::aspect_property_handler< T >::handle_delete(), ai::aspect_property_handler< T >::handle_get(), ai::aspect_property_handler< T >::handle_get_children(), impl_track_eq(), lua_common::impl_vconfig_get(), ng::create_engine::init_all_levels(), events::console_handler::init_map(), intf_unit_resistance(), editor::mouse_action::key_event(), l_str2int(), editor::editor_controller::left_click(), editor::editor_controller::left_drag_end(), editor::editor_controller::left_mouse_up(), game_config::library_name(), gui2::dialogs::addon_manager::load_addon_list(), game_config::load_config(), math_ult(), movetype::terrain_info::data::merge(), movetype::resistances::merge(), theme::modify(), editor::editor_controller::mouse_motion(), mp_game_settings::mp_game_settings(), ucs4::iterator_base< string_type, update_implementation >::operator!=(), operator!=(), wesnothd::banned_compare_subnet::operator()(), editor::editor_action_chain::operator=(), operator==(), operator>(), utils::parse_range(), editor::editor_action_chain::perform(), editor::editor_action_chain::perform_without_undo(), controller_base::play_slice(), gui2::dialogs::mp_lobby::post_build(), gui2::unit_preview_pane::print_attack_details(), editor::editor_controller::process_keyup_event(), ai::ai_default_rca::move_to_targets_phase::rate_group(), t_translation::read_builder_map(), theme::refresh_title(), theme::remove_object(), editor::context_manager::resize_map_dialog(), editor::editor_controller::right_click(), editor::editor_controller::right_drag_end(), editor::editor_controller::right_mouse_up(), rotate_around_centers(), scale_surface(), scale_surface_legacy(), scale_surface_sharp(), gui2::addon_list::select_addon(), gui2::addon_list::select_first_addon(), n_ref_counter::ref_counter< signed int >::set(), ai::typesafe_known_aspect< T >::set(), gui2::addon_list::set_addon_order(), gui2::addon_list::set_addons(), theme::set_resolution(), gui2::dialogs::campaign_selection::sort_campaigns(), wfl::function_expression::str(), wfl::list_expression::str(), wfl::where_expression::str(), submerge_alpha(), ai::readonly_context_impl::to_readonly_context_config(), color_t::to_sdl(), utils::basic_string_view< charT, traits >::to_string(), unit::unit(), editor::mouse_action_map_label::up_left(), editor::mouse_action_starting_position::up_left(), gui2::dialogs::addon_manager::update_all_addons(), terrain_builder::update_animation(), editor::editor_action_chain::~editor_action_chain(), simple_wml::node::~node(), and ai::default_recruitment::recruitment::~recruitment().

◆ b

#define b   get_b<rotDeg>(ker)

Referenced by ai::composite_aspect< T >::add_facet(), ai::ai_composite::add_goal(), ai::ai_composite::add_stage(), adjust_surface_alpha_add(), adjust_surface_color(), unit_creator::allow_add_to_recall(), unit_creator::allow_discover(), unit_creator::allow_get_village(), unit_creator::allow_invalidate(), unit_creator::allow_rename_side(), unit_creator::allow_show(), battle_context::better_combat(), blend_surface(), BOOST_AUTO_TEST_CASE(), brighten_image(), gui2::generator_base::build(), gui2::policy::placement::table::calculate_best_size(), characterization_distance_direction(), wfl::formula_debugger::check_breakpoints(), ai::ai_default_rca::move_to_targets_phase::compare_groups(), ai::default_recruitment::recruitment::compare_unit_types(), ai::composite_aspect< T >::composite_aspect(), game_events::wml_event_pump::context_skip_messages(), ai::composite_aspect< T >::create_facet(), wfl::builtins::DEFINE_WFL_FUNCTION(), ai::composite_aspect< T >::delete_all_facets(), dispatch2(), ai::vector_property_handler< T >::do_add(), editor::editor_controller::do_execute_command(), ai::engine_cpp::do_parse_aspect_from_config(), ai::engine_lua::do_parse_aspect_from_config(), ai::engine_fai::do_parse_candidate_action_from_config(), ai::engine_cpp::do_parse_candidate_action_from_config(), ai::engine_lua::do_parse_candidate_action_from_config(), ai::engine_cpp::do_parse_engine_from_config(), ai::engine_cpp::do_parse_goal_from_config(), ai::engine_lua::do_parse_goal_from_config(), ai::engine_fai::do_parse_stage_from_config(), ai::engine_cpp::do_parse_stage_from_config(), ai::engine_lua::do_parse_stage_from_config(), do_version_check(), sdl::fill_surface_rect(), findsetreg(), font::from_cairo_format(), funcstat(), game_config::config_cache_transaction::get_active_map(), ai::default_recruitment::recruitment::get_cached_combat_value(), preprocessor_data::get_chunk(), config::get_diff(), display::get_halo_manager(), hotkey::command_executor::get_menu_images(), get_noise(), getobjname(), greyscale_image(), ai::aspect_property_handler< T >::handle_delete(), editor::location_palette::handler_members(), editor::editor_palette< overlay >::handler_members(), impl_track_eq(), ng::create_engine::init_all_levels(), intf_eval_conditional(), game_lua_kernel::intf_fire_event(), game_lua_kernel::intf_fire_wml_menu_item(), lua_fileops::intf_read_file(), lua_gui2::intf_set_dialog_active(), lua_gui2::intf_set_dialog_markup(), game_config::library_name(), light_surface(), font::pango_text::link_aware(), localfunc(), luaB_collectgarbage(), luaK_setlist(), luaL_addlstring(), luaL_gsub(), luaV_execute(), luaV_finishOp(), luaW_pushtstring(), wesnothd::banned::mask(), mask_surface(), matchbalance(), math_ult(), monochrome_image(), negative_image(), noenv(), operator!=(), compare_samples_to_stringspan::operator()(), wesnothd::banned_compare_subnet::operator()(), image::o_modification::operator()(), operator+(), operator<=(), operator>=(), os_date(), ai::engine::parse_aspect_from_config(), ai::engine::parse_candidate_action_from_config(), ai::engine::parse_engine_from_config(), ai::engine::parse_goal_from_config(), utils::parse_range(), ai::engine::parse_stage_from_config(), image::precached_file_exists(), wesnothd::ban_manager::read(), read_all(), read_chars(), read_line(), rotate_around_centers(), game_lua_kernel::run_filter(), game_lua_kernel::run_wml_conditional(), save(), scale_surface(), scale_surface_legacy(), scale_surface_sharp(), sdl_copy_portion(), sepia_image(), gui2::addon_list::set_addon_order(), storyscreen::background_layer::set_base_layer(), image::set_color_adjustment(), storyscreen::background_layer::set_keep_aspect_ratio(), font::pango_text::set_link_aware(), storyscreen::background_layer::set_scale_horizontally(), storyscreen::background_layer::set_scale_vertically(), storyscreen::background_layer::set_tile_horizontally(), storyscreen::background_layer::set_tile_vertically(), game_events::wml_event_pump::set_undo_disabled(), gui2::dialogs::setup_pref_toggle_button(), playsingle_controller::show_turn_dialog(), gui2::dialogs::campaign_selection::sort_campaigns(), pathfind::step_compare(), str_char(), str_dump(), str_format(), str_gsub(), str_lower(), str_pack(), str_rep(), str_reverse(), str_upper(), submerge_alpha(), tconcat(), time_of_day_at(), color_t::to_sdl(), font::floating_label::use_markup(), utfchar(), simple_wml::node::~node(), and ai::default_recruitment::recruitment::~recruitment().

◆ c

#define c   get_c<rotDeg>(ker)

◆ d

#define d   get_d<rotDeg>(ker)

◆ DEF_GETTER [1/4]

#define DEF_GETTER (   x)    template <RotationDegree rotDeg> uint32_t inline get_##x(const Kernel_3x3& ker) { return ker.x; }

Definition at line 629 of file xbrz.cpp.

◆ DEF_GETTER [2/4]

#define DEF_GETTER (   x,
 
)    template <> inline uint32_t get_##x<ROT_90>(const Kernel_3x3& ker) { return ker.y; }

Definition at line 629 of file xbrz.cpp.

◆ DEF_GETTER [3/4]

#define DEF_GETTER (   x,
 
)    template <> inline uint32_t get_##x<ROT_180>(const Kernel_3x3& ker) { return ker.y; }

Definition at line 629 of file xbrz.cpp.

◆ DEF_GETTER [4/4]

#define DEF_GETTER (   x,
 
)    template <> inline uint32_t get_##x<ROT_270>(const Kernel_3x3& ker) { return ker.y; }

Definition at line 629 of file xbrz.cpp.

◆ e

#define e   get_e<rotDeg>(ker)

Referenced by ad_hoc_addon_fetch_session(), help::section::add_section(), ai::lua_goal::add_targets(), editor::context_manager::apply_mask_dialog(), assignment(), async_send_doc(), wesnothd::ban_manager::ban(), wesnothd::server::bans_handler(), preferences::base_manager::base_manager(), BOOST_AUTO_TEST_CASE(), help::help_manager::build_topic_tree(), play_controller::check_time_over(), lua_map_generator::create_map(), editor::context_manager::create_mask_to_dialog(), ai::formula_ai::create_optional_formula(), lua_map_generator::create_scenario(), image::create_texture_from_sub_file(), savegame::save_index_class::data(), decode(), ai::stage_unit_formulas::do_play_stage(), ai::stage_side_formulas::do_play_stage(), editor::editor_controller::do_screenshot(), wesnothd::server::dul_handler(), encode(), sp::enter_create_mode(), ai::formula_ai::evaluate(), wfl::move_candidate_action::evaluate(), wfl::attack_candidate_action::evaluate(), utils::detail::evaluate_formula_impl(), wfl::formula::execute(), gui2::dialogs::lua_interpreter::lua_model::execute(), wfl::base_candidate_action::execute_formula(), actions::undo_action::execute_undo_umc_wml(), exp1(), unit_filter_impl::unit_filter_compound::fill(), spirit_po::catalog_metadata::find_header_line(), savegame::savegame::finish_save_game(), forlist(), wfl::formula::formula(), frame_builder::frame_builder(), editor::editor_map::from_string(), mp::game_info::game_info(), gui2::dialogs::game_version::game_version(), editor::context_manager::generate_map_dialog(), get_addon_install_info(), get_addon_pbl_info(), preprocessor_data::get_chunk(), ai::formula_ai::get_keeps_cache(), ai::register_engine_factory< ENGINE >::get_new_instance(), gmatch_aux(), wesnothd::server::handle_nickserv(), wesnothd::server::handle_player_in_game(), handle_preprocess_command(), unit::has_ability_type(), translation::icompare(), gui2::init(), unit::init(), ng::create_engine::init_all_levels(), ng::create_engine::init_generated_level_data(), game_launcher::init_lua_script(), lua_gui2::intf_add_widget_definition(), isneg(), game_launcher::launch_game(), wesnothd::ban_manager::list_bans(), wesnothd::ban_manager::list_deleted_bans(), ai::formula_ai::load_candidate_action_from_config(), game_config::load_config(), font::load_font_config(), game_launcher::load_game(), game_config_manager::load_game_config(), image::load_image_sub_file(), editor::context_manager::load_map(), editor::map_context::load_scenario(), localstat(), luaK_storevar(), luaL_tolstring(), luaO_int2fb(), luaO_pushvfstring(), luaO_str2num(), luaW_pcall(), luaX_init(), main(), editor::editor_controller::main_loop(), ng::depcheck::MAKE_ENUM(), editor::map_context::map_context(), side_filter::match_internal(), terrain_filter::match_internal(), matchbalance(), matches_simple_filter(), math_type(), editor::mouse_action_select::mouse_action_select(), gui2::dialogs::mp_lobby::network_handler(), ai::formula_ai::on_create(), playsingle_controller::on_replay_end(), savegame::savegame::open_save_game(), spirit_po::default_plural_forms::compiler::operator()(), spirit_po::default_plural_forms::evaluator::operator()(), handle_receive_doc< Handler, ErrorHandler >::operator()(), filesystem::ostream_file(), simple_wml::document::output(), wfl::parse_expression(), wesnothd::ban_manager::parse_time(), help::topic::parsed_text(), team_builder::place_units(), campaign_controller::play_game(), game_launcher::play_multiplayer(), game_launcher::play_render_image_mode(), game_launcher::play_replay(), playsingle_controller::play_scenario(), game_launcher::play_test(), gui2::dialogs::title_screen::pre_show(), gui2::dialogs::loading_screen::pre_show(), wesnothd::server::process_command(), mp::lobby_info::process_gamelist_diff(), gamemap::read(), actions::undo_list::read(), wesnothd::ban_manager::read(), game_config::config_cache::read_cache(), wesnothd::server::read_config(), schema_validation::schema_validator::read_config_file(), savegame::read_save_file(), retstat(), lua_kernel_base::run(), server_base::run(), savegame::savegame::save_game(), events::menu_handler::save_map(), editor::map_context::save_map(), wesnothd::game::save_replay(), editor::map_context::save_scenario(), scale_surface(), gui2::dialogs::lua_interpreter::input_model::search(), wesnothd::game::send_history(), wesnothd::server::send_password_request(), gui2::dialogs::attack_predictions::set_data(), gui2::minimap::set_map_data(), ng::scenario::set_metadata(), editor::start(), str_gsub(), wfl::string_expression::string_expression(), SYNCED_COMMAND_HANDLER_FUNCTION(), tinsert(), tmove(), ai::readonly_context_impl::to_readonly_context_config(), wesnothd::ban_manager::unban(), actions::undo_action::undo_action(), game_launcher::unit_test(), gui2::dialogs::unit_test_mp_server_list(), unpack(), lua_map_generator::user_config(), game_events::WML_HANDLER_FUNCTION(), editor::context_manager::write_map(), savegame::save_index_class::write_save_index(), editor::context_manager::write_scenario(), editor::mouse_action::~mouse_action(), save_blocker::~save_blocker(), and unit::~unit().

◆ f

#define f   get_f<rotDeg>(ker)

Referenced by events::map_command_handler< Worker >::command::add_flag(), addk(), addprototype(), aux_upvalue(), gui2::implementation::builder_listbox::builder_listbox(), font::pango_text::calculate_size(), events::call_in_main_thread(), clearkeys(), clearvalues(), close_func(), createstdfile(), decrement_chunk_usage(), wfl::builtins::DEFINE_WFL_FUNCTION(), filesystem::delete_directory(), gui2::dialogs::loading_screen::display(), ai::engine_cpp::do_parse_aspect_from_config(), ai::engine_lua::do_parse_aspect_from_config(), ai::engine_cpp::do_parse_candidate_action_from_config(), ai::engine_cpp::do_parse_engine_from_config(), ai::engine_cpp::do_parse_goal_from_config(), ai::engine_lua::do_parse_goal_from_config(), ai::engine_cpp::do_parse_stage_from_config(), DumpCode(), ai::formula_ai::evaluate(), f_seek(), f_setvbuf(), f_write(), game_events::wml_event_pump::filter_event(), ng::flg_manager::find_suitable_faction(), unit_filter::first_match_on_map(), gamemap::for_each_loc(), gamemap::for_each_walkable_loc(), help::generate_faction_topics(), getupvalref(), display::init_flags(), lua_cpp::intf_closure_dispatcher(), lua_cpp::intf_dispatcher(), intf_sound_volume(), LoadCode(), lua_getallocf(), lua_load(), lua_newstate(), lua_setallocf(), lua_upvalueid(), luaD_precall(), luaF_newproto(), luaH_newkey(), luaK_code(), luaV_tointeger(), unit_animation::matches(), newupvalue(), open_func(), game_config::optional_features_report(), parlist(), wfl::parse_expression(), gui2::dialogs::addon_manager::pre_show(), image::precache_file_existence_internal(), read_number(), ai::composite_aspect< T >::recalculate(), gui2::listbox::register_sorting_option(), gui2::listbox::register_translatable_sorting_option(), gui2::register_widget(), registerlocalvar(), sound::music_track::resolve(), gui2::chatbox::set_active_window_changed_callback(), lua_cpp::set_functions(), tmove(), ai::composite_aspect< T >::to_config(), unarchive_dir(), and ng::flg_manager::update_available_leaders().

◆ FORCE_INLINE

#define FORCE_INLINE   inline

Definition at line 185 of file xbrz.cpp.

◆ g

#define g   get_g<rotDeg>(ker)

◆ h

#define h   get_h<rotDeg>(ker)

Referenced by gui2::gui_definition::activate(), display::announce(), gui2::canvas::append_cfg(), display::bounds_check_position(), gui2::implementation::builder_drawing::build(), gui2::implementation::builder_listbox::builder_listbox(), wb::move::calculate_new_route(), image::scale_exact_modification::calculate_size(), image::scale_into_modification::calculate_size(), game_lua_kernel::cfun_wml_action(), cfun_wml_condition(), clearkeys(), clearvalues(), createstrobj(), default_map_generator_job::default_generate_map(), events::menu_handler::do_search(), gui2::rectangle_shape::draw(), gui2::round_rectangle_shape::draw(), gui2::image_shape::draw(), gui2::text_shape::draw(), game_display::draw_footstep_images(), ai::formula_ai::get_keeps(), terrain_filter::get_locs_impl(), t_translation::get_map_size(), unit_frame::get_overlaped_hex(), wfl::gamemap_callable::get_value(), image::pixel_callable::get_value(), editor::location_palette::handler_members(), editor::editor_palette< overlay >::handler_members(), hash_str(), hash_value(), gui2::dialogs::preferences_dialog::hotkey_type_filter_callback(), CVideo::init_window(), internshrstr(), game_lua_kernel::intf_message(), game_events::event_handlers::log_handlers(), luaS_hash(), luaS_resize(), luaV_execute(), luaV_finishset(), luaV_objlen(), makeseed(), preferences::manager::manager(), display::minimap_location_on(), editor::context_manager::new_map_dialog(), editor::context_manager::new_scenario_dialog(), gui2::grid::place(), propagatemark(), terrain_builder::reload_map(), editor::context_manager::resize_map_dialog(), wesnothd::game::save_replay(), scale_surface(), scale_surface_legacy(), scale_surface_nn(), scale_surface_sharp(), display::scroll_to_tiles(), sdl_copy_portion(), wesnothd::game::send_history(), font::floating_label::set_height(), gui2::canvas::set_size(), ai::formula_ai::shortest_path_calculator(), str_pack(), str_packsize(), str_unpack(), stretch_surface_vertical(), tile_surface(), color_t::to_hex_string(), unit_animation::unit_animation(), unit_display::unit_healing(), and events::context::~context().

◆ i

#define i   get_i<rotDeg>(ker)

Enumeration Type Documentation

◆ BlendType

enum BlendType

Definition at line 540 of file xbrz.cpp.

◆ RotationDegree

Definition at line 189 of file xbrz.cpp.