Comments (3)
Overall low performance: as expected or not?
For the results you are posting, I would say that is better than expected 😆
FFmpeg reports that it is able to drive 30fps and I see no real delay in the resulting video device's output. Great! But when I try to shuffle frames in a 1080p30 mode with the following command, FFmpeg is only able to achieve just 25 fps on average and after a few seconds (as expected as the input still comes with 30 fps) the FFmpeg "rtbufsize" is full and FFmpeg complains and the virtual camera device's output shows more and more delay
It's normal, the bigger the frame size, the higher the delay you will have.
Do you have any ideas what can cause such a low overall performance?
Yes, all the frames format conversions and scaling is by far the biggest bottleneck.
Do you have any ideas how I speed up the processing?
Yes, all the frame processing could be improved parallelizing the conversion, maybe using OpenMP, maybe using the CPU intrinsic functions, maybe passing the task to the GPU, maybe using OpenCL or CUDA, there are a lot of options.
For now, I am satisfied that it works at least, and will try to improve it much later.
I guess feeding YUY2 is actually not intended, even it looks it partly works?
I'll add support for other input formats later.
from akvirtualcamera.
Ok, I've investigated deeper: it was entirely my fault in using a too problematic setup! As I'm a Unix veteran I was used to write down the test pipelines as the mentioned Unix shell scripts, as even under Windows 10 I'm always working inside its WSL. But: the two involved programs in the pipeline are ffmpeg.exe
and AkVCamManager.exe
and both are regular Windows executables, while the stdio interconnect is from the Unix shell! As a consequence, the video stream had to travel from the Windows world of ffmpeg.exe
to the WSL world (for the stdio pipe) and back again to the Windows world of AkVCamManager.exe
. And this doubled transfer between the worlds was what effectively limited the overall throughput! Once I executed the pipleline directly inside a Windows .bat
file it achieves 60fps:
ffmpeg.exe -hide_banner -f dshow -rtbufsize 240M -s 1920x1080 -framerate 60 -i "video=BRIO 4K Stre
am Edition" -f rawvideo -map 0:v -pix_fmt rgb24 -s 1920x1080 - | AkVCamManager.exe stream AkVCamVideoDevice0 RGB24 1920 1080
So, sorry, there is neither is performance problem within FFmpeg nor AkVirtualCamera. It was the problematic interconnect!
from akvirtualcamera.
Oh ok, I didn't tested it in WSL, I usually use MSYS as my playground.
from akvirtualcamera.
Related Issues (20)
- Webcamoid 9.0.0 hangs after downloading and installing akvirtualcamera HOT 2
- Sending frames from python HOT 2
- Stream bitmap ( single frame image ) to the virtual device HOT 4
- Frame transfer not using pipe HOT 1
- Virtual Camera "Can't Start Stream" in Mac HOT 5
- Unable to find virtual camera on M1 Mac (Chrome, Firefox, Zoom) HOT 3
- Idea: move xpc_connection_create_mach_service to NSXPCConnection so that it works with QuickTime HOT 12
- Zoom can't detect akvirtualcamera,and virtual cameras can't delete in Windows. HOT 9
- [MacOS] Virtual cameras do not appear in applications but clients appear in list HOT 2
- Windows: Skype for desktop do not find virtual camera HOT 5
- Add-device success, but not found in any client HOT 3
- akvirtualcamera is not available on Android Emulator HOT 1
- AkVCamManager Remove-Devices Issue HOT 1
- AkVirtualCamera replaces a different virtual camera and renders it unusable HOT 1
- Forbid other programs to use the virtual camera when already in use HOT 3
- akvirtual camera - Virus detected HOT 2
- AkVirtualCamera manager keeps waiting and shows no output. HOT 2
- window10 ,akvirtualcamera-windows-9.1.1.exe,Wechat cannot be used,but it can be detected HOT 1
- Bootstrap failed: 5: Input/output error HOT 2
- I want to use other programs to write data to the shared memory of the virtual camera. How do I do that? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from akvirtualcamera.