Issues with colour/motion tracking instrument patch

    Jul 04 2013 | 8:04 pm
    I am currently working on a patch that tracks the motion and colour of live video using jit.findbounds. I am having difficulty troubleshooting a couple things:
    1. The contrast I have applied to jit.brcosa does not appear to be affecting the pwindow at all. I wonder if it is just a case of a missing patch chord, but I can’t seem to figure it out.
    2. The green and blue “trackers” are not working, only the red. This could be because jit.brcosa is not connected properly, or because of something else I am not currently aware of.
    3. I am using fluidsynth~ (in subpatchers) for each “tracker” and they should be producing sounds (using soundfonts in the patch file) — but nothing is happening there either. This could be tied in with the first issue, but it might be something else altogether.
    I am continuing to investigate each problem, but I would be grateful if anyone has some tips or suggestions for me. I have attached the patch here.
    Thank you in advance for your help!

    • Jul 04 2013 | 8:11 pm
      Whoops. Apparently the patch file was too large, probably because of the soundfonts. Here it is:
    • Jul 04 2013 | 8:28 pm
      It's interesting... we just discussed issues related to [jit.findbounds] in this topic:
      I'm just downloading your patch. Luckly it's realted to things I'm just doing, so I can spend some time with this... ;-)
    • Jul 04 2013 | 9:01 pm
    • Jul 04 2013 | 9:01 pm
      Hi again @Yaniki!
      That’s funny. Seems to be a hot topic around here. Thanks for the link, and any advice you have for me in the future!
    • Jul 04 2013 | 9:05 pm
      @Yaniki You fixed it! Thank you! What was the problem?
    • Jul 04 2013 | 9:06 pm
      I'm just study your patch. Some details to fix, but nothing special, I think I know, what you want to create. First we should made better tracking - wait 30 minutes, I send a patch.
      ps. funny, I'm using fluidsynth~ too...
    • Jul 04 2013 | 9:09 pm
      "You fixed it! Thank you! What was the problem?" - some chaotic connections between trigger and other objects. Nothing magical ;-)
      Is it all, you need, or can I help you more (my computer is just rendering some video... I have time...)
    • Jul 04 2013 | 9:38 pm
      It may not be magical to you, but it helps me out a lot! I just discovered fluidsynth~ on one of the threads here. It’s really fun to use. Currently mine are finicky — it works fine at times and then not at all. I found that I was limited with the amount of soundfonts I could use because it appears that there aren’t any sfArk to sf2 conversion software for Mac OS X... which is really too bad.
      That is all I need help with for now — but I really appreciate it!
    • Jul 04 2013 | 9:50 pm
      Ok Sasha - I'm glad it was so simple. But feel free to ask more if you need.
      I experienced actually the same issues as your related to fluidsynth~ - it's a great, but a bit limited tools.
      Now I think, it's better to use any VST or AU sampler instead of fluidsynth~, but it's not as handy solution, as this external.
    • Jul 04 2013 | 11:46 pm
      Yeah, I was thinking of looking into VST, but I will stick with fluidsynth~ at the moment.
      Do you have any advice for me in terms of making the blue and green trackers work? There must be a simple answer that I am missing.
    • Jul 05 2013 | 1:53 am
      @yaniki Hmm, in my Max window I’ve noticed that I keep getting this error:
      2013-07-04 20:57:37.996 Max[3621:c07] Error loading /Applications/Max6/Cycling '74/ftm-and-co/externals/ftm.javascript.mxo/Contents/MacOS/ftm.javascript: dlopen(/Applications/Max6/Cycling '74/ftm-and-co/externals/ftm.javascript.mxo/Contents/MacOS/ftm.jav ascript, 262): Symbol not found: _JS_DefineFunctions Referenced from: /Applications/Max6/Cycling '74/ftm-and-co/externals/ftm.javascript.mxo/Contents/MacOS/ftm.javascript Expected in: /Applications/Max6/ in /Applications/Max6/Cycling '74/ftm-and-co/externals/ftm.javascript.mxo/Contents/MacOS/ftm.javascript cannot enable FTM JavaScript support
      What is that about? Could that be a clue as to why the soundfonts aren’t functioning?
    • Jul 05 2013 | 8:21 am
      I'm not sure about this error message. Can't reproduce it on my computer. Looks like something related to JavaScript, but you have no JavaScript in the patch... strange.
      And about colour tracking: I see the problem... in my opinion this is something related to jit.findbounds object, not your patch (the same issue was discussed in the topic I mentioned).
      But we can create several workarounds. Simplest trick is to split image into 3 components (RGB) and process them independently (see attached patch). It's not very robust solution, I have something better in mind (based on solution from mentioned topic) and I send you patch based on this better architecture today later.
    • Jul 05 2013 | 12:36 pm
      Try this patch. It's just a color-tracking , but you can simple integrate it with you own portion of objects (just insert [r colorBounds1], [r colorBounds2] and [r colorBounds3] to the patch to receive data from color-trackers).
      This patch can track 3 colors (red, green, blue on beginning - but you can change it, if you want) in the same time. Play a bit with tolerance parameter for every tracker and with brcosa (especially saturation).
      If you want to change one of the colors to track choose tracker from menu in "displays and color selector" area, and click on pwindow (color of the pixel will be sent to the tracker).
      This should be a bit more flexible solution, compared to the previous one, even if is a bit more complex (btw: I'm sure this is something that can be simplified).
      Have fun with the patch and tell mi, if something is wrong or unclear.