MCPcopy Create free account
hub / github.com/heygen-com/hyperframes / getContext

Method getContext

packages/sdk/src/adapters/iframe.test.ts:677–688  ·  view source on GitHub ↗
(_type: string)

Source from the content-addressed store, hash-verified

675 this.height = h;
676 }
677 getContext(_type: string) {
678 return {
679 drawImage() {},
680 getImageData() {
681 if (behavior === "tainted") {
682 throw new DOMException("Tainted canvases may not be exported.", "SecurityError");
683 }
684 const alpha = behavior === "opaque" ? 255 : 0;
685 return { data: new Uint8ClampedArray([255, 0, 0, alpha]), width: 1, height: 1 };
686 },
687 };
688 }
689 } as unknown as typeof OffscreenCanvas;
690 return () => {
691 if (orig === undefined) {

Callers 15

_doInitMethod · 0.80
uploadAndBlurMethod · 0.80
constructorMethod · 0.80
_doInitMethod · 0.80
uploadAndBlurMethod · 0.80
constructorMethod · 0.80
_doInitMethod · 0.80
uploadAndBlurMethod · 0.80
constructorMethod · 0.80
_doInitMethod · 0.80
uploadAndBlurMethod · 0.80
constructorMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected