Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Slow Webcam Response

Community Beginner ,
Jul 20, 2013 Jul 20, 2013

I've been struggling with poor performance from my Logitech 9000 Pro webcam. My program takes snapshots of the video and saves them to the users hard drive. I need high resolution images so I'm going for 1280x720 which is the limit of this webcam. But it's so slow. The refresh rate is poor and movement looks blurry. I have another brand new $100 webcam from Logitech and it's better, but has issues at higher resolutions like 1080p just like the 9000 Pro. I'm ready to dump Logitech and go with Microsoft webcams. Maybe I'll have better luck. Does anyone have any suggestions. The simplest of code gives me the poor results so I don't think it's the code, but the webcam or driver or both or logitech. Lower resolutions are faster, but I need 720p out of this camera and 1080p out of the newer camera. Here's my code:

import flash.media.Video;

var myWidth:Number = 1280;

var myHeight:Number = 720;

var my_video:Video = new Video(myWidth,myHeight);

var my_cam:Camera = Camera.getCamera();

my_cam.setMode(myWidth, myHeight, 30);

my_video.attachCamera(my_cam);

addChild(my_video);

TOPICS
ActionScript
3.7K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Jul 22, 2013 Jul 22, 2013

It sounds to me like you have not installed the Logitech drivers. The cam will just work if you plug it in, but if you don't install the drivers you will get very poor perfomance. I use the 1920x1080 Logitech C920 for any webcam projects I do, and have had this same issue.

In fact, I just did a quick test with your code, and my C920 does 30fps no problem - even at 1920x1080 it was fine.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 22, 2013 Jul 22, 2013

Just saw your response. It's the Logitech C920 I'm having issues with as well, but the camera is incredible otherwise. All three logitech cameras I'm using use the exact same software and drivers so I've just been switching out trying different cameras. It recognizes them just fine.

However, when I use logitechs software to capture video, the camera is perfect. No delays whatsoever. So why does flash do so poorly with the same video in the same 1080p mode?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Jul 22, 2013 Jul 22, 2013

>>However, when I use logitechs software to capture video, the camera is perfect. No delays whatsoever. So why does flash do so poorly with the same video in the same 1080p mode?

That is odd. 1080 is working great for me in Flash, it's very smooth. I never even installed the Logitech software though, just the drivers, so I can't test any difference. What version of Windows - I'm running 64bit Windows 8.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 22, 2013 Jul 22, 2013

I'm using 64 bit Windows 8 as well on my laptop with an i3. I wonder if the logitech software is getting in the way somehow? Maybe I'll uninstall the software and just install the drivers and see what happens. So you're saying that on your 64 bit Windows 8 i3 computer your 1080p video from the C920 looks great in Flash with no delays?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 22, 2013 Jul 22, 2013

I've had some success dealing with this issue. First I turned on Level 2 Hardware Acceleration in the flash IDE which seems to have helped. Still can't use 1080p on an i3 laptop. I ran into the StageVideo object API. Looks great at first because the webcam might use direct hardware acceleration, but at the same time I also need to capture images from the video using BitMapData, etc and it looks like StageVideo cannot do that.

From Adobe StageVideo API:

The benefits to using a StageVideo object instead of the Video object are:

    Improved video display performance because of using hardware acceleration.

    Decreased CPU usage.

    Flexibility and creativity for development of content, such as video controls, that appears in front of the StageVideo object.

Is it safe to say that my users simply need a faster computer to handle 1080p video from a webcam? Like an i5 or i7? Is there something I'm missing? Does switching to Level 2 Hardware Acceleration provide a benefit to me like I'm thinking? Are the newer webcams talking to flash in a different way then they used to?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Jul 22, 2013 Jul 22, 2013

>.Still can't use 1080p on an i3 laptop

Well, of course not... It's an i3. I have hardware acceleration set to None in Publish Settings, and can get 1920x1080 video from a Logitech C920 without issue. However my dev machine is a dual core i7... I'd never expect to be able to do that on an i3 though, and likely not even on an i5 - though 720 should be doable on it.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 22, 2013 Jul 22, 2013

My dev machine is an i7 and it works well on that I agree. But the C920 works on my i3 laptop using the Logitech Software at 1080p perfectly, but not in flash. My question is why? It has to be that their software communicates with the camera better or something. Right?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Jul 22, 2013 Jul 22, 2013

OK, I see... so, can you use just the code you posted on your i3 - and just simply view the video smoothly, without trying to capture it? If you can view it fine, then how your capturing it would be suspect. Anytime I've needed to capture video I've used Flash Media Server.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 22, 2013 Jul 22, 2013

I wrote something really simple without the capture code and still had the same problems.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 22, 2013 Jul 22, 2013

Tried uninstalling everything then reinstalling the drivers only. Same thing. Yes 720p works fairly well, while 1080p has a one second dely in the video. Still don't understand why logitechs software displays the video perfectly even at 1080p on my i3 machine.

When you wrote this: That is odd. 1080 is working great for me in Flash, it's very smooth. I never even installed the Logitech software though, just the drivers, so I can't test any difference. What version of Windows - I'm running 64bit Windows 8.


were you referring to your i3 or i7 computer?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Jul 22, 2013 Jul 22, 2013

My i7, I do not have an i3 even for testing. I feel for ya... obviously the i3 is capable, given that Logitech's software works fine. You could try Logitech support, or their forums maybe just to see if this is a known issue. Off the top of my head, I can't think of any kind of workaround. You might try what you mentioned earlier and see if a MS cam and drivers works.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 22, 2013 Jul 22, 2013
LATEST

Great suggestions. I'll do both. Microsoft webcams might be better. It's their operating system so the interface might be smoother. Thanks for your help.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines