1 | initial version |
it's a typical python nooooooob error. you're blindly pasting other ppls code.
you have to add CHECKS,
if not cap.isOpened(): ...
VideoCapture will NEVER trow any exceptions on failure, so you HAVE to check manually
also, next time (can't help to say it -- please RESEARCH your problem, before asking anywhere, it'S the most prominent error happenig to python kids (they're all like you).
2 | No.2 Revision |
it's a typical python nooooooob error. you're blindly pasting other ppls code.
you have to add CHECKS,
if not cap.isOpened(): ...
if
not img is NONE: ...VideoCapture will NEVER trow any exceptions on failure, so you HAVE to check manually
also, next time (can't help to say it -- please RESEARCH your problem, before asking anywhere, it'S it's the most prominent error happenig to python kids (they're all like you).
3 | No.3 Revision |
it's a typical python nooooooob error. you're blindly pasting other ppls code.
you have to add CHECKS,
if not cap.isOpened(): ...
if not img is NONE: ...
VideoCapture will NEVER trow any exceptions on failure, so you HAVE to check manually
also, next time (can't help to say it -- please RESEARCH your problem, before asking anywhere, it's the most prominent error happenig to python kids (they're all like you).
4 | No.4 Revision |
it's a typical python nooooooob error. you're blindly pasting other ppls code.
you have to add CHECKS,
if not cap.isOpened(): ...
if not img is NONE: ...
VideoCapture will NEVER trow throw any exceptions on failure, so you HAVE to check manually