nice still, streaming is dark

Support and queries relating to all previous versions of ZoneMinder
bhomass
Posts: 103
Joined: Sat Jun 11, 2005 6:54 pm

nice still, streaming is dark

Post by bhomass »

I got everything setup so I can see a nice still in the browser, but the streaming display is dark. I have ffmpeg installed. do I need anything else in terms of codec or player to see streaming video?

is there a place where I dictate what kind of streaming encoding (MJPEG, MPEG, etc.) to use?

Thanks
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

When you say it's dark are you refering to that it is darker than the jpeg still or do you mean it is black and not displaying?
Windows Media player also takes up to 15 seconds to buffer the image before it will display and on a linux machine you would have to install something like mplayer to see the stream.
Firefox supports mjpg natively so you could disable mpg streaming and ZM will send mjpeg to mozilla based browsers.
You can also use cambozola to recieve mjpeg in IE.
bhomass
Posts: 103
Joined: Sat Jun 11, 2005 6:54 pm

Post by bhomass »

I mean totally dar. can't see a thing.

I have it playing on FireFox and NetScape on Windows. I can see it embedded Windows Media Player. I like to try playing both MPEG and MJPEG.

any idea what is killing the stream?
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

Any errors in the logs? and what version of ffmpeg are you useing?
bhomass
Posts: 103
Joined: Sat Jun 11, 2005 6:54 pm

Post by bhomass »

for some reason, make did not create /var/log/zm and there is no log file. could it be anywhere else?

I am using ffmpeg-0.4.9-pre1
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

It could be in just /var/log but also if you had permision problems it my not have been created. That could also contribute to your ffmpeg issue. Hopefully you can find the logs and the error not allowing streaming to start.
bhomass
Posts: 103
Joined: Sat Jun 11, 2005 6:54 pm

Post by bhomass »

I found zmdc.log in /tmp. here are some errors

Server starting at 05/06/11 08:49:25
Can't find process with command of 'zmtrack.pl -m 12'
Can't find process with command of 'zma -m 12'
Can't find process with command of 'zmc -d 0'
'zmc -d 0' started at 05/06/11 08:52:24
'zmc -d 0' starting at 05/06/11 08:52:24, pid = 14500
'zmc -d 0' crashed at 05/06/11 08:52:24, exit status 255
'zmc -d 0' started at 05/06/11 08:52:24
'zmc -d 0' starting at 05/06/11 08:52:24, pid = 14504
'zmc -d 0' crashed at 05/06/11 08:52:24, exit status 255
Can't select: No child processes at /usr/local/bin/zmdc.pl line 593.
Server starting at 05/06/11 08:52:24
Can't find process with command of 'zmtrack.pl -m 13'
Can't find process with command of 'zma -m 13'


what do they mean?
bhomass
Posts: 103
Joined: Sat Jun 11, 2005 6:54 pm

Post by bhomass »

now it has gone from bad to worse.

the device /dev/video0 turned red. both still and stream are showing. status says idle - 0.00 fps. what could have happened?
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

You need to check /var/log/messages to see why zmc is crashing. It should be fairly obvious but you can search for ERR to find errors.

Phil
bhomass
Posts: 103
Joined: Sat Jun 11, 2005 6:54 pm

Post by bhomass »

I saw a lot of
zmu[16357]: ERR [Can't shmget, probably not enough shared memory space free: Invalid argument]

so I increased shmall and shmmax to 134217728.

now I see this
zms[7065]: ERR [Shared memory not initialised by capture daemon]

the /dev/video1 remains red, and no still nor stream images.

has anyone seen this before?
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

Lot of times. If you do a search you'll get 2 pages worth.
This may be because the capture daemon hasn't been started or may be because it crashed before it could initialise it. Check in zmdc.log for example to see if it is being restarted, or look for earlier errors in the messages file.
See this thread may help:
http://www.zoneminder.com/forums/viewto ... ure+daemon
and
http://www.zoneminder.com/forums/viewto ... ure+daemon
Regards,
Cordel
bhomass
Posts: 103
Joined: Sat Jun 11, 2005 6:54 pm

Post by bhomass »

well, first zmu -d 0 -q -v failed, it says
Error, failed to open video device: No such device

the list of video devices has permission set as
linux:/dev # ll vid*
lrwxrwxrwx 1 root root 6 Jun 2 10:42 video -> video0
crw----rw- 1 bruce video 81, 0 Mar 19 11:36 video0
crw----rw- 1 bruce video 81, 1 Mar 19 11:36 video1
crw------- 1 bruce root 171, 16 Mar 19 11:36 video1394
crw----rw- 1 bruce video 81, 2 Mar 19 11:36 video2
crw----rw- 1 bruce video 81, 3 Mar 19 11:36 video3

do these look ok? or do they indicate some permission problem causing zmu to not find video0?
bhomass
Posts: 103
Joined: Sat Jun 11, 2005 6:54 pm

Post by bhomass »

I changed the u&g of video to bruce:video, now zmu -d 0 -q -v gets

Video Capabilities
Name: BT878 video (ProVideo PV143)
Type: 171
Can capture
Can tune
Overlay onto frame buffer
Can clip
Scalable
Video Channels: 4
Audio Channels: 0
Maximum Width: 924
Maximum Height: 576
Minimum Width: 48
Minimum Height: 32
Window Attributes
X Offset: 0
Y Offset: 0
Width: 320
Height: 240
Picture Attributes
Palette: 4 - 24bit RGB
Colour Depth: 24
Brightness: 32768
Hue: 32768
Colour :32768
Contrast: 32768
Whiteness: 0
Channel 0 Attributes
Name: Composite0
Channel: 0
Flags: 2
Channel has audio
Type: 2 - Camera
Format: 0 - PAL
Channel 1 Attributes
Name: Composite1
Channel: 1
Flags: 2
Channel has audio
Type: 2 - Camera
Format: 0 - PAL
Channel 2 Attributes
Name: Composite2
Channel: 2
Flags: 2
Channel has audio
Type: 2 - Camera
Format: 0 - PAL
Channel 3 Attributes
Name: Composite3
Channel: 3
Flags: 2
Channel has audio
Type: 2 - Camera
Format: 0 - PAL


but /dev/video0(0) on console is still red, and no image is displayed.
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

Well heres mine on FC3
lrwxrwxrwx 1 root root 6 May 18 14:47 /dev/video -> video0
crw----rw- 1 root root 81, 0 May 18 14:47 /dev/video0
crw----rw- 1 root root 81, 1 May 18 14:47 /dev/video1
crw------- 1 root root 81, 1 May 18 14:47 /dev/video4linux

not sure how your name got in there as the owner or why video is the group unless you changed the root user to bruce.
bhomass
Posts: 103
Joined: Sat Jun 11, 2005 6:54 pm

Post by bhomass »

strange, after I changed the symlink owner to bruce, zmu started to see the video device. I thought that was the problem.

in any case, I restarted zm, and now still image is showing fine again.

but still no stream image. why and when would still show but not stream? can't be the zmc problem anymore, right?
Locked