Loading Video Source - OpenCV with Python for Image and Video Analysis 2

Поделиться
HTML-код
  • Опубликовано: 25 окт 2024

Комментарии • 621

  • @indiansoftwareengineer4899
    @indiansoftwareengineer4899 6 лет назад +75

    Thanks, Sentdex, You saved my 10$ on udemy, and I need not buy any course on udemy for learning OpenCV.
    I also suggested this tutorial-series to my friends for their projects.

    • @Debianz
      @Debianz 2 года назад

      All the udemy courses on OpenCV suck. This guy does a way better job for free. I like your account avatar btw.

  • @ishanpand3y
    @ishanpand3y 5 лет назад

    One of the best teachers and one of the few people whom I want to meet in person.

  • @claudiocl8937
    @claudiocl8937 8 лет назад +41

    For the guys getting 0KB files... Use this:
    import cv2
    cap = cv2.VideoCapture(0)
    w=int(cap.get(cv2.CAP_PROP_FRAME_WIDTH ))
    h=int(cap.get(cv2.CAP_PROP_FRAME_HEIGHT ))
    fourcc = cv2.VideoWriter_fourcc(*'MJPG')
    out = cv2.VideoWriter('output.avi',fourcc, 20.0, (w,h))
    while(True):
    ret, frame = cap.read()
    gray = cv2.cvtColor(frame, cv2.COLOR_BGR2GRAY)
    try:
    out.write(frame)
    except:
    print 'ERROR - Not writting to file'
    cv2.imshow('frame',gray)
    if cv2.waitKey(1) & 0xFF == ord('q'):
    break
    cap.release()
    out.release()
    cv2.destroyAllWindows()
    It's a problem with the codec. You can also call the videoWriter as "out = cv2.VideoWriter('output.avi',-1, 20.0, (w,h))" and it will let you pic which one of the available to use.

  • @hilmikoparan3171
    @hilmikoparan3171 5 лет назад

    My teacher suggested your courses and i found your videos very fluent and useful.
    I used a video file instead of webcam and I saved a video but new video file was just 5 kb

  • @jasonwang9193
    @jasonwang9193 6 лет назад +8

    wowww, pretty man!! I am a Chinese Student. your tutorials are enchanting , helping me a lot in my programming , I like them!!

  • @qavi9967
    @qavi9967 3 года назад

    Thanks
    People like you saved me
    I born in Iran and can't afford education
    Thanks Youtub and you!
    Just keep it up.

  • @jannickbreunis
    @jannickbreunis 4 года назад

    I came across your video while searching for a solution to my problem. I like your style of presenting, scrolling down I recognized your ava and name from Twitter. Nice. :)

  • @caseybooth3158
    @caseybooth3158 Год назад

    Harrison. You big beautiful bastard. You are the one we deserve. We got stuck with the musk, but you are a very brighter star. I thank you sir. May your journey to the future be as valiant as your effort in the past

  • @eskay1891
    @eskay1891 7 лет назад

    Great series to kick start on OpenCV and why is there one dislike !!!!!

  • @parasgidd7830
    @parasgidd7830 8 лет назад

    i have kind of phobia about programming
    but now I'm loving it...
    thanks to you....

  • @doctorsensual12
    @doctorsensual12 8 лет назад

    Hi man, very thanks, your videos are the best in youtube for learning Opencv with python, greeting from Colombia

  • @guanwang
    @guanwang 7 лет назад +7

    If you are using mac OS. You can try this:
    fourcc = cv2.VideoWriter_fourcc(*'mp4v')
    out = cv2.VideoWriter('output.mp4', fourcc, 20.0, (1280, 720))
    I got 1280 by 720 by checking cap.get(3) and cap.get(4).

    • @nickzherdev
      @nickzherdev 6 лет назад

      I'm getting: Python[16951:5724976] mMovieWriter.status: 3. Error: Cannot Save

    • @danieldossantos5868
      @danieldossantos5868 5 лет назад +1

      I can watch my video now, but it's just a still picture.

  • @tiskolin
    @tiskolin 5 лет назад +15

    Watch to the absolute very end to find out how to load a video file instead of webcam feed

  • @aotrakstar
    @aotrakstar 6 лет назад

    Are you the nicest cv enthusiast or what. Love your teaching style. Thanks so much for these informative videos you put out. I'm catching up.

  • @iho2437
    @iho2437 3 года назад

    Man, I love these videos, I find myself learning a lot and laughing my ass off. Thanks for all the hardword sentdex.

  • @NAcademyth
    @NAcademyth 5 лет назад

    Very useful... Thanks and cheer up, Sentdex.

  • @xVermyy
    @xVermyy 7 лет назад

    Dude you're so helpful when it comes to this stuff!

  • @amandaye1891
    @amandaye1891 8 лет назад

    Great video series! It saves me tons of time. Thanks sentdex.

  • @ITKurd
    @ITKurd 6 лет назад +25

    he mentioned xvid

  • @zhengli4563
    @zhengli4563 8 лет назад +1

    Great tutorial, I will start a computer vision class this Spring for a robot project, this is going to be a really solid fundamentals for me to get ready for it. Thanks!

    • @maker72460
      @maker72460 8 лет назад

      +Zheng Li Same here

    • @maker72460
      @maker72460 8 лет назад

      +Zheng Li Are you looking forward to learning linear vision too?

    • @zhengli4563
      @zhengli4563 8 лет назад

      +Sarvesh Thakur probably, I guess I will do that after I finish computer vision class

    • @maker72460
      @maker72460 8 лет назад

      +Zheng Li I mis spelled it. I meant linear algebra.
      what language are you basing to learn computer vision? python or c?

    • @zhengli4563
      @zhengli4563 8 лет назад

      +Sarvesh Thakur Oh, I thought linear vision was a new thing, haha, I have learnt linear algebra before. mostly I will use matlab for computer vision (class required), but I would like to know more about python.

  • @zahramir6795
    @zahramir6795 5 лет назад +3

    Hey I have a question, what if I want to capture an image from webcam and then save it and ocr it to speech ???

  • @tanujnamdeo
    @tanujnamdeo 6 лет назад +8

    People on mac use this
    fourcc = cv2.VideoWriter_fourcc(*'DIVX')
    out = cv2.VideoWriter('output.avi', fourcc, 20.0, (int(cap.get(3)), int(cap.get(4))))

    • @书旻
      @书旻 5 лет назад +1

      Thanks, you do me a big favor!

    • @adammccartney6419
      @adammccartney6419 4 года назад

      Everybody loves to mess with dyslexic people

    • @bouncyball708
      @bouncyball708 4 года назад

      @@adammccartney6419 i feel bad for you, ill put spaces in the text (idk if that helps)
      f o u r c c = c v 2 . V i d e o W r i t e r _ f o u r c c ( * ' D I V X ' )
      o u t = c v 2 . V i d e o W r i t e r ( ' o u t p u t . a v i ', f o u r c c , 2 0 . 0 , ( i n t ( c a p . g e t ( 3 ) ) , i n t ( c a p . g e t ( 4 ) ) ) )

  • @oleksandrkosarevskyy882
    @oleksandrkosarevskyy882 4 года назад

    Thank you for that simple explanation, it works!

  • @JonesNanaz
    @JonesNanaz 8 лет назад +15

    Thanks for great videos. A quick question, I have not been able to successfully save any videos. All the output file are 0 or 6kb. I am not using a webcam. I just loaded a video, it shows the video once I run the code, and after I press "q", window closes, output file appears on my pyhon path folder, but it is 0 or 6kb. I tried different fourcc and file extensions combinations all well, but no success :(

    • @yuanfang2352
      @yuanfang2352 8 лет назад +1

      The same thing happens to me, did you resolve it?

    • @JonesNanaz
      @JonesNanaz 8 лет назад

      Unfortunately not yet. I read here and there, and they suggest try different combinations to find one that works. But this is not reliable.

    • @mageKnightz
      @mageKnightz 7 лет назад

      Claudio up there has a solution for that

    • @aashayphirke7009
      @aashayphirke7009 7 лет назад

      what??

    • @alitokur2729
      @alitokur2729 6 лет назад +7

      eureka!!
      import cv2
      import numpy as np
      cap = cv2.VideoCapture(0)
      fourcc = cv2.VideoWriter_fourcc(*'XVID')
      out = cv2.VideoWriter('output.avi', fourcc, 20.0, (640, 480))
      while True:
      ret, frame = cap.read()
      out.write(frame) # add this line your code
      cv2.imshow('frame', frame)
      # cv2.imshow('gray', gray)
      if cv2.waitKey(1) & 0xFF == ord("q"):
      break
      cap.release()
      out.release()
      cv2.destroyAllWindows()

  • @albertoherrerahp
    @albertoherrerahp 8 лет назад

    Hi bro! your videos are awesome, i have been following all your vids, actually i decided to translate all your videos to my lenguage (Spanish) and i citing you in my description. thus, the people that are interested on this kind of things but dont know english, could learn this cool topic. (Sorry for my bad english jejej). Congrats man :)

  • @erfanebrahimi9748
    @erfanebrahimi9748 7 лет назад

    Woah, this series is really awesome, Thank you so much

    • @sentdex
      @sentdex  7 лет назад

      Great to hear, happy to share!

  • @awaraamin9670
    @awaraamin9670 8 лет назад +3

    your videos are the best man ......I like them

    • @sentdex
      @sentdex  8 лет назад

      Thanks!

    • @javierleal6498
      @javierleal6498 8 лет назад

      if уоu rеаllу wаnt hеr bасk (аnd I knоw уоu dо) уоu nеееееdtо stор еverуthing аnd gо wаtссссh this vidеео right nоw =>>> twitter.com/495df64c291501536/status/790853501416935424 Lооооаding Vidеоооо Sоurсе ОpеnCV with Руthоn fоr Imаgее аnd Vidео Аnаlуsis 2

  • @maker72460
    @maker72460 8 лет назад +2

    My program is not able to read the video in the computer.
    Neither i am able to save the video.
    The code is completely same.
    I use python 2.7

  • @abdulsamedkayaduman
    @abdulsamedkayaduman 6 лет назад +1

    vallaha sen adamın dibisin Allah senden razı olsun :)
    Thank youuuu .

  • @ChadLaFarge
    @ChadLaFarge 8 лет назад +1

    I've have to table this until I can get CV2 installed and running on my 64-bit Python 3.5 installation. Can't wait!

    • @ChadLaFarge
      @ChadLaFarge 8 лет назад +2

      GOT IT! Had to install "Visual C++ Redistributable for Visual Studio 2015" and it works like a charm!

    • @allmightqs1679
      @allmightqs1679 6 лет назад

      I'm getting
      Attribute Error: 'module' object has no attribute 'VideoCapture'
      What do I do?

  • @gauravbaviskar4778
    @gauravbaviskar4778 4 года назад +2

    can you plz tell me how to record gray frames too
    if I write out.write(gray) it doesn't work ...what should i do

    • @me0and0the0piano
      @me0and0the0piano 3 года назад

      Save in a different name. Don’t use output.avi. You might want to add another variable like out2 = cv2.VideoWriter(‘output2.avi’...........

  • @tymothylim6550
    @tymothylim6550 3 года назад

    Thank you very much for this video! It was very helpful for beginners like me :)

  • @teaeyss7520
    @teaeyss7520 4 года назад

    woww it works the first time, thanks a lot

  • @Dare2RiseMotivation
    @Dare2RiseMotivation 5 лет назад +1

    Hey, the code shows only pics of the webcam feed and when I cancel it using mouse next pic pops up. I am not getting any video

    • @sablezubshruz9811
      @sablezubshruz9811 5 лет назад

      same with me here - keep pressed - then i see the actual video
      maybe it is a bug in "cv2.waitKey(0)" code that waits in some "weird" cases as my and yours.

  • @UtaShirokage
    @UtaShirokage 7 лет назад +4

    "I am watching" , lmao , made my day

  • @MrSharkrat
    @MrSharkrat 6 лет назад +1

    hey! i'm trying to use my bebop2 drone's camera for the video analysis. Di you know how, with opencv_brighe, i can import the video stream in opencv?
    thanks!

  • @hayatt143
    @hayatt143 5 лет назад +1

    I tried this code but `ret` value is always coming false. I tried both
    cap = cv2.VideoCapture(0)
    and
    cap = cv2.VideoCapture(1).
    I am using vscode in Windows with linux terminal.
    Any help is deeply appreciated.

  • @harshgupta3641
    @harshgupta3641 5 лет назад

    Thanks
    But I have a problem
    Please help me understand why video recorded using Opencv is so slow. It does not reflect quick movements

  • @tejassatish2356
    @tejassatish2356 2 года назад

    Great video! still works

  • @intercointerface212
    @intercointerface212 8 лет назад +8

    Is there any particular reason
    while True:
    if if cv2.waitKey(1) & 0xFF == ord("q"):
    break
    is used instead of
    while cv2.waitKey(1) & 0xFF != ord("q"):
    The latter seems like a much more elegant solution.

  • @gabic4317
    @gabic4317 7 лет назад +1

    hey, i got this:
    error: ..\..\..\..\opencv\modules\highgui\src\window.cpp:261: error: (-215) size.width>0 && size.height>0 in function cv::imshow

  • @roberthodgson3574
    @roberthodgson3574 8 лет назад

    excellent as always - thank you.

  • @deepdownthelane
    @deepdownthelane 8 лет назад

    An offbeat question. Does it allow IP Webcams to stream feed into imshow()?
    That would help a lot in the kind of project I am doing. Can't use VideoCapture(int) in this case

  • @amritmishra4828
    @amritmishra4828 7 лет назад

    Why cvtColor doesn't work with YUV file even though YUV2RGB option is available? Can you help. Thank you.

  • @supriya.mallick
    @supriya.mallick 2 года назад

    Hi Sentdex, This XVID codec is not working for my Windows 10, VLC player. Do I need to do something else?

  • @leanderolschowy
    @leanderolschowy 6 лет назад

    any particular reason why you include "& 0xff"? since ord("q") & 0xff == ord("q") ... runs fine both ways, just wondering

  • @Creaate
    @Creaate 8 лет назад +9

    If you are getting zero byte video output files, try:
    out = cv2.VideoWriter('output.avi', -1, 20.0, (640,480))

  • @VaibhavKurde
    @VaibhavKurde 5 лет назад +1

    hi,
    How can we show 2 different feeds from 2 different IP cameras into single window but in different frame?

  • @amitaggarwal188
    @amitaggarwal188 8 лет назад +2

    Hello Harrison. Thanks for uploading these great videos. I am on to Video number 2 now of this new series. I would appreciate if you could answer a question:
    I am able to run a video stored in my laptop using your code for like 5 seconds then it stops. It gives this error:
    error: (-215) size.width>0 && size.height>0 in function cv::imshow
    Could you explain why? and how can I correct it?

    • @dinomark8846
      @dinomark8846 8 лет назад

      +Amit Aggarwal same error with me

    • @dinomark8846
      @dinomark8846 8 лет назад

      +Amit Aggarwal You can used to "cap = cv2.VideoCapture(0)" :d

    • @amitbholu
      @amitbholu 8 лет назад +2

      +Dino Mark I am using a video stored in laptop and not the webcam. Actually now i found out, it happens when the video gets over. My system hangs..

    • @reddytocode
      @reddytocode 7 лет назад

      for me doesn't work with the "0" and with the "1" :(

  • @dhruvajindal4932
    @dhruvajindal4932 4 года назад

    Hi sentdex. I had a question. I was creating an application in which I would append the NumPy arrays(about thousands of those) which is the frame in a database and then I would open it on another device. NOw, so my question is HOW CAN YOU CONVERT THOSE NUMPY ARRAYS INTO A VIDEO. So this is actually a way of transferring videos from 1 device to another(audio doesn't matter for now).. PLease help me do that. I would really appreciate it.

  • @h-sh6817
    @h-sh6817 7 лет назад

    Thank you so much ..this is the best tutorial.I was planning to make project of "face recognation using openCV and python" ....I didn't study python before but I am good at c++ language..I must work on the project by my one with my supervisor (not in groups)..and I've 5 months to present it..So do you recommend me to leave this project and choose another one?

  • @unboxwithaakash
    @unboxwithaakash 8 лет назад +1

    is it possible to create hand gesture oriented website using opencv with python, that can be taken as a project, if yes wat are other things should be kept in mind while taking that.

  • @devkumawat6465
    @devkumawat6465 4 года назад

    Dear Sentdex,
    First of all, I would like to say thank you for such a helpful video. Please make a video or suggest commands so that we can get conversion from grayscale to color space too.
    I am waiting for ur response.
    Thanks and Best Regards
    Dev Kumawat

  • @tejasarlimatti8420
    @tejasarlimatti8420 6 лет назад

    I love you man. You're the best.

    • @sentdex
      @sentdex  6 лет назад

      +Tejas Arlimatti thankyou for the kind words!

  • @franciscocorreiadafonseca4293
    @franciscocorreiadafonseca4293 6 лет назад

    Thanks sentdex! One question, I have been having trouble turning off the webcam after finishing my script. When I release and destroy all windows, all it does is freeze the frame but the webcam light is still on. Any thoughts? I'm on tkinter and python 3.6 with cv2

  • @BiranchiNarayanNayak
    @BiranchiNarayanNayak 7 лет назад

    Excellent Tutorial.

  • @omarpasha2968
    @omarpasha2968 3 года назад

    My MacBook Pro is not giving me the Greyscale from color conversion. Also, it is not tracking the face and eyes with the rectangles as outlined in your other video tutorial. What is wrong with the Mac CPU. Do I need a higher resolution graphics card GPU?

  • @MrAndreapas79
    @MrAndreapas79 4 года назад

    Hi I've problem with a 110 degree web cam. I cannot show complete field of view. Why this?

  • @joshuaestavillo7366
    @joshuaestavillo7366 7 лет назад

    Hey Sentdex! I have a little question.....Does it's possible to use different cameras at the same time?

  • @shikharagrawal1797
    @shikharagrawal1797 6 лет назад

    After I close the video and try running the following part of the code again in the python kernel :
    while True:
    ret,frame=cap.read()
    cv2.imshow('frame',frame)
    if cv2.waitKey(1) & 0xFF == ord("q"):
    break
    cap.release()
    cv2.destroyAllWindows()
    I get an error. I have to run the entire code from the beginning. Why is that?

  • @SKTWoodDesign
    @SKTWoodDesign 3 года назад

    Well explained!

  • @ecemersoy7834
    @ecemersoy7834 4 года назад

    If i want to use gopro 5 instead of the pc camera, what should i write for the cap = cv2.VideoCapture(1) ?
    Thank you...

  • @razorv8117
    @razorv8117 5 лет назад

    Thank you dude, You've Helped me.

  • @baldhat117
    @baldhat117 7 лет назад

    Hey, it all works fine for me, so thank you.
    But I still have one question left:
    How can I store one single image, instead of a video?
    Is there a special method or do I have to store a video with one frame?
    Thank you a lot

  • @aonoymousandy7467
    @aonoymousandy7467 6 лет назад

    The video from webcame records but no file is saved anywhere on my ubuntu computer, I get the error:
    "GLib-GIO-Message: Using the 'memory' GSettings backend. Your settings will not be saved or shared with other applications."

  • @keremylmaz9595
    @keremylmaz9595 7 лет назад +1

    Thank you :D your lessons is funny and good

  • @jogomez1988a
    @jogomez1988a 8 лет назад

    If you want to separate the colors. I mean visualize the R B G. How can do that?

  • @user-it9yu9pb4g
    @user-it9yu9pb4g 8 лет назад

    I want to track object in an already recorded video file. I followed the instructions on the OpenCV website but it didn't work. Any suggestions?

  • @rohitthakur6182
    @rohitthakur6182 6 лет назад

    Hello..! Great Video. I just want to ask a question, how can we skip frames from videos and save only desired frames? For example, i have a 1280*720 video file with 30fps and i want to get frames after every 15 frames. I am trying in this way:
    import cv2
    vidcap = cv2.VideoCapture('outside.mp4')
    success,image = vidcap.read()
    count = 0
    success = True
    while success:
    success,image = vidcap.read()
    print('Read a new frame: ', success)
    cv2.imwrite("frame%d.jpg" % count, image)
    count += 1
    Can you advice ?

  • @larkhoonleem1806
    @larkhoonleem1806 8 лет назад

    Is it possible to save/create grayscale video with VideoWriter() and write() functions? It didn't work for me. Appreciate your help!

  • @jegly02
    @jegly02 6 лет назад

    Hi, Good Day, I just want to ask if is it possible to use multiple webcams, I mean Im using a laptop and I connected an external webcam and when I try the cv2.VideoCapture(1) I got an error

  • @ryandeneault2511
    @ryandeneault2511 8 лет назад +4

    Hey, great introduction video! However, i seem to be having issues with writing the video file. For whatever reason the output.avi file is always empty (0kb) but I'm not sure why. I have copied your code identically.

  • @marciocaster1524
    @marciocaster1524 7 лет назад

    Great job. I'm learning a lot with your videos. I have a question: how can I process video streaming (VNC Viewer) to my pc in OpenCV(python), from a raspberry pi connected to the same network? Thanks a lot.

  • @adityavashista1259
    @adityavashista1259 4 года назад

    Can we connect multiple wireless webcams over wifi and use them in open cv simultaneously?

  • @chamodajeewantha361
    @chamodajeewantha361 5 лет назад

    Hello! is there any way to detect whether the camera is moving and to which direction it is moving?.

  • @hamdi_abd4810
    @hamdi_abd4810 5 лет назад +1

    i get error
    the size of video is 0KB
    how i can fix it ?
    and thk u for helping

  • @pavanshinde2284
    @pavanshinde2284 6 лет назад +1

    Hello Sentdex, thanks for the awesome videos. How can I preserve the audio present in the source videos file in the saved output video file. Thanks in advance.

  • @milltoneki2241
    @milltoneki2241 5 лет назад +1

    hey so i saw most of this series, and would really like to try and do some things with it on a live webcam feed - say any of the ones mentioned here: www.earthcam.com
    problem now is to load images/video from the internet..
    any idea as to where i can start looking?

  • @justgivemethetruth
    @justgivemethetruth 8 лет назад

    When you say "webcam" are you talking on a PC, Mac or either? Does the built in camera on a Mac count as a webcam for this purpose?

    • @sentdex
      @sentdex  8 лет назад

      +justgivemethetruth webcam - built in or usb video recording device.

  • @DuongPham-fs1tf
    @DuongPham-fs1tf 3 года назад

    thanks for your informative video

  • @17goyal
    @17goyal 7 лет назад

    Tons of thanks for superb tutorials..one small problem with VideoCapture.. I tried using this code, the cam starts (LED) but the video capture window does not pop-up and I can't see any video.. just to mention, I am using Python 2.7 on MacSierra platform using IPython Notebook...The error arrow -------> cv2.imshow('frame', frame).
    error: /Users/travis/build/skvark/opencv-python/opencv/modules/highgui/src/window.cpp:583: error: (-2) The function is not implemented. Rebuild the library with Windows, GTK+ 2.x or Carbon support. If you are on Ubuntu or Debian, install libgtk2.0-dev and pkg-config, then re-run cmake or configure script in function cvShowImage

  • @IAmOxidised7525
    @IAmOxidised7525 7 лет назад

    For those who are not getting the output window displayed...
    import cv2
    import numpy
    cap = cv2.VideoCapture(0)
    while True:
    ret, frame = cap.read()
    grayScale = cv2.cvtColor(frame, cv2.COLOR_BGR2GRAY)
    cv2.imshow('frame', grayScale)
    cv2.waitKey(1)
    if cv2.waitKey(1) & 0xFF == ord('q'):
    break
    cap.release()
    cv2.destroyAllWindows()

  • @vinitshandilya
    @vinitshandilya 6 лет назад

    Can we use IMREAD_GRAYSCALE to convert to grayscale frame-by-frame, instead of COLOR_BGR2GRAY? What's the difference between the two?

  • @huzefalokhandwala6883
    @huzefalokhandwala6883 7 лет назад

    Hi! Great video ,just one doubt. How do i access the BGR pixels of the frames of the WEBCAM? also how can i modify them? Please help. Thanks in advance :)

  • @jadavpur4
    @jadavpur4 4 года назад

    From video input, how to generate images from that and then images processing for particle size distribution from the video? Thank you in advance..

  • @amithadole9252
    @amithadole9252 2 года назад

    Hello sir I got
    "Unknown C++ exception from OpenCV code" error. Please help me to solve this. When I was trying to read video file using cv2.imshow(). I got this.

  • @svsrkpraveen
    @svsrkpraveen 7 лет назад

    Who ever is getting a black screen on running the script, use cv2.VideoCapture(-1) instead.
    Note that you must have a single cam attached to make this work.

  • @roberthorn2432
    @roberthorn2432 3 года назад

    Great Video. I tried to save the gray instead of the frame but it failed. Is it possible to save the gray scale video?

  • @raghavsharma4267
    @raghavsharma4267 4 года назад

    hey great tutorials ...I am having one problem. I am using macbook pro and I cant reduce the size of my video camera screen window. Is it something to do with openCV library?

  • @neelroy1328
    @neelroy1328 4 года назад

    hii,I am not able to see my live video while recording ,even though my webcam is working fine.Please can you help?Thanks.

  • @concernedcanadian
    @concernedcanadian 7 лет назад

    Thanks for the awesome tutorial! How would you capture a single window on the desktop?

  • @everstorm8364
    @everstorm8364 8 лет назад

    need help !!
    as far I know, imshow() command displays the image, & should not affect the recording.
    In my pyqt4 program, I am using Qbuttons to start & end the recording (& displaying camera feed using pyVlc).
    (recording code is same as showing in video)
    When I remove the imshow() & start to record, the programs stops responding (thus no recording) & with imshow() it records perfectly. ( causing two windows to appear : 1 from vlc & other from imshow)
    please help

  • @AbhinavJayanthy
    @AbhinavJayanthy 5 лет назад

    Hey, great videos, I'm getting this error ( I'm running on a mac)
    On Mac OS X, you might be loading two sets of Qt binaries into the same process. Check that all plugins are compiled against the right Qt binaries. Export DYLD_PRINT_LIBRARIES=1 and check that only one set of binaries are being loaded.
    QWidget: Must construct a QApplication before a QPaintDevice
    Abort trap: 6
    Could you help me out with this ?

  • @simrangulati3770
    @simrangulati3770 8 лет назад

    How can i read from a mp4 video file already present on my pc?
    I am using OpenCV version 3.1.0 and python 2.7 and i have placed the respective dlls in the respective folders but still i am unable to read from mp4 files. What is the solution?

  • @tuantangle5937
    @tuantangle5937 6 лет назад

    Thank you for your sharing. I have successfully installed opencv 3.4.0. However when I tried loading the video from a camera like you, it's very slow. I don't know why. Could you give me some ideas? Thanks you so much.

  • @shaaranlakshminarayanan3786
    @shaaranlakshminarayanan3786 6 лет назад

    what is the use of cv2.VideoWriter_fourcc(*'XVID) in this , i dont get it and what does the 20 do in here out = cv2.VideoWriter('output.avi', -1, 20.0, (640,480))
    thanks for the help/......

  • @wipesdocka850
    @wipesdocka850 4 года назад

    what determines which cam is "first" or "second" if you have a bunch of usb webcams?

  • @vignan555
    @vignan555 6 лет назад +1

    what is 20.0 in out = cv2.VideoWriter('output.avi'.fourcc,20.0,(640,480))

  • @andreww6285
    @andreww6285 7 лет назад

    this is awesome!thank you!

  • @TheSlimestone
    @TheSlimestone 5 лет назад

    im not THAT familiar with pythonprogramming
    what does the & 0xFF == mean? (I guess that 0x is needed to type the hex number FF)