color coding

Noob Help - Color Generation

scottbernoth's picture

Hi, this is my first post, but i have been browsing the forum from the time i started delving into Quartz Composer. It has taken a while for me to get my brain in sync with doing stuff in Quartz, but i have got to a point were i can work out how to achieve most things that i want to do (usually by creating a massive, completely inelegant comp, cause I’d never written a line of code in my life). However i’ve hit a brick wall coming up with a way to achieve the following:

I want a to create a patch where inputs are: Color A Color B X no of Sample Colors of the gradient between both colors

outputs are X no. of Colors (I assume in a structure would be easiest).

Eg if Color A = Blue, Color B = Red , X = 10 output would be 10 colors equally spaced in Hue etc from each other from blue to red.

Is this possible? Will i have to learn to code to achieve it?

Object Detection (Composition by gtoledo3)

Author: gtoledo3
License: (unknown)
Date: 2010.12.23
Compatibility: 10.6
Categories:
Required plugins:
(none)

This composition shows an object detection routine that's enabled by using an offscreen texture to store color values.

I was inspired to whip up this composition after looking at the title and initial picture of an article at Lighthouse3D...but I haven't read the article yet! It's informed by a bunch of stuff I've been doing with id'ing moving objects with openCL; a simple version, if you will. It was a challenge to myself to reproduce the setup from the picture and title before reading the article.

Also, due credit of influence to Xiang Bai, and Jamie Shotton for having written good material on id-ing objects, that make this sort of ultra-obvious if you've read their work, as well as the earlier work of many others. It's also pretty darn apparent after doing any math involving normal calc, or coordinate masking, imo, so credit to whoever invented that, and stuff like the ...triangle :)

Limited to 10.6 because of the employment of some interaction patches. Keep source texture and rendering destination square for this example.

Kineme Video Tools with Point Grey FireFly MV

adrianward's picture

(bumped to a new thread instead of just a comment on a previous topic...)

I'm trying to get a Point Grey FireFly MV FFMV-03M2C firewire color camera working... Kineme Video Device Info is reporting the device is there and capable, using the CameraExplorer qtz shows the available settings, but no image ever is output. Looking at the console, I'm just seeing the camera failing to handshake due to some sort of color coding issue.

Apr 12 12:48:41 *: [VTVideoInputPatch execute:time:arguments:]  Waiting for transmission to begin...
Apr 12 12:48:40 *: libdc1394 error: Format_7 Error_flag_1 is set: in _dc1394_v130_handshake (/Users/smokris/prj/qc/plugin/VideoTools/libdc1394/dc1394/format7.c, line 122): invalid image position, size, color coding or ISO speed
Apr 12 12:48:40 *: libdc1394 error: Format_7 Error_flag_1 is set: in dc1394_format7_set_roi (/Users/smokris/prj/qc/plugin/VideoTools/libdc1394/dc1394/format7.c, line 803): Handshaking failed after setting color_coding
Apr 12 12:48:41 *: libdc1394 error: Format_7 Error_flag_1 is set: in _dc1394_v130_handshake (/Users/smokris/prj/qc/plugin/VideoTools/libdc1394/dc1394/format7.c, line 122): invalid image position, size, color coding or ISO speed
Apr 12 12:48:41 *: libdc1394 error: Format_7 Error_flag_1 is set: in dc1394_format7_set_roi (/Users/smokris/prj/qc/plugin/VideoTools/libdc1394/dc1394/format7.c, line 803): Handshaking failed after setting color_coding

or similar errors:

Apr 12 12:57:41 *: libdc1394 error: Format_7 Error_flag_1 is set: in _dc1394_v130_handshake (/Users/smokris/prj/qc/plugin/VideoTools/libdc1394/dc1394/format7.c, line 122): invalid image position, size, color coding or ISO speed
Apr 12 12:57:41 *: libdc1394 error: Format_7 Error_flag_1 is set: in dc1394_format7_set_roi (/Users/smokris/prj/qc/plugin/VideoTools/libdc1394/dc1394/format7.c, line 803): Handshaking failed after setting color_coding
Apr 12 12:57:48 *: libdc1394 error: Format_7 Error_flag_1 is set: in _dc1394_v130_handshake (/Users/smokris/prj/qc/plugin/VideoTools/libdc1394/dc1394/format7.c, line 122): invalid image position, size, color coding or ISO speed
Apr 12 12:57:48 *: libdc1394 error: Format_7 Error_flag_1 is set: in dc1394_format7_set_roi (/Users/smokris/prj/qc/plugin/VideoTools/libdc1394/dc1394/format7.c, line 803): Handshaking failed after setting color_coding
Apr 12 12:57:52 *: libdc1394 error: Format_7 Error_flag_1 is set: in _dc1394_v130_handshake (/Users/smokris/prj/qc/plugin/VideoTools/libdc1394/dc1394/format7.c, line 122): invalid image position, size, color coding or ISO speed
Apr 12 12:57:52 *: libdc1394 error: Format_7 Error_flag_1 is set: in dc1394_format7_set_roi (/Users/smokris/prj/qc/plugin/VideoTools/libdc1394/dc1394/format7.c, line 803): Handshaking failed after setting color_coding

This is after I've tried all possible resolutions and framerates, and thoroughly explored all color coding formats both manufacturer-documented and Kineme-suggested (MONO8, MONO16, RAW8, RAW16, YUV411, YUV422, YUV444, RGB8, Y8, Y16) and when I'm not getting "Invalid Color Coding" responses, I'm seeing "Waiting for transmission to begin..." and then nothing...

I believe this camera only supports monochrome images in its standard non-Format 7 modes (with a QuickTime based video feed, I only see a monochrome image). Unfortunately, I need color output.

The documentation for the camera suggests that color data is not retained when binning is used ("Color binning is not supported on the FMVU-03MTC or FFMV-03M2C. Color data is not maintained when operating these models in pixel binning mode."). So I guess that means if we use a Format 7 mode, we have to define the ROI but I'm not sure how? Kind of beyond my expertise by this stage.

So no support yet using Kineme Video Input - any further suggestions?