我不会告诉你们
我到现在还没解决
while(SDL_PollEvent(&event))
{
if(event.type==SDL_FINGERDOWN||
event.type==SDL_FINGERUP||
event.type==SDL_FINGERMOTION
)
{
//各手指状态
if(event.type==SDL_FINGERDOWN)
EVE_pos[event.tfinger.fingerId].state=1;
if(event.type==SDL_FINGERUP)
EVE_pos[event.tfinger.fingerId].state=3;
if(event.type==SDL_FINGERMOTION)
EVE_pos[event.tfinger.fingerId].state=2;
//各手指坐标
EVE_pos[event.tfinger.fingerId].x= event.tfinger.x*S_w;
EVE_pos[event.tfinger.fingerId].y = event.tfinger.y*S_h;
EVE_pos[event.tfinger.fingerId].id = event.tfinger.fingerId;
}
}
这种方法是不能获取各手指状态的
我到现在还没解决
while(SDL_PollEvent(&event))
{
if(event.type==SDL_FINGERDOWN||
event.type==SDL_FINGERUP||
event.type==SDL_FINGERMOTION
)
{
//各手指状态
if(event.type==SDL_FINGERDOWN)
EVE_pos[event.tfinger.fingerId].state=1;
if(event.type==SDL_FINGERUP)
EVE_pos[event.tfinger.fingerId].state=3;
if(event.type==SDL_FINGERMOTION)
EVE_pos[event.tfinger.fingerId].state=2;
//各手指坐标
EVE_pos[event.tfinger.fingerId].x= event.tfinger.x*S_w;
EVE_pos[event.tfinger.fingerId].y = event.tfinger.y*S_h;
EVE_pos[event.tfinger.fingerId].id = event.tfinger.fingerId;
}
}
这种方法是不能获取各手指状态的