|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
||||
|
||||
|
Accessing .mjpg stream from camera to process
Our team is attempting to use a dlink camera (don't know the exact model at the moment) and it has support in the form of 10.16.84.20/camera.mjpg. I've looked at the axis camera code and switching that to a standard mjpeg stream would require a bit of deconstruction, which is doable but is a waste of my time if there is another alternative.
Is there a built in way to retrieve images from any given mjpg stream? |
|
#2
|
||||
|
||||
|
Re: Accessing .mjpg stream from camera to process
bump. Haven't had time to write a mjpeg adapter
|
|
#3
|
|||
|
|||
|
Re: Accessing .mjpg stream from camera to process
I do not think you can do what your looking for. I think first really shafted the java programmers this season! I digress, I think you might have to use a usb webcam for that. In the beginning i was playing around with the vision and stuff, but it seems like you will need a co-processor anyways. I did a solid week of research on this topic before I got a semi workable vision prototype. I only use OpenCV(for image processing) and the network tables to communicate to the robot. You can find the github link here!
|
|
#4
|
||||||
|
||||||
|
What do you think is worse this year compared to last year? |
|
#5
|
||||
|
||||
|
Re: Accessing .mjpg stream from camera to process
Vision programming. The entire thing is really buggy with next to no documentation whatsoever and the only sample code doesn't even process an image.
Thanks for your JavaCV link but the only thing I'm looking for is to display the image on the driver station. I ended up following this code to get some byte arrays out of a mjpeg. |
|
#6
|
|||
|
|||
|
Re: Accessing .mjpg stream from camera to process
yeah, exactly that! Also I do not think there is a support for the axis camera series, just Usb webcams
|
|
#7
|
||||
|
||||
|
Re: Accessing .mjpg stream from camera to process
AxisCamera.java?
|
|
#8
|
|||||
|
|||||
|
Re: Accessing .mjpg stream from camera to process
Have you had any success with actually connecting to the camera from the robot?
|
|
#9
|
|||
|
|||
|
Re: Accessing .mjpg stream from camera to process
That class was made for last year's vision system. Also I have tested it this year and does not work.
|
|
#10
|
||||
|
||||
|
Re: Accessing .mjpg stream from camera to process
You can use OpenCV VideoCapture object. You could also edit the smart dashboard camera view.
|
|
#11
|
||||
|
||||
|
Re: Accessing .mjpg stream from camera to process
I also confirm that it works, though CameraServer has a 2-3sec lag compared to SmartDashboard's direct connection which gets a ~100ms lag
|
|
#12
|
|||
|
|||
|
Re: Accessing .mjpg stream from camera to process
what Axis camera? I used an axis m1013 and it did not, maybe I will revisit it.
|
|
#13
|
|||||
|
|||||
|
Re: Accessing .mjpg stream from camera to process
We were finally able to get it running, but not with the AxisCamera. The robotRio sees the IP camera as cam0, so I was able to use it just like the USB cameras. Thank for the help.
|
|
#14
|
||||||
|
||||||
|
Quote:
It works for me. There's even a built in example for it. |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|