Copiando o repositório do Alexandre

This commit is contained in:
fls committed 2026-09-17 17:37:20 -03:00
1 parent a3e604697b
commit 0ab8836265
363 files changed
+27249

No files matched your search

@@ -0,0 +1,39 @@
{
"source": "JSON",
"data": "BLOCK",
"version": "0.0.1",
"type": "javascript.background",
"language": "javascript",
"extension": "webaudio",
"help": "Change Background color",
"label": "Background",
"color": "#24C1D3",
"group": "Interface",
"codes": [
{
"name": "declaration",
"code": "\nvar $port[rgb]$ = function(value){\n document.body.style.backgroundColor = value;\n return true;\n };\n"
},
{
"name": "onload",
"code": "\n$port[rgb]$('$prop[color]$');\n\n"
}
],
"properties": [
{
"name": "color",
"label": "Color",
"value": "#F00",
"format": "FF00FF",
"type": "Color"
}
],
"ports": [
{
"conn_type": "input",
"name": "rgb",
"label": "RGB COlor",
"type": "javascript.color"
}
]
}
@@ -0,0 +1,58 @@
{
"source": "JSON",
"data": "BLOCK",
"version": "0.0.1",
"type": "javascript.arithmetics.inc",
"language": "javascript",
"extension": "webaudio",
"help": "Increment",
"label": "Increment",
"color": "#24C1D3",
"group": "Interface",
"codes": [
{
"name": "declaration",
"code": "\n// block_$id$ = $label$\nvar block_$id$_value = $prop[value]$;\nvar block_$id$_step = $prop[step]$;\nvar $port[float]$ = [];\n\nvar $port[count]$ = function(value){\n block_$id$_value += block_$id$_step;\n for (var i = 0; i < $port[float]$.length ; i++){\n $port[float]$[i](block_$id$_value);\n }\n return true;\n };\n\nvar $port[value]$ = function(value){\n block_$id$_value = value;\n return true;\n };\n\n"
}
],
"properties": [
{
"name": "value",
"label": "Value",
"type": "Float",
"lower": 0,
"upper": 20000,
"step": 1,
"value": 1
},
{
"name": "step",
"label": "Step",
"type": "Float",
"lower": -20000,
"upper": 20000,
"step": 1,
"value": 1
}
],
"ports": [
{
"conn_type": "output",
"name": "float",
"label": "Float",
"type": "javascript.float"
},
{
"conn_type": "input",
"name": "count",
"label": "Count",
"type": "javascript.float"
},
{
"conn_type": "input",
"name": "value",
"label": "Value",
"type": "javascript.float"
}
]
}
@@ -0,0 +1,66 @@
{
"source": "JSON",
"data": "BLOCK",
"version": "0.0.1",
"type": "javascript.metronome",
"language": "javascript",
"extension": "webaudio",
"help": "Metronome",
"label": "Metronome",
"color": "#24C1D3",
"group": "Interface",
"codes": [
{
"name": "declaration",
"code": "\n// block_$id$ = Float Value\nvar block_$id$_timeout;\nvar block_$id$_value = $prop[value]$;\nvar block_$id$_time = $prop[time]$;\nvar $port[float]$ = [];\n\nvar $port[start]$ = function(value){\n timeout_$id$_value();\n return true;\n };\n\nvar $port[stop]$ = function(value){\n if (value > 0) {\n clearTimeout(block_$id$_timeout);\n }\n return true;\n };\n\n"
},
{
"name": "execution",
"code": "\nfunction timeout_$id$_value(){\n for (var i = 0; i < $port[float]$.length ; i++){\n $port[float]$[i](block_$id$_value);\n }\n block_$id$_timeout = setTimeout(timeout_$id$_value, block_$id$_time);\n};\n"
},
{
"name": "onload",
"code": ""
}
],
"properties": [
{
"name": "value",
"label": "Value",
"type": "Float",
"lower": 0,
"upper": 20000,
"step": 1,
"value": 1
},
{
"name": "time",
"label": "Time (ms)",
"type": "Float",
"lower": 0,
"upper": 20000,
"step": 1,
"value": 1000
}
],
"ports": [
{
"conn_type": "output",
"name": "float",
"label": "Float",
"type": "javascript.float"
},
{
"conn_type": "input",
"name": "start",
"label": "Start",
"type": "javascript.float"
},
{
"conn_type": "input",
"name": "stop",
"label": "Stop",
"type": "javascript.float"
}
]
}
@@ -0,0 +1,52 @@
{
"source": "JSON",
"data": "BLOCK",
"version": "0.0.1",
"type": "javascript.random",
"language": "javascript",
"extension": "webaudio",
"help": "Random",
"label": "Random",
"color": "#24C1D3",
"group": "Interface",
"codes": [
{
"name": "declaration",
"code": "\n// block_$id$ = $label$\nvar block_$id$_min = $prop[min]$;\nvar block_$id$_max = $prop[max]$;\nvar $port[float]$ = [];\n\nvar $port[generate]$ = function(value){\n value = Math.floor((Math.random() * (block_$id$_max - block_$id$_min)) + block_$id$_min);\n for (var i = 0; i < $port[float]$.length ; i++){\n $port[float]$[i](value);\n }\n return true;\n };\n\n"
}
],
"properties": [
{
"name": "min",
"label": "Min",
"type": "Float",
"lower": -20000,
"upper": 20000,
"step": 1,
"value": 1
},
{
"name": "max",
"label": "Max",
"type": "Float",
"lower": -20000,
"upper": 20000,
"step": 1,
"value": 100
}
],
"ports": [
{
"conn_type": "output",
"name": "float",
"label": "Float",
"type": "javascript.float"
},
{
"conn_type": "input",
"name": "generate",
"label": "Generate",
"type": "javascript.float"
}
]
}