Moe82 / Webcam-Monitor

MIT License
1 stars 0 forks source link

test webcam.py on different OS #4

Open Moe82 opened 3 years ago

Moe82 commented 3 years ago

Note: Please wait until issue #1 is closed.

Get webcam.py to run as expected on MacOS, Linux, Unix, and Windows. If everything checks out, please let me know and I'll close the issue.

afifabroory commented 3 years ago

Hi :wave: I tried on Linux distro Ubuntu, i have an error when webcam.record_video() is execute...

Error messages: ASSERT: "false" in file qasciikey.cpp, line 501 Aborted (core dumped)

but i tried in debugger pdb it's work without any error... i don't know what the problem is... kinda wierd maybe the problem it's just on my pc...

and i just curious, at line 71 are you doing comparison operator or bitwise operator? also, why you put time.sleep() 10 sec. at line 84?

also can i do pull requests?

i am sorry, if my english is not good also i am sorry if i am wrong.... i am still learning :)

Moe82 commented 3 years ago

Hi, @afifabroory !

I tried on Linux distro Ubuntu, i have an error when webcam.record_video() is execute...

Can you please try removing lines 71-72 and see if it fixes your problem? Those lines really are not needed since the user would be away from his machine (in theory) when the record_video function is called.

and i just curious, at line 71 are you doing comparison operator or bitwise operator?

bitwise operator.

also, why you put time.sleep() 10 sec. at line 84?

The point of this delay is to allow the user time to leave the room. Without line 84, the users movement would trigger the record_video function. I bet there's a more elegant solution, but that's the best I was able to come up with when I wrote the code.

also can i do pull requests?

Absolutely man, go for it.

  • i fixing your indentation
  • fix coding convention
  • add .gitignore file
  • and change some code
  • also can i remove line 81 - 85?

Regarding line 81-85, I included them for just testing purposes. I'm planning to add a GUI once I fix the issues and figure out which features to include. So those lines won't be needed in the future. For the sack of having clean code, lets take them out.

i am sorry, if my english is not good also i am sorry if i am wrong.... i am still learning :)

Thats ok man, I understood everything you said perfectly =)

By the way, did you discover this repo over at reddit.com?

afifabroory commented 3 years ago

Can you please try removing lines 71-72 and see if it fixes your problem? Those lines really are not needed since the user would be away from his machine (in theory) when the record_video function is called.

Yes, it's fix the problem, but now i had a new problem :laughing: Screenshot_2020-11-30_11-44-17 but it's okay, the problem won't affect the output video.

The point of this delay is to allow the user time to leave the room. Without line 84, the users movement would trigger the record_video function. I bet there's a more elegant solution, but that's the best I was able to come up with when I wrote the code.

Maybe, i suggest you separate, file for testing purposes and main code.

By the way, did you discover this repo over at reddit.com?

No, i discover from goodfirstissues.com