Skip to content

Commit

Permalink
refactor(pixel): implement IPixelBuffer for PackedBuffer
Browse files Browse the repository at this point in the history
  • Loading branch information
postspectacular committed Jan 2, 2021
1 parent abd1ca8 commit 2dcbde5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/pixel/src/packed.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import {
BayerSize,
BlendFnInt,
BlitOpts,
IPixelBuffer,
Lane,
PackedChannel,
PackedFormat,
Expand Down Expand Up @@ -57,7 +58,7 @@ export const buffer = (
pixels?: UIntArray
) => new PackedBuffer(w, h, fmt, pixels);

export class PackedBuffer {
export class PackedBuffer implements IPixelBuffer<UIntArray, number> {
static fromImage(
img: HTMLImageElement,
fmt: PackedFormat,
Expand Down

0 comments on commit 2dcbde5

Please sign in to comment.