示例#1
0
int main()
{
	LOG_INSTANCE->Initial("LoginServer.log");
	LOG_INSTANCE->SetLogPriority(Library::ELogType_All & ~Library::ELogType_Console_Debug);

	gce::attributes attr;
	attr.id_ = gce::atom("login_server");

	gce::context ctx_(attr);

	gce::actor<gce::threaded> base_(gce::spawn(ctx_));

	gce::net_option opt;
	opt.heartbeat_period_ = boost::chrono::seconds(15);
	opt.heartbeat_count_ = 5;

	gce::bind(base_, "tcp://127.0.0.1:5001");

	LoginServer server;
	server.Start();

	server.Run();

	return 0;
}
示例#2
0
 pixel_t operator()(const coord_t x, const coord_t y) const {
     return fn_(base_(x, y));
 }
示例#3
0
 pixel_t operator()(const coord_t x, const coord_t y) const {
     using grid_t = typename I::pixel_t;
     return base_((grid_t) std::round(x), (grid_t) std::round(y));
 }