shortes answer possible. for reaper lua script, make me a gfx knob
Jump to turn (13)
- 1shortes answer possible. for reaper lua script, make me a gfx knob
- 2now make me able to control the pointer of the knob with the mouse while holding
- 316: attempt to call a nil value (field 'atan2')
- 4make the knob minimum value -24 and the maximum value 24
- 523: attempt to call a nil value (field 'atan2')
- 6atan2 is deprecated
- 7make me a gfx script that mimcs a media explorer, showing the files of a directo
- 8-- Initialize graphics window gfx.init("Media Explorer", 300, 400, 0, 100, 100)
- 9-- Initialize graphics window gfx.init("Media Explorer", 300, 400, 0, 100, 100)
- 10-- Initialize graphics window gfx.init("Media Explorer", 300, 400, 0, 100, 100)
- 11shortest answer only. i want to know if a file is selected in the gfx window (i
- 12shortest answer only. i want to be able to drag the file into the arrangment, no
- 13shortest answer only. the behavior i want is this: when i select a file, if it i
- User
shortes answer possible. for reaper lua script, make me a gfx knob
- Assistantlua
gfx.init("Knob", 100, 100) local angle = 0 function draw_knob() gfx.clear = 0x333333 gfx.set(1, 1, 1) gfx.circle(50, 50, 30, 0) gfx.line(50, 50, 50 + 30 * math.cos(angle), 50 + 30 * math.sin(angle)) end function main() gfx.x, gfx.y = gfx.mouse_x, gfx.mouse_y if gfx.mouse_cap & 1 == 1 then local mx, my = gfx.mouse_x - 50, gfx.mouse_y - 50 angle = math.atan2(my, mx) end gfx.dest = -1 gfx.a = 1 draw_knob() gfx.update() reaper.defer(main) end main() - User