nbb

Benjamin 2022-09-14T10:52:02.030609Z

Hi, do you know why, error with overload resolution failed in thread

Benjamin 2022-09-14T10:52:06.612649Z

(defonce ctx (js/window.AudioContext.))

(def panner (. ctx createStereoPanner))
(.. panner (connect ctx.destination))
;; this works

(defn ->panner [ctx left?]
  (let [panner (. ctx createStereoPanner)]
    (set! (.. panner -pan -value) (if left? -1 1))
    (.. panner (connect ctx.destination))
    panner))

;; error
(->panner ctx false)


;; => "#error {:message \"Failed to execute 'connect' on 'AudioNode': Overload resolution failed.\", :data {:type :sci/error, :line 1, :column 1, :message \"Failed to execute 'connect' on 'AudioNode': Overload resolution failed.\", :sci.impl/callstack #object[cljs.core.Volatile {:val ({:line 1, :column 1, :ns #object[Ao playground], :file nil, :sci.impl/f-meta {:name ->panner, :ns #object[Ao playground], :file \"playground.cljs\", :line 1, :column 1, :arglists ([ctx left?])}} {:line 1, :column 1, :ns #object[Ao playground], :file nil, :sci.impl/f-meta {:name ->panner, :ns #object[Ao playground], :file \"playground.cljs\", :line 1, :column 1, :arglists ([ctx left?])}})}], :file nil}, :cause #object[TypeError TypeError: Failed to execute 'connect' on 'AudioNode': Overload resolution failed.]}"

Benjamin 2022-09-14T10:52:29.976079Z

it is skittle

borkdude 2022-09-14T21:07:17.016019Z

Hey @benjamin.schwerdtner - I don't know this API. Do you think it's scittle related? We can talk in #scittle