capture image from webcam using java

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • kanagarak
    New Member
    • Nov 2012
    • 1

    capture image from webcam using java

    In my java application i am using webcam to capture image and save into DB. this is working upto take 4 or 5 images after that ,its showing "Java Heap Space Error" below error

    java.lang.OutOf MemoryError: Java heap space
    at com.sun.media.B asicPlugIn.vali dateIntArraySiz e(BasicPlugIn.j ava:168)
    at com.sun.media.B asicPlugIn.vali dateData(BasicP lugIn.java:228)
    at com.sun.media.c odec.video.jpeg .NativeDecoder. process(NativeD ecoder.java:306 )
    at com.sun.media.B asicFilterModul e.process(Basic FilterModule.ja va:322)
    at com.sun.media.B asicModule.conn ectorPushed(Bas icModule.java:6 9)
    at com.sun.media.B asicOutputConne ctor.writeRepor t(BasicOutputCo nnector.java:12 0)
    at com.sun.media.S ourceThread.pro cess(BasicSourc eModule.java:72 9)
    at com.sun.media.u til.LoopThread. run(LoopThread. java:135)


    Exception in thread "VFW Request Thread" java.lang.OutOf MemoryError: Java heap space
    at com.sun.media.p rotocol.vfw.VFW SourceStream.do Connect(VFWSour ceStream.java:3 45)
    at com.sun.media.p rotocol.vfw.VFW SourceStream.ru n(VFWSourceStre am.java:763)
    at java.lang.Threa d.run(Thread.ja va:619)



    after that i try to click means its showing some errors. i can't to find the problem. could any one help me please. Advance in thanks
  • yushulx
    New Member
    • Mar 2014
    • 2

    #2
    It's OutOfMemoryErro r. I think you forgot to release your image memory after saving it to DB. Could you post the code about how you capture image from webcam?

    Comment

    • Frinavale
      Recognized Expert Expert
      • Oct 2006
      • 9749

      #3
      It would help people to give you an answer to your question if you posted the code that causes the error.

      Comment

      Working...