Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice
  4. Dismiss Notice

Multitouch in Unity?

Discussion in 'General Discussion' started by Charles Hinshaw, Feb 25, 2008.

  1. Charles Hinshaw

    Charles Hinshaw

    Joined:
    Feb 6, 2008
    Posts:
    1,070
    For some reason, this popped into my head this afternoon... and I don't really know what prompted it.

    We should add multitouch capability. This is probably too fringe for built-in support from UT, but I would imagine that it would be a useful plugin... I am correct in assuming that this could be implemented with a plugin?

    I've played with TUIO (http://reactable.iua.upf.edu/?software) clients in Quartz Composer and Flash. It seems like a Unity client might be a good start.

    We could also look at blob-tracking libraries. OpenCV (http://sourceforge.net/projects/opencvlibrary/) supports this. There is TouchLib as a start too, but it looks Windows only at the moment: http://nuigroup.com/touchlib/

    I'm just picturing that Unity would be a really cool environment for developing content for table-based multi-touch displays. Has anyone else gone down this road? I saw a wish list request... but nothing where somebody had implemented something in Unity, I don't think.
     
  2. Trane

    Trane

    Joined:
    Dec 24, 2007
    Posts:
    2
    I'm really interested in this subject. Any further developments? I'm enduring Unity Tutorials, while shopping for the components to build my first multi-touch projector enabled table. I'm really looking for a lib or resource for mutlitouch nav in Unity3D. Any info you could share would be much appreciated.
     
  3. Jorgen

    Jorgen

    Joined:
    Dec 13, 2005
    Posts:
    38
    Hi,

    Find attached a quick implementation of the C# TUIO Library from reacTIVision, as a (very) basic tuio client in Unity.

    Enjoy!

    j.

    PS: We're throwing a workshop on the topic tomorrow at the Reboot10 festival (http://www.reboot.dk), drop by if you can!
     

    Attached Files:

  4. AngryAnt

    AngryAnt

    Keyboard Operator Moderator

    Joined:
    Oct 25, 2005
    Posts:
    3,045
    otee might as well implement this along with the iPhone port - creating a unified API for multi-touch.
     
  5. Jesper Johansen

    Jesper Johansen

    Joined:
    May 23, 2007
    Posts:
    51
    I have actually played around a lot with both touchlib and reactivision for other uses, and I must say I dont think either will ever become a standard in future multitouch setups. The demands for ambient necessaries are just too high in optical tracking setups.

    That being said, it would be great to have some sort of inputprovider embedded in Unity, so you could switch between various dll's supplying Unity with a translation and what-to-do with multiple coordinate inputs - this is the approach we're using at the moment in WPF. We can simply switch between hardware (driver) in a xml-file and then it wraps the inputs to a generic output - that being Nexio, Surface, TouchLib (TUIO) or whatever...
     
  6. dustin o'connor

    dustin o'connor

    Joined:
    Feb 15, 2009
    Posts:
    17
    multi-touch is cool but G Speak is way cooler. using OSC and some c-java-etc... or my preferred method quartz composer can turn just about any multi-touch, HID wii...etc... into a input source for Unity. if you just attach lets say HID input in QC to a OSC send then use the local loopback or network to get the values into Unity, you will not have a headache trying to find drivers and stuff for your HID joy stick. im using some of the Multi-touch principles meaning computer vision and optical flow to control unity with a web camera. no need for fancy IR LED, DI, FTIR setups.
     
  7. Dakta

    Dakta

    Joined:
    Apr 8, 2008
    Posts:
    492
    Could you, by any chance, give us pictures/code/videos/demos of any sort other than text of what you're doing?

    (Oh, and thanks for bumping this thread. It's pretty interesting)
     
  8. bliprob

    bliprob

    Joined:
    May 13, 2007
    Posts:
    901
    I have created a plugin for Unity that supports the PQLabs multitouch screen. I was waiting on a cool demo before announcing it. If anyone has a PQLabs screen and wants to try the plugin out, let m eknow.
     
  9. camaleonazul

    camaleonazul

    Joined:
    Oct 30, 2009
    Posts:
    1
    :eek: My university (www.upv.es) is planning to buy a PQLab Screen and I'm testing Unity3d. Would be fantastic if you can share your plugin to enhance our project. thanks!
     
  10. koichisenada

    koichisenada

    Joined:
    Nov 4, 2009
    Posts:
    10
    <Mod: this message looks a bit like spam with all the links and Multivitamin stuff, but don't worry - it's actually a real post!>

    bliprob, hello there!
    The company I am working at ( Vitamin Group with MultiVitamin ) is working on MultiTouch enabled applications actively.
    One of our last efforts was using MultiTouch with Art projects ( ArtMultiTouch )
    PQ Labs are our hardware supplier partner.
    We are to decide what is going to be the middleware for our next offline/online project, Entertainment MultiTouch.
    Chance are it's gonna be Unity3D, so could you please let us see your Unity3D MultiTouch plugin?
    We will test them with our G2 50" screens from PQ Labs and report the results.
     
  11. Sandor

    Sandor

    Joined:
    Apr 17, 2009
    Posts:
    91
    just stubled again on this posting. If you are still following this thread: uniTUIO is similar to Jorgens implementation (which is cool, thanks Jorgen!), but since is a bit newer, it will offer some more possibilities...

    Cheers,
     
  12. koichisenada

    koichisenada

    Joined:
    Nov 4, 2009
    Posts:
    10
    I suppose that's uniTUIO you have mentioned, Sandor.
    What are the similarities and differences between those two?
     
  13. Sandor

    Sandor

    Joined:
    Apr 17, 2009
    Posts:
    91
    yes it is uniTUIO i am talking about. It would be too long to compare them here, but since uniTUIO freely available and OpenSource, you are invited to test it out. If you have questions - please feel free to post them here on the forums...

    Cheers,
     
  14. koichisenada

    koichisenada

    Joined:
    Nov 4, 2009
    Posts:
    10
    Alright, so uniTUIO is freeware OpenSource project, alright.
    Does it support Windows 7 WM_TOUCH messages and devices based on that protocol, or TUIO protocol is the only one supported by uniTUIO?
     
  15. Sandor

    Sandor

    Joined:
    Apr 17, 2009
    Posts:
    91
    as the name says : uni + TUIO :) the windows touch protocol is working only on windows - we are trying to keep everything what's possible cross platform - that's why we are using TUIO as a protocol. Beside that TUIO is supported by a lot of the camera based vision systems (like BBTouch or the new xTOUCH (promo: look for them also on the www.xtuio.com site)). But you can have a look at the site of Martin Kaltenbrunner (the godfather of TUIO and the Reactable - www.tuio.org). There you can find a solution for using WM_Touch enabled hardware via TUIO...

    Cheers,
     
  16. gue4711

    gue4711

    Joined:
    Aug 11, 2011
    Posts:
    1
    Hi bliprob,

    i'm interested in this plugin - is it still available?

    thx gue
     
  17. Dreamora

    Dreamora

    Joined:
    Apr 5, 2008
    Posts:
    26,601
    since unity 3.4 the Windows 7 Multitouch capabilities can just be used from within unity through the same Input.touches etc as on mobiles.
     
  18. Madmaax

    Madmaax

    Joined:
    Aug 9, 2010
    Posts:
    4
    Hi, I am trying to use trough Input.touches on Unity 3.4 as you said, but no success. There is some option/setup to be able to use this support? Either outside (Windows Seven) or inside Unity?

    I also couldn't find any announcement on 3.4 roadmap or anywhere for this major upgrade!
     
  19. Sarudan

    Sarudan

    Joined:
    May 21, 2011
    Posts:
    65
    I'd also like to know if anything special needs to be done to get this to work as there is no documentation (or examples) available that I have come across.

    I've tried using touch input in Unity 3.4 via a Wacom Tablet, NextWindow touchscreen overlay, and a Mitsubishi driverless Windows 7 compliant touchscreen - none of which register any touch information inside Unity.

    Has anyone successfully used Windows 7 Touch Input in Unity 3.4?
     
  20. yvesh

    yvesh

    Joined:
    Apr 2, 2010
    Posts:
    14
    I believe Unity fixed the OnGUI() touch compatibility problem with Windows 7 compatible touchscreens wit the 3.4 release but it seems from my preliminary testing that Unity still hasn't included support for MultiTouch under Windows 7.
    Input.multiTouchEnabled returns false on my W7 touch system and I don't see the equivalent of iPhone input or AndroidInput for W7 in the API.
    Can someone from Unity confirm this is still not supported ?
     
  21. William Wong

    William Wong

    Joined:
    Aug 25, 2011
    Posts:
    1
    Same problem here x 2
    I have a 3M multitouch screen in our lab and it doesn't work as "Input.touches etc as on mobiles". It always return Input.multiTouchEnabled as false too.
    It always says Input.touchCount = 0, so neither single touch nor multi touch is working.
    Any example from Unity to show how it would work ?
     
  22. ledahu

    ledahu

    Joined:
    Feb 5, 2010
    Posts:
    2
    I tested with a PQLabs multitouch screen and i have the same result, Input.multiTouchEnabled return always false.
    I don't think windows touch is available in unity 3.4...
     
  23. yvesh

    yvesh

    Joined:
    Apr 2, 2010
    Posts:
    14
  24. Wolfram

    Wolfram

    Joined:
    Feb 16, 2010
    Posts:
    253
    Hi all,

    we are using both PQLabs touch overlays, and 3M monitors with Win7 multitouch. Both work flawlessly with uniTUIO in Unity, as Sandor mentioned several times above.

    To get Win7 to work with uniTUIO, we use Touch2Tuio, which translates and forwards the Win7 touches to TUIO, which is then interpreted by uniTUIO. The lag is even better when using the 3M Win7 touch, as opposed to the PQlabs native TUIO.

    However, I can confirm that native Win7 touch support does not seem to work in Unity 3.4.1 Pro. dreamora, is there a trick or setting you need to enable? Where did you get your info?
     
    Last edited: Sep 23, 2011
  25. techmage

    techmage

    Joined:
    Oct 31, 2009
    Posts:
    2,133
    I am looking at a need to get multitouch working on windows 7 surface as well. Has anyone figured anything out?

    Dreamora have you tested Input.Touches in unity on a windows 7 surface yourself? Did you get it to work?
     
  26. Vern_Shurtz

    Vern_Shurtz

    Joined:
    Mar 6, 2009
    Posts:
    264
    Has anyone been able to get Win 7 multitouch working in Unity?
     
  27. Super_apple

    Super_apple

    Joined:
    Mar 14, 2011
    Posts:
    31
    Is there somebo got the solution for Win7 MultiTouch ?
     
  28. davebuchhofer

    davebuchhofer

    Joined:
    Nov 9, 2007
    Posts:
    126
  29. elias_t

    elias_t

    Joined:
    Sep 17, 2010
    Posts:
    1,366
    I vote for win7 multitouch too.
     
  30. pnectarios

    pnectarios

    Joined:
    Jun 5, 2012
    Posts:
    2
    Hi, I am interested in the PQ-labs plugin for Unity. Is it available?
     
  31. bdovaz

    bdovaz

    Joined:
    Dec 10, 2011
    Posts:
    1,015
    We have a library that works without sockets or anything weird (= better performance and insignificant lag) like Tuio. It works directly in the editor, so you only have to hit play and have fun!! No publishing required to test it!!

    We are thinking to going public and publishing it in the asset store (low cost), is anyone interested?
     
  32. pnectarios

    pnectarios

    Joined:
    Jun 5, 2012
    Posts:
    2
    We are interested for the plugin. Does it support flash publishing?
     
  33. bdovaz

    bdovaz

    Joined:
    Dec 10, 2011
    Posts:
    1,015
    No, I'm only speaking about Windows 7.
     
  34. elias_t

    elias_t

    Joined:
    Sep 17, 2010
    Posts:
    1,366
    Yes of course. Count me in.
     
  35. TylerPerry

    TylerPerry

    Joined:
    May 29, 2011
    Posts:
    5,577
    Well personally i think having multi touch in our game's would be a good start? having it as simple as "Input.GetAnyTouch" for any amount of touches is a must :( It is damn right primitive, i don't care if it is slow it would be faster than anything i could make and people who don't like it could just make there own touch stuff, Oh and well I'm ranting, Input.MousePosition needs to work on all platforms... when i plug a mouse into my galaxy s2 it doesn't work(Can control Android with curser but not unity games)..

    (Hope none of these have been implemented as i did notice that Input.MousePostion is touches but i think it is single touch)
     
  36. joyceanblue

    joyceanblue

    Joined:
    Jul 26, 2010
    Posts:
    43
    id be interested in it too.. is there any particular hardware youve tested it with?
     
  37. Virtualware

    Virtualware

    Joined:
    Sep 17, 2012
    Posts:
    75
  38. creativetechDMNS

    creativetechDMNS

    Joined:
    Apr 29, 2014
    Posts:
    1
    If this plugin is still available, I would love to get a copy and would be very grateful. We're currently working on a multi-touch multi user touch table for a new exhibit opening at the Denver Museum of Nature Science and are using a PQ Gs overlay.
    Thank you!
     
  39. HavocX

    HavocX

    Joined:
    Jan 5, 2014
    Posts:
    40
    Take a look at TouchsScript! It is a multitouch framework for unity with TUIO, designed for large displays. Well supported and under active development. Has been confirmed to play nice with PQ surfaces. It is also really easy to use.

    http://interactivelab.github.io/TouchScript/
    http://forum.unity3d.com/threads/172955-TouchScript-%97-multi-touch-library-for-Unity-RELEASED
     
  40. SilverfernPro

    SilverfernPro

    Joined:
    Oct 24, 2013
    Posts:
    1
    Is this plugin still available? I would be very interested ( and grateful)
     
  41. yanmasharski

    yanmasharski

    Joined:
    Feb 20, 2014
    Posts:
    2
    Im interested in this plugin, can i get a copy?