Jan 08 2004

Getting your DV cam signal to work in Flash Player

Published by at 2:15 under Wayback Archive

If you own a DV cam you probably have tried to make itself known to the Macromedia Flash Player. Macromedia could only test a limited number of cameras, most of which are webcams and not DV cams. I know from the FlashComm mailing list that some developers have had problems getting the DV cam video signals into their applications.

Well, today I received an email from DigitalInkt wih the possible solution. One single line of ActionScript made their DV cam work!

Any webcam that supports MS DirectShow should work with Flash video, but this was not the case for Laurent from Digital Inkt; some of their cams did not properly sent their video to the Flash Player. Here’s the information that Laurent sent to me:

“I did some further research and found out that most DV-Cams won’t show up in Flash unless I specify the exact resolution of the incoming videodata using Camera.setMode();”

So, if your cam is recognized by the Flash Player and you are not seeing the video image, then simply give this trick a try. Be aware of the parameters that this method takes. Sample: my_camera.setMode(720, 568, 12,true);

6 responses so far

6 Responses to “Getting your DV cam signal to work in Flash Player”

  1. JesterXL says:

    That method is both powerful and dangerous. Although that has been the solution to many camera oddities, do NOT set it lower than 160 x 120. There are some crashing issues, maybe fixed by now, but you never know based on camera, based off of setting setMode to exremely low values for width and height.

  2. Waldo Smeets says:

    Interesting. Do those crashes only happen on the machine broadcasting the video, or also on the machines receiving the video?

  3. Thanks for the tip Waldo. FYI, the Canon “ZR” series of DV cameras seems to work with no problem.

  4. Laurent says:

    it seems to work now, when i set it at 720×568… but now i have some kind of strange fieldjitter when I move in front of the camera: http://forum.n3uk.com/images/fieldJitter.jpg

    On the sony cams we tested, this was resolved by setting the camera in memory (instead of tape) mode. I think it has something to do with fields vs. frames (someone tried explaining me that concept and it seems logic that is what’s happening here).

    However now we’re testing with a panasonic dv-cam that doesn’t have that memory-mode. So how do i resolve the fieldjittering problem?

  5. Johanna says:

    Hi
    I’m try to get this to work in flash mx with a Sony handycam (Carl Zeiss). I’ve it set to memory mode and I’m using the following code

    cam = Camera.get();
    cam.setMode(720, 568, 12,true);
    mylive.attachVideo(cam);

    Can anyone help, its driving me crazy
    Thanks:)

  6. Waldo Smeets says:

    Hi Johanna,

    my best advice is to try the FlashComm mailinglist: http://chattyfig.figleaf.com They have lots of FlashCom developers that can give you more feedback on this issue you mention.