Thanks Pada!
Works perfect for 6 days without interruption.
Has anyone tried to modify it to show, by a click, the camera in full screen? It may even include a window with ptz controls?
For now i'm looking for ways, if any did appreciate your help...
Sorry for my english, but some time ago that i do not practice... : P
Raw stream viewer
Hi Pada,
Quick question:
Should the feed take up the whole window? I'm accessing a network camera with a feed 640 x 480. When I launch the OpenGL version, I can view the feed but it only takes up a 640 x 480 in the top left corner of the window and the rest is all black. If I resize the window, the feed takes up a smaller/larger portion accordingly but never overtakes the black area.
Here are some screenshots that will hopefully help:
Here is what I get when I just use "sudo ./xlib_shm -m6"
Here is what I get when I use "sudo ./xlib_shm -m6 -w 640 -h 480"
And in an unrelated issue, this is what I get when I use the non-GL version. EDIT: This was addressed/fixed earlier in the thread:
Quick question:
Should the feed take up the whole window? I'm accessing a network camera with a feed 640 x 480. When I launch the OpenGL version, I can view the feed but it only takes up a 640 x 480 in the top left corner of the window and the rest is all black. If I resize the window, the feed takes up a smaller/larger portion accordingly but never overtakes the black area.
Here are some screenshots that will hopefully help:
Here is what I get when I just use "sudo ./xlib_shm -m6"
Here is what I get when I use "sudo ./xlib_shm -m6 -w 640 -h 480"
And in an unrelated issue, this is what I get when I use the non-GL version. EDIT: This was addressed/fixed earlier in the thread:
Any thoughts?Yes, i'm sure that all palettes are right.
It seem to be an issue with the video driver, the videocard it's a crappy nvidia with proprietary driver.
Using the non-gl version of xlib_shm with the -s option solve the problem and i can see good images on video.
If under Ubuntu server LTSP 10.04 64bit (xlib_shm-0.6.5) someone will have error such like:
the patch should be applied (its just dot difference):
Thanks maciekc & pada for this useful code !
cheers
Code: Select all
Can't open linked memory map file /dev/shm/zm.mmap.1: No such file or directory
Code: Select all
--- xlib_shm.c.orig 2010-10-15 04:49:44.000000000 +0200
+++ xlib_shm.c 2011-03-09 15:35:40.000000000 +0100
@@ -641,7 +641,7 @@
int id = monitor[cam]->mon_id;
if (use_mmap) {
char mem_file[255];
- snprintf( mem_file, sizeof(mem_file), "%s/zm.mmap.%d", "/dev/shm", id );
+ snprintf( mem_file, sizeof(mem_file), "%s/.zm.mmap.%d", "/dev/shm", id );
// Copied from zm_monitor.cpp
int mem_size = sizeof(SharedData) + sizeof(TriggerData);
cheers