3 of 3
3
tbeta and Quartz Composer
Posted: 28 January 2009 01:46 AM   [ Ignore ]   [ # 31 ]
Avatar
RankRankRankRankRankRank
Joined  2007-04-08
Total Posts:  2294
Moderator

This message zoomak from this thread: http://nuigroup.com/forums/viewthread/4216/ who says the height/width are only showing up as 0s. I took a quick look at the code changes and have no found a reason this would be. I’ll have to look into it more. If someone would like to try and debug, I can post the source if someone would like.

 Signature 

Follow me on:
My Website - Youtube - Twitter - Linkedin

Profile
 
 
Posted: 28 January 2009 03:18 AM   [ Ignore ]   [ # 32 ]
Avatar
RankRank
Joined  2008-06-26
Total Posts:  228
Jr. Member
Seth (cerupcat) - 28 January 2009 01:46 AM

This message zoomak from this thread: http://nuigroup.com/forums/viewthread/4216/ who says the height/width are only showing up as 0s. I took a quick look at the code changes and have no found a reason this would be. I’ll have to look into it more. If someone would like to try and debug, I can post the source if someone would like.

Hey Seth,

yeah, i can confirm that. Only “0” at w/h… If you would like to post the source… Maybe i have next week some time to take a look…

 Signature 

Sandor Rozsa
--
http://www.xtuio.com - home of uniTUIO: bringing MultiTouch in the 3’rd dimension
http://www.cd-cologne.de - my company homepage

Profile
 
 
Posted: 28 January 2009 07:50 PM   [ Ignore ]   [ # 33 ]
Avatar
Rank
Joined  2008-03-23
Total Posts:  92
New Member

Hey Seth,

I have like, 20 extra minutes today and I am trying to make the best of them grin I want to update BBTouch so that it can send the height/width stuff down the TUIO stream.  I just want to confirm the formatting really quick.

currently the TUIO packet looks like this:

s session ID, int32
x 0..1 x position, float
y 0..1 y position, float
X x speed, float
Y y speed, float
m vector acceleration, float

I presume the ‘new’ format is something like this:

s session ID, int32
x 0..1 x position, float
y 0..1 y position, float
X x speed, float
Y y speed, float
m vector acceleration, float
h height
w width

what are the height and width units?  are they in pixels? are they a float that is relative to the width of the screen (ie screen width = 1.0, blob width = 0.035 or something?)

Thanks!
-panda

 Signature 

http://benbritten.com/blog/category/multitouch/

Profile
 
 
Posted: 28 January 2009 08:02 PM   [ Ignore ]   [ # 34 ]
Avatar
RankRankRankRankRankRank
Joined  2007-04-08
Total Posts:  2294
Moderator

Hi panda smile

They are sent as floats ranging (0-1) as fractions of the screen and format is what you said:

s session ID, int32
x 0..1 x position, float
y 0..1 y position, float
X x speed, float
Y y speed, float
m vector acceleration, float
h height float
w width float

I double checked and couldn’t find out why the QC Client would only be receiving zeros. I’m not sure where I missed something. Basically all I did was add height/width paramters (floats) to the end of the current set of messages whereever I saw them. The same cpp code works for the MAX/MSP clients so not sure why it’s not here.

Also, it would be best if we put an if statment in so if the parameters are 5 it only updates the 5 parameters and if 7 it does height/width. That way it’ll work with all trackers. I was looking into this, but didn’t get to finish. If you’re able to do so, let me know and then I can use the source to do the same for the MAX/MSP and puredata clients since the code for the cpp files are all the same.

Here’s the updated source: http://www.nuicat.com/TUIO_Quartz.zip and if you need it, you can get the original source from the reactivision website.

 Signature 

Follow me on:
My Website - Youtube - Twitter - Linkedin

Profile
 
 
Posted: 28 January 2009 08:06 PM   [ Ignore ]   [ # 35 ]
Avatar
Rank
Joined  2008-03-23
Total Posts:  92
New Member

Hey Seth,

coolio, i know i am being a bit redundant, but I want to make sure i do it the right way grin

The 0..1 is relative to the screen width?

so a blob with a width of 1.0 would be as big as the screen, a blob with 0.5 width would be half the screen width, a blob with 0.1 would be a tenth.. etc.?

Thanks!
-panda

 Signature 

http://benbritten.com/blog/category/multitouch/

Profile
 
 
Posted: 28 January 2009 08:07 PM   [ Ignore ]   [ # 36 ]
Avatar
Rank
Joined  2008-03-23
Total Posts:  92
New Member

crap, either you edited your post or I am really dying in the heat wave we are having here in Melbourne and didnt even read it right the first time grin that is what i needed!

Cheers!
-panda

 Signature 

http://benbritten.com/blog/category/multitouch/

Profile
 
 
Posted: 28 January 2009 08:07 PM   [ Ignore ]   [ # 37 ]
Avatar
RankRankRankRankRankRank
Joined  2007-04-08
Total Posts:  2294
Moderator

Sorry I edited it. Wasn’t expecting you to reply so fast lol

And looks like I read your message wrong too since I didn’t realize you’re adding this to bbtouch. So means you’ll be forced into helping me fix the QC client since it’s broken for height/wdith as posted above. hehe

 Signature 

Follow me on:
My Website - Youtube - Twitter - Linkedin

Profile
 
 
Posted: 28 January 2009 08:27 PM   [ Ignore ]   [ # 38 ]
Avatar
Rank
Joined  2008-03-23
Total Posts:  92
New Member

heh,

yeah i plan to add it to BBTouch as a configureable thinger, so you will be able to do either the ‘new one’ or the ‘classic tuio’ grin does this mean i still have to help with the QC? wink

-panda

 Signature 

http://benbritten.com/blog/category/multitouch/

Profile
 
 
Posted: 28 January 2009 08:36 PM   [ Ignore ]   [ # 39 ]
Avatar
RankRankRankRankRankRank
Joined  2007-04-08
Total Posts:  2294
Moderator

Haha. No you don’t have to, but right now I’m stuck on it and it’s probably a 5-10 minute fix, but I don’t see the error.  So if you update bbtouch and I can’t sort out the height/width issue in QC, people won’t be able to get that info anyway wink

Also currently the updated QC client is setup that it will break “classic” bbtouch, touche and reactivision. The above that I mentioned (if statement) should solve it, but I’m not sure when I’ll be able to really get into it. Would probably take a professional like yourself a couple minutes wink lol

 Signature 

Follow me on:
My Website - Youtube - Twitter - Linkedin

Profile
 
 
Posted: 28 January 2009 09:40 PM   [ Ignore ]   [ # 40 ]
Avatar
Rank
Joined  2008-03-23
Total Posts:  92
New Member

Well, as I am not a QC programmer, it may take me longer than a few minutes, but if you make it easy and post a link to the code i will see if i can have a look at it in the next few days grin

 Signature 

http://benbritten.com/blog/category/multitouch/

Profile
 
 
Posted: 28 January 2009 10:42 PM   [ Ignore ]   [ # 41 ]
Avatar
RankRankRankRankRankRank
Joined  2007-04-08
Total Posts:  2294
Moderator

I attached the code above panda. It’s cpp, .m, and .h files. It’s not any QC stuff as I know nothing about QC either. My post above with the source link also explains the problem and issue. I’ll see if I can take a look, but as you know we’re all only one person wink

 Signature 

Follow me on:
My Website - Youtube - Twitter - Linkedin

Profile
 
 
Posted: 28 January 2009 10:46 PM   [ Ignore ]   [ # 42 ]
Avatar
Rank
Joined  2008-03-23
Total Posts:  92
New Member

oh hello there zip file!  helps if i read the whole thread eh?  Cool, if anything jumps out at me I will post it here grin

 Signature 

http://benbritten.com/blog/category/multitouch/

Profile
 
 
   
3 of 3
3