2,453 questions
1
vote
0
answers
40
views
Memory returned by VIDIOC_DQBUF has garbage. Sometimes
I'm trying to capture a USB camera video as a series of MJPEG images. I'm using this official example as a base. Please refer to it, since it's quite long to paste it here. The only thing I changed is ...
1
vote
1
answer
172
views
V4L2 VIDIOC_ENUM_FMT: Inappropriate ioctl for device
My goal is to capture video using V4L2, and testing it with a virtual video device created by v4l2loopback. I'm feeding a dummy .mp4 to this virt vid device with ffmpeg which is located at /dev/video7....
0
votes
2
answers
90
views
Want to capture video from AverMedia Live Gamer Ultra GC553 on Raspberry Pi 5
I want to analyze video using OpenCV in Python on my Raspberry Pi 5 by capturing it through a Live Gamer Ultra GC553. I tried the following Python code on the Raspberry Pi:
import cv2
cam_id = 0
cap ...
0
votes
0
answers
38
views
MediaRecorder fails to properly transition to second video file
I'm trying to use an Android MediaRecorder to record video. In order to limit the size of the file I want to periodically start a new video file, and just like the built-in Camera app I don't want to ...
0
votes
0
answers
26
views
How can record the filtered video to an MP4 file with Android CameraX
I want to use CameraX to implement a video recording feature, where I can apply a filter effect using OpenGL during the preview, and record the video with the filtered effect. However, I can’t find a ...
1
vote
1
answer
400
views
Crash in AVCaptureDevice.requestAccess in iOS 18 with swift 6
I am facing an issue in iOS 18 that works fine in iOS 17 and earlier.
This happens when you set the project to use Swift 6.
The app has the Privacy - Camera Usage Description key in the Info.plist.
It ...
1
vote
0
answers
722
views
Issues with Video Recording Duration and Smooth Playback when Using v4l2 framework to MP4 (FFmpeg)
I'm trying to record a video from a USB device with v4l2 framework and save it in MP4 format using FFmpeg. My sample code successfully captures and saves the video, but I'm running into some issues:
...
0
votes
0
answers
169
views
Record incoming WebRTC Stream on Client Side
I want to capture incoming video of other user(s) on a WebRTC Live Stream (Example: GMeet), without recording my screen. I found a similar question, and a chrome extension, but they don't work anymore....
1
vote
0
answers
122
views
Why is this shader stretching the overlay?
I have the following shader where I expect to write an overlay onto a video frame, but the result is an overlaid image which is stretched horizontally by a factor 2. What could be causing this issue? ...
0
votes
1
answer
144
views
How to improve random access of a video frame with Python?
I'm using pims library (https://github.com/soft-matter/pims) to access frames from .MOV file with over 25K frames, 3840 × 2160, H.264 (High Profile), 60fps.
import pims
from time import perf_counter
...
0
votes
0
answers
126
views
How to parse ffmpeg -list_options output to get complete list of formats?
On my Windows 10, application I use VB6 and ffmpeg.exe to capture video from USB capture device.
I need to show complete list of supported formats by this capture card.
When I use below command I get ...
2
votes
0
answers
56
views
GTK4 rapidly display multiple frames
I am trying to display a video stream received from an ffmpeg stream.
ffmpeg -f x11grab -framerate 60 -video_size 1920x1080 -i :0.0 -c:v libx264 -preset ultrafast -tune zerolatency -b:v 3M -f mpegts -...
0
votes
0
answers
87
views
Lack of volume of recorded video from ESP32-CAM
I have this code in my esp32-cam there is no error, but when 20 seconds of video is recorded, an AVI file is created in the SD card, and it has no size, it is 0 KB and it doesn't show anything. No ...
0
votes
1
answer
408
views
Problem in running ESP32-CAM video recording code
I wanted to upload the code in this link to my esp32-cam so that I can save the videos recorded by the camera to the sdcard. But I encountered the following error while uploading:
C:\Users\Hacker\...
1
vote
1
answer
206
views
Preferred video file format to prevent corruption in the event of unexpected recording interruption
I'm rigging up some additional security cameras for my home office, and while I have battery backup in case of power loss, and auto startup for the code I developed, I would like the video files to be ...
0
votes
1
answer
102
views
Videoplayer does not play previously recorded VIDEO BLOB
For a friends master thesis I have started creating a small video recorder app, so her participants can record themselves (also because I wanted to use this API :) ).
I'm in the early stages of this ...
2
votes
0
answers
159
views
Media Foundation Video Capture Engine fails to capture the video on disconnecting the device
I am developing a windows desktop application to record video in .mp4 format from a USB camera using the Media Foundation Capture Engine sample code. In this application, everything works fine until I ...
0
votes
0
answers
119
views
Improving low-light image capture using OpenCV
We are using the following Python script combined with OpenCV to record video of salmon migration in order to estimate total fish passage,
import cv2
import numpy as np
import time
import datetime
...
0
votes
0
answers
83
views
How can we get the contents of an occluded window using Rust
I hope someone can give me some Pointers. I want to use Rust to call the Windows api for a feature that fetches the contents of an occluded window. I tried DGI method, but BitBlt method could not get ...
0
votes
0
answers
49
views
Save video output to a new file each time a button is pressed? - Human Dashcam Project
Apologies if this is out of format, this is my first time on Stack Exchange!
I've been trying to build a project that functions like a real-world equivalent of Nvidia's Shadowplay feature--a camera ...
0
votes
2
answers
823
views
How to implement Low Latency, 60 fps video encoding in WebRTC in C# with WebRTC?
Recently, I've been trying to implement a 60 fps low latency screenshare with C# with a library called Sipsorcery. I've tried my best so far to maximize the frames but i only get around 20 fps.
I ...
0
votes
1
answer
597
views
Capture video of my screen with libpipewire
The pipewire repository has an example of capturing video from a webcam. The window that opens displays video from the webcam. How to capture video from the desktop, not from the camera? That is, so ...
1
vote
0
answers
38
views
Video formats that support writing in a rolling fashion?
Are there any video formats out there that support writing in a rolling fashion? e.g. if I have a mmap/file that is the size of a 3 seconds video (1920x1080) at 30fps, I want to write frames to it ...
0
votes
0
answers
46
views
Record video playing in canvas with full volume even if it is playing on lower volume
Hello and thank you for your time,
I am recording a video which is mirror-playing in a canvas from that canvas.
The original video is seated in a normal tag.
When recording the volume of the recorded ...
0
votes
0
answers
79
views
Python - OpenCV Videocapture stuck
I have a esp32cam with a stream on a webserver. When I try to open the stream with opencv it gets stuck
import cv2
from PIL import Image, ImageTk
raw_stream = cv2.VideoCapture()
raw_stream.open("...
0
votes
0
answers
37
views
startRecording(saveDirectory) is not working as expected
It returns true that it is starting the recording, but when ending the recording it does not save the file in specified saveDirectory
Also checked with File(recordPath).exists() it returns false, no ...
0
votes
1
answer
2k
views
OpenCvSharp VideoCapture super slow upon Initialization
I am using OpenCvSharp's VideoCapture class to capture images from a camera, from which I use to display as a video stream. I am using this camera that is attached via USB.
The problem that I have is ...
0
votes
1
answer
136
views
cv2 VideoWriter writes small file with no video. Frames come from mss screen capture
I am writing a python script to capture the screen to a video but the resulting video file is only 8k long and there is no video in it. My code looks fine to me and I can see the captured frames which ...
0
votes
0
answers
70
views
Massive memory leak when creating and releasing Capture Filter in DirectShow
After much trial and error I have succeeded in grabbing still images from the laptop's built-in camera.
But I have noticed a memory leak and spent days trying to pin it.
So I have stripped the code to ...
0
votes
0
answers
86
views
What I'm I doing wrong with my custom video controls
I am trying to create custom video controls for my react native app but it seems like I am missing something. Currently only the pause/play functionality work. The fast forward/ rewinding and slider ...
0
votes
0
answers
100
views
Video Emulation solution
For a professional application I'm using a video grabber to capture realtime the video output of a PC, having various resolutions (Full HD to 4K) and incapsulate it into a RTP stream with RTSP ...
1
vote
0
answers
63
views
How to clean the packets of AVFormatContext?
I'm trying to write a video recorder class with ffmpeg, but video file generate have a issue. In every record, the second 1 of the video is a dark frame, and the second 2 is single frame, repeated 25 ...
-1
votes
1
answer
251
views
Capturing video using raspberry pi with 64 bit OS
I tried capturing video using Raspberry Pi 4 Model B 8GB RAM and OS of 64 bit. But unable to capture a video due to c2 error. Along with that I'm having no camera in interface option so I updated then ...
0
votes
1
answer
66
views
Meaning of VideoCapture prop definitions not in the opencv documentation
Is there any to tell what the meaning of video capture properties that aren't defined in the official documentation? For example,
import cv2
cap = cv2.VideoCapture(filename)
Video properties can be ...
1
vote
1
answer
88
views
an efficient for loop for this program
I'm writing a program that will analyze a video frame-by-frame. The program is supposed to calculate the height of an object that is varying through time. I used the fact that the top of the object is ...
1
vote
0
answers
117
views
Why is there a discrepancy in CVImageBufferYCbCrMatrix between full range and video range formats?
I am looking at the 420v (kCVPixelFormatType_420YpCbCr8BiPlanarVideoRange) and 420f (kCVPixelFormatType_420YpCbCr8BiPlanarFullRange) options offered via AVCaptureDevice.Format when setting up an ...
0
votes
1
answer
402
views
Optimizing Real-time Video Frame Capture Python/cv2
I have a thread dedicated to reading frames from a camera, aiming to read at a specific frequency (self.target_fps). Therefore, I need to perform a read every self.target_frequency = 1 / self....
1
vote
0
answers
911
views
Using OpenCV to read input from Capture Card
I am trying to use OpenCV in Python to read the feed coming from my Elgato HD 60 pro capture card but I keep running into errors. If you don't think OpenCV is the right tool for this I would greatly ...
1
vote
0
answers
436
views
SIPSorcery WebRTC receive and save video stream to file
I created a project using SIPSorcery that receives stream (VP8 or H264 format) from WebRTC, and saves it to video file (and photo if needed). The problem is, I cannot think how to convert that ...
0
votes
0
answers
76
views
multiple images in a single frame in opencv
I extracted a video from a VHS tape. The horizontal sync didn't trigger properly in many of the lines causing that line to be shifted, usually to the right. I wrote some code in an attempt to detect ...
1
vote
1
answer
362
views
How to use VideoCapture Camera with elgato camera hub
I am trying to use the VideoCapture function from the opencv library. Due to the lack of webcam of my laptop, I've download CameraHub to access my phone's camera as the main webcam for the system.
...
0
votes
0
answers
116
views
Can't extract frames from corrupted video files using python, but can play the videos on VLC
I use python to extract frames from video files.
Specific now I use Open-CV.
I know that the files is some how corrupted I knew that there is a chance that I could not extract the frames as I want to, ...
2
votes
1
answer
575
views
WebRTC: Capture picture while stream to remote peer disabled
Imagine a video call application where you allow the user to disable his camera stream (say, for privacy reasons) and in which it is also possible to take a picture with the camera to then send it to ...
1
vote
1
answer
215
views
Encountered an issue using MediaFoundation
My project is using MediaFoundation's Source Reader to capture and preview cameras, but I encountered the following issues when presenting videos using EVR.
Code:
#include <evr.h>
#include <...
0
votes
0
answers
88
views
Raspberry Pi 4 8GB - 2 USB Cams - C++ not loading but JS loads video in browser
I have Raspberry pi 4 with 8GB ram, I have connected two USB webcams (Eternico Webcam ET101 HD) to it, I need to read video from both cameras at once for triangulation of detected objects.
I am using ...
1
vote
0
answers
178
views
Videocapture from opencv doesn't work for me. What should I do?
I have dockerized my app and I have used http://nvcr.io/nvidia/pytorch:23.10-py3 base image. I'll share my dockerfile with you. I am also using Ubuntu.
The problem here is that videocapture method ...
1
vote
0
answers
158
views
C# Emgu CV get name of capture
I use the Emgu.CV.VideoCapture class to capture an external camera connected via usb.
However sometimes I have the problem that the capture seems to switch internally to my integrated laptop camera.
I ...
1
vote
0
answers
102
views
Opencv videocapture can not open 4 cameras simultaneously
I have four usb camers mounted via usb hub. they are video4,video6,video8 and video10. When I open the camera one by one, they works fine.
When I open three cameras together, they still works fine.
...
1
vote
1
answer
148
views
SharpDX camera streaming not respecting MediaType set
I am trying to stream web camera to my application and while I have a workaround for various resolutions I would like to use camera capabilities to provide the image in different resolution.
My ...
0
votes
0
answers
132
views
How to modify camera settings of shared camera capture in Windows?
I want to modify the camera exposure while previewing the video capture from my webcam, while I am in a video meeting with Google Meet, Zoom, etc. I'm using the MediaCapture class in a WPF application....