cubehelix.genjit now is a file ; auto window resize
This commit is contained in:
@@ -198,7 +198,7 @@
|
||||
"box" : {
|
||||
"comment" : "ARGB matrix output (unprocessed)",
|
||||
"id" : "obj-40",
|
||||
"index" : 0,
|
||||
"index" : 2,
|
||||
"maxclass" : "outlet",
|
||||
"numinlets" : 1,
|
||||
"numoutlets" : 0,
|
||||
@@ -2262,180 +2262,8 @@
|
||||
"numinlets" : 1,
|
||||
"numoutlets" : 2,
|
||||
"outlettype" : [ "jit_matrix", "" ],
|
||||
"patcher" : {
|
||||
"fileversion" : 1,
|
||||
"appversion" : {
|
||||
"major" : 8,
|
||||
"minor" : 5,
|
||||
"revision" : 6,
|
||||
"architecture" : "x64",
|
||||
"modernui" : 1
|
||||
}
|
||||
,
|
||||
"classnamespace" : "jit.gen",
|
||||
"rect" : [ 110.0, 335.0, 672.0, 730.0 ],
|
||||
"bglocked" : 0,
|
||||
"openinpresentation" : 0,
|
||||
"default_fontsize" : 12.0,
|
||||
"default_fontface" : 0,
|
||||
"default_fontname" : "Arial",
|
||||
"gridonopen" : 1,
|
||||
"gridsize" : [ 15.0, 15.0 ],
|
||||
"gridsnaponopen" : 1,
|
||||
"objectsnaponopen" : 1,
|
||||
"statusbarvisible" : 2,
|
||||
"toolbarvisible" : 1,
|
||||
"lefttoolbarpinned" : 0,
|
||||
"toptoolbarpinned" : 0,
|
||||
"righttoolbarpinned" : 0,
|
||||
"bottomtoolbarpinned" : 0,
|
||||
"toolbars_unpinned_last_save" : 0,
|
||||
"tallnewobj" : 0,
|
||||
"boxanimatetime" : 200,
|
||||
"enablehscroll" : 1,
|
||||
"enablevscroll" : 1,
|
||||
"devicewidth" : 0.0,
|
||||
"description" : "",
|
||||
"digest" : "",
|
||||
"tags" : "",
|
||||
"style" : "",
|
||||
"subpatcher_template" : "",
|
||||
"assistshowspatchername" : 0,
|
||||
"boxes" : [ {
|
||||
"box" : {
|
||||
"id" : "obj-11",
|
||||
"linecount" : 3,
|
||||
"maxclass" : "comment",
|
||||
"numinlets" : 1,
|
||||
"numoutlets" : 0,
|
||||
"patching_rect" : [ 50.0, 123.0, 570.0, 48.0 ],
|
||||
"text" : "Original cubehelix implementation from: Green, D. A., 2011, ‘A colour scheme for the display of astronomical intensity images’, Bulletin of the Astronomical Society of India, 39, 289.\n(2011BASI...39..289G at ADS.): https://www.mrao.cam.ac.uk/~dag/CUBEHELIX/"
|
||||
}
|
||||
|
||||
}
|
||||
, {
|
||||
"box" : {
|
||||
"id" : "obj-8",
|
||||
"linecount" : 2,
|
||||
"maxclass" : "comment",
|
||||
"numinlets" : 1,
|
||||
"numoutlets" : 0,
|
||||
"patching_rect" : [ 50.0, 176.0, 570.0, 34.0 ],
|
||||
"text" : "Below implementation based on D3 implementation by @mbostock https://github.com/d3/d3-plugins/tree/master/cubehelix"
|
||||
}
|
||||
|
||||
}
|
||||
, {
|
||||
"box" : {
|
||||
"id" : "obj-7",
|
||||
"linecount" : 3,
|
||||
"maxclass" : "comment",
|
||||
"numinlets" : 1,
|
||||
"numoutlets" : 0,
|
||||
"patching_rect" : [ 282.0, 54.0, 338.0, 48.0 ],
|
||||
"text" : "hue_offset is here to shift common Max hue values (with 0 as red) by 120° and make them work with the cubehelix algorithm (made to work with 0 as blue)"
|
||||
}
|
||||
|
||||
}
|
||||
, {
|
||||
"box" : {
|
||||
"id" : "obj-5",
|
||||
"maxclass" : "newobj",
|
||||
"numinlets" : 0,
|
||||
"numoutlets" : 1,
|
||||
"outlettype" : [ "" ],
|
||||
"patching_rect" : [ 105.0, 52.0, 155.0, 22.0 ],
|
||||
"text" : "param hue_offset 0.333333"
|
||||
}
|
||||
|
||||
}
|
||||
, {
|
||||
"box" : {
|
||||
"id" : "obj-3",
|
||||
"maxclass" : "newobj",
|
||||
"numinlets" : 0,
|
||||
"numoutlets" : 1,
|
||||
"outlettype" : [ "" ],
|
||||
"patching_rect" : [ 317.0, 14.0, 203.0, 22.0 ],
|
||||
"text" : "param color_end -0.666666 0.5 1. 1."
|
||||
}
|
||||
|
||||
}
|
||||
, {
|
||||
"box" : {
|
||||
"id" : "obj-2",
|
||||
"maxclass" : "newobj",
|
||||
"numinlets" : 0,
|
||||
"numoutlets" : 1,
|
||||
"outlettype" : [ "" ],
|
||||
"patching_rect" : [ 105.0, 14.0, 202.0, 22.0 ],
|
||||
"text" : "param color_start 0.888888 0.5 0. 1."
|
||||
}
|
||||
|
||||
}
|
||||
, {
|
||||
"box" : {
|
||||
"code" : "h_s = (color_start.x + hue_offset) * TWOPI;\r\nh_e = (color_end.x + hue_offset) * TWOPI - h_s;\r\ns_s = color_start.y;\r\ns_e = color_end.y - s_s;\r\nl_s = color_start.z;\r\nl_e = color_end.z - l_s;\r\n\r\n\r\nh = h_s + h_e * norm;\r\nl = pow(l_s + l_e * norm, gamma);\r\na = (s_s + s_e * norm) * l * (1 - l);\r\n\r\ncosh = cos(h);\r\nsinh = sin(h);\r\n\r\nr = l + a * (-0.14861 * cosh + 1.78277 * sinh);\r\n\r\ng = l + a * (-0.29227 * cosh - 0.90649 * sinh);\r\n\r\nb = l + a * (1.97294 * cosh);\r\n\r\nout1 = vec(1, r, g, b);",
|
||||
"fontface" : 0,
|
||||
"fontname" : "<Monospaced>",
|
||||
"fontsize" : 12.0,
|
||||
"id" : "obj-12",
|
||||
"maxclass" : "codebox",
|
||||
"numinlets" : 1,
|
||||
"numoutlets" : 1,
|
||||
"outlettype" : [ "" ],
|
||||
"patching_rect" : [ 50.0, 224.0, 531.0, 382.0 ]
|
||||
}
|
||||
|
||||
}
|
||||
, {
|
||||
"box" : {
|
||||
"id" : "obj-10",
|
||||
"maxclass" : "newobj",
|
||||
"numinlets" : 0,
|
||||
"numoutlets" : 1,
|
||||
"outlettype" : [ "" ],
|
||||
"patching_rect" : [ 540.0, 14.0, 99.0, 22.0 ],
|
||||
"text" : "param gamma 1."
|
||||
}
|
||||
|
||||
}
|
||||
, {
|
||||
"box" : {
|
||||
"id" : "obj-1",
|
||||
"maxclass" : "newobj",
|
||||
"numinlets" : 0,
|
||||
"numoutlets" : 1,
|
||||
"outlettype" : [ "" ],
|
||||
"patching_rect" : [ 50.0, 14.0, 28.0, 22.0 ],
|
||||
"text" : "in 1"
|
||||
}
|
||||
|
||||
}
|
||||
, {
|
||||
"box" : {
|
||||
"id" : "obj-4",
|
||||
"maxclass" : "newobj",
|
||||
"numinlets" : 1,
|
||||
"numoutlets" : 0,
|
||||
"patching_rect" : [ 50.0, 623.0, 35.0, 22.0 ],
|
||||
"text" : "out 1"
|
||||
}
|
||||
|
||||
}
|
||||
],
|
||||
"lines" : [ {
|
||||
"patchline" : {
|
||||
"destination" : [ "obj-4", 0 ],
|
||||
"source" : [ "obj-12", 0 ]
|
||||
}
|
||||
|
||||
}
|
||||
]
|
||||
}
|
||||
,
|
||||
"patching_rect" : [ 126.513736263736178, 482.0, 129.0, 22.0 ],
|
||||
"text" : "jit.gen @title cubehelix"
|
||||
"patching_rect" : [ 126.513736263736178, 482.0, 162.0, 22.0 ],
|
||||
"text" : "jit.gen @gen cubehelix.genjit"
|
||||
}
|
||||
|
||||
}
|
||||
@@ -2540,7 +2368,7 @@
|
||||
"box" : {
|
||||
"comment" : " Outputs lists of colors, formatted accordingly to coloroutputmode and alpha_last",
|
||||
"id" : "obj-88",
|
||||
"index" : 0,
|
||||
"index" : 3,
|
||||
"maxclass" : "outlet",
|
||||
"numinlets" : 1,
|
||||
"numoutlets" : 0,
|
||||
@@ -2612,7 +2440,7 @@
|
||||
"box" : {
|
||||
"comment" : "ARGB/RGBA/AHSL/HSLA matrix output",
|
||||
"id" : "obj-44",
|
||||
"index" : 0,
|
||||
"index" : 1,
|
||||
"maxclass" : "outlet",
|
||||
"numinlets" : 1,
|
||||
"numoutlets" : 0,
|
||||
@@ -2634,13 +2462,13 @@
|
||||
}
|
||||
, {
|
||||
"box" : {
|
||||
"comment" : "",
|
||||
"comment" : "bang, colormodeoutput, alpha_last, listoutput, auto, color_start, color_end, start, rotation, saturation, flip, gamma, type, dim, getcolor, reset",
|
||||
"id" : "obj-22",
|
||||
"index" : 0,
|
||||
"index" : 1,
|
||||
"maxclass" : "inlet",
|
||||
"numinlets" : 0,
|
||||
"numoutlets" : 1,
|
||||
"outlettype" : [ "" ],
|
||||
"outlettype" : [ "bang" ],
|
||||
"patching_rect" : [ 31.0, 11.0, 30.0, 30.0 ]
|
||||
}
|
||||
|
||||
@@ -3064,13 +2892,7 @@
|
||||
}
|
||||
|
||||
}
|
||||
],
|
||||
"dependency_cache" : [ {
|
||||
"name" : "jit.pass.mxe64",
|
||||
"type" : "mx64"
|
||||
}
|
||||
],
|
||||
"autosave" : 0
|
||||
]
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user