Esempio n. 1
0
void
sanguis::client::draw2d::scene::background::render(
	sge::renderer::context::core &_render_context,
	sanguis::client::draw2d::translation const _translation
)
{
	sprite_.texture_coordinates(
		sanguis::client::draw2d::scene::background_texture_coordinates(
			sanguis::client::draw2d::translation{
				(
					_translation.get()
					/
					fcppt::literal<
						sanguis::client::draw2d::unit
					>(
						2
					)
				).get_unsafe()
			},
			client_system_.renderer(),
			texture_
		)
	);

	client_system_.render(
		_render_context,
		sanguis::client::draw2d::sprite::client::category::background
	);
}
Esempio n. 2
0
sge::renderer::matrix4
sanguis::client::draw2d::scene::translation_matrix(
	sanguis::client::draw2d::translation const _translation
)
{
	return
		fcppt::math::matrix::translation(
			fcppt::math::vector::construct(
				fcppt::math::vector::structure_cast<
					sanguis::client::draw2d::vector2,
					fcppt::cast::int_to_float_fun
				>(
					_translation.get()
				),
				fcppt::literal<
					sanguis::client::draw2d::funit
				>(
					0
				)
			)
		);
}