Interactive slides question

hello,

I am working on making a slide show in unity for touch devices.
I have tried two methods…

  1. Using slideshow script in unify community.
  2. Using camera orbit function modifying it so that it moves in horizontal direction over the slides.

The problem I am facing is with the touch and mouse axis codes… I am able to have the camera manoeuvre with touch but the touch direction gets messed up in both cases if I use mouse axis or touch.deltatouch … Also the biggest problem is when I simply touch the screen without swiping the screen moves towards the side from the middle of the screen where I initiated the touch. I require it to only react on swipe. I also tried to manipulate between touch phase conditions but either it didn’t make a difference or didn’t move altogether. Could someone direct me on how to go about this…
Appreciate the help…

Red.

P.s. (Attn. Moderators) I realise this is a generic type question… I had posted this on forums but I find unity answers more vibrant with solutions so I posted here. If it is not a proper platform to post this please advise and close this thread … Thank you.

[Update],

Currently I am working with this code :

	public GameObject ParentObject;
	private Vector3 NewVec = Vector3.zero;
	private float x = 0f;
	private bool xBool = false;

	void Update () 
	{
		if(Input.GetMouseButton(0) && (!xBool))
		{
			x = Input.GetAxis("Mouse X");

			if(x < 0)
			{
				xBool = true;
				NewVec.x += 24.0f;
				NewVec.y = 0f;
				NewVec.z = 0f;
				iTween.MoveTo(ParentObject, NewVec,2.25f);
			}
			else if(x > 0)
			{
				xBool = true;
				NewVec.x -= 24.0f;
				NewVec.y = 0f;
				NewVec.z = 0f;
				iTween.MoveTo(ParentObject, NewVec,2.25f);
			}
		}
		if(Input.GetMouseButtonUp(0))
		{
			xBool = false;
		}

Its working except that it starts to react if I just touch the screen.I want that it should only work for swipe and drag gestures in the respective direction.

I would like to use the method suggested by SaraCecilia for dtection of discreet events but am not able to incorporate it in my code.

Thanks in advance,
Red.

Did you check out TouchGestures? AngryAnt - Unity Hacks: Touch gestures