forked from rctoris/mjpegcanvasjs
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #12 from Techming/develop
V0.1.5 Add minified build file and fix type declaration file
- Loading branch information
Showing
7 changed files
with
660 additions
and
64 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,66 +1,63 @@ | ||
import EventEmitter2 from 'eventemitter2'; | ||
|
||
declare module '@techming/web-video-canvas' { | ||
interface ViewOptions { | ||
divID: string; | ||
width: number; | ||
height: number; | ||
host: string; | ||
port?: number; | ||
quality?: number; | ||
topic: string; | ||
overlay?: HTMLCanvasElement; | ||
refreshRate?: number; | ||
interval?: number; | ||
type?: string; | ||
} | ||
export as namespace WebVideoCanvas; | ||
export class Viewer extends EventEmitter2 { | ||
constructor(options: WebVideoCanvas.ViewOptions); | ||
width: number; | ||
height: number; | ||
host: string; | ||
port?: number; | ||
quality?: number; | ||
topic: string; | ||
overlay?: HTMLCanvasElement; | ||
refreshRate?: number; | ||
interval?: number; | ||
type?: string; | ||
canvas?: HTMLCanvasElement; | ||
image: typeof Image; | ||
|
||
interface MultiStreamViewerOptions { | ||
divID: string; | ||
width: number; | ||
height: number; | ||
host: string; | ||
port?: number; | ||
quality?: number; | ||
topics: [string]; | ||
labels?: [string]; | ||
defaultStream?: number; | ||
} | ||
|
||
class View extends EventEmitter2 { | ||
constructor(options: ViewOptions); | ||
width: number; | ||
height: number; | ||
host: string; | ||
port?: number; | ||
quality?: number; | ||
topic: string; | ||
overlay?: HTMLCanvasElement; | ||
refreshRate?: number; | ||
interval?: number; | ||
type?: string; | ||
canvas?: HTMLCanvasElement; | ||
image: typeof Image; | ||
draw(): void; | ||
changeStream(topic: string): void; | ||
} | ||
|
||
draw(): void; | ||
changeStream(topic: string): void; | ||
} | ||
export class MultiStreamViewer extends EventEmitter2 { | ||
constructor(options: WebVideoCanvas.MultiStreamViewerOptions); | ||
divID: string; | ||
width: number; | ||
height: number; | ||
host: string; | ||
port?: number; | ||
quality?: number; | ||
topics: [string]; | ||
labels?: [string]; | ||
defaultStream?: number; | ||
|
||
class MultiStreamViewer extends EventEmitter2 { | ||
constructor(options: MultiStreamViewerOptions); | ||
divID: string; | ||
width: number; | ||
height: number; | ||
host: string; | ||
port?: number; | ||
quality?: number; | ||
topics: [string]; | ||
labels?: [string]; | ||
defaultStream?: number; | ||
clearButton(): void; | ||
fadeImage(): void; | ||
} | ||
|
||
clearButton(): void; | ||
fadeImage(): void; | ||
} | ||
export interface ViewOptions { | ||
divID: string; | ||
width: number; | ||
height: number; | ||
host: string; | ||
port?: number; | ||
quality?: number; | ||
topic: string; | ||
overlay?: HTMLCanvasElement; | ||
refreshRate?: number; | ||
interval?: number; | ||
type?: string; | ||
} | ||
|
||
export { View, MultiStreamViewer }; | ||
export interface MultiStreamViewerOptions { | ||
divID: string; | ||
width: number; | ||
height: number; | ||
host: string; | ||
port?: number; | ||
quality?: number; | ||
topics: [string]; | ||
labels?: [string]; | ||
defaultStream?: number; | ||
} |
Large diffs are not rendered by default.
Oops, something went wrong.
Oops, something went wrong.