-
Notifications
You must be signed in to change notification settings - Fork 903
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
remake posenet results so they are now grouped into one single array
- Loading branch information
1 parent
9c44ab8
commit 1d9148e
Showing
2 changed files
with
6 additions
and
3 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,7 +15,9 @@ class ImageAndVideo { | |
this.videoReady = false; | ||
this.onVideoReady = () => { | ||
this.videoReady = true; | ||
this.waitingPredictions.forEach(i => this.predict(i.imgToPredict, i.num, i.callback)); | ||
if (this.waitingPredictions) { | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
cvalenzuela
Author
Member
|
||
this.waitingPredictions.forEach(i => this.predict(i.imgToPredict, i.num, i.callback)); | ||
} | ||
}; | ||
|
||
if (video instanceof HTMLVideoElement) { | ||
|
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 shouldn't really be a responsibility of this class...This class should just be loading a video and calling back when its done. Executing of waiting predictions should be done by whoever is consuming this and needs to wait for the callback.