We don’t allow questions seeking recommendations for software libraries, tutorials, tools, books, or other off-site resources. You can edit the question so it can be answered with facts and citations.
Closed 5 years ago.
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(7)
FFMPEG 支持屏幕捕获(投射)并且是跨平台的。
FFMPEG supports screen capturing(casting) and is cross platform.
您可以尝试 Windows Media Encoder(免费软件,仅限 wmv/asf)或 VLC(GPL、Win/OSX/Linux)。请注意,“硬件加速”视图(例如 Direct3D 和 OpenGL 渲染)将不可用,并且由于视频压缩,将会出现一些质量损失。您丢失的数量取决于您的设置(编解码器、比特率、分辨率等)
示例:如何使用 VLC 流式传输桌面
您可以在 VLC 文档,例如将流保存为文件。
You could try Windows Media Encoder (freeware, wmv/asf only) or VLC (GPL, Win/OSX/Linux). Be aware that "hardware accelerated" views (Direct3D & OpenGL rendering for example) will not be available, and some quality loss will be experienced due to video compression. How much you lose will depend on your settings (codec, bitrate, resolution, etc)
Example: How to Stream your Desktop using VLC
You can find more options in VLC documentation, for saving your stream as a file for example.
这是我在 Delphi 中使用的一个,它被称为“专业屏幕摄像头组件”。不可否认,我必须进行一些更改才能支持 unicode 版本(将 PChar 替换为 PAnsiChar,将 Char 替换为 AnsiChar)。
它会很乐意以我设置的任何帧速率进行录制,使用我指定的任何编解码器(如果我想要的话)对视频进行编码,并允许您指定要录制的区域。
还附带一个演示项目!
哦,它是免费/开源的!
This is the one I use with Delphi, it's called "Professional Screen Camera Component". Admittedly I had to make some changes to support unicode versions (replace PChar with PAnsiChar, replace Char with AnsiChar).
It'll happily record away at whatever framerate I set it to, will encode the video with whatever codec I specify (if I want it to), and allows you to specify the region you wish to record.
Comes with a demo project too!
Oh, and it's free/open source!
它可能超出了您的需求,但 DataStead 的视频采集器组件还可以记录屏幕活动并将输出保存为视频文件。请参阅http://www.datastead.com/products/tvideograbber/overview.html。我与 DataStead 没有任何关系,但我已经是几年前的客户了,而且效果很好。
It is probably overkill for your needs, but the video grabber component from DataStead can also record screen activity and save the output as video file. See http://www.datastead.com/products/tvideograbber/overview.html. I'm not associated with DataStead, but have been a customer for a few years and it works great.
FFmpeg 可用于捕获屏幕。
观看使用 FFMPEG 录制的屏幕视频演示:https://www.youtube.com/watch?v=a31bBY3HuxE
容器格式 : MP4
编解码器 : MPEG4
按照以下步骤录制屏幕使用 FFmpeg 和其他库的视频。
初始化所需的寄存器
在 av_find_input_format 中使用 x11grab(适用于 linux 操作系统)
提及在屏幕中捕获视频的位置(例如 av_format_open_input 中的“:0.0+10,250”)
现在进行常规视频参数初始化和内存分配。
开始捕获帧并将其存储在文件中。
最后,完成后释放分配的资源!。
下面的代码是用c++编写的,使用linux(ubuntu)平台视频格式为mp4格式。
这是屏幕截图。
完整的工作代码github链接:
FFmpeg can be used to capture the screen.
watch the screen recorded video demo using FFMPEG : https://www.youtube.com/watch?v=a31bBY3HuxE
Container format : MP4
Codec : MPEG4
Follow the steps to record the screen in video using FFmpeg and other libraries.
Initialize required registers
use x11grab(for linux OS) in av_find_input_format
mention the posistion to capture the video in screen (Eg. ":0.0+10,250" in av_format_open_input)
Now go for regular video parameters initialization and memory allocation.
start capturing the frames and store it in a file.
Finally, release the allocated resources once completed !.
below code is written in c++ and uses linux(ubuntu) platform video format is in mp4 format.
Here's the screenshot.
complete working code in github link:
我自己以前没有这样做过,但是当我用谷歌搜索时(我相信你已经这样做了),我遇到了这个:
http://www.codeproject.com/KB/GDI/barry_s_screen_capture.aspx
看起来它应该很容易地完成您所要求的任务(对于Windows),并且没有与之关联的许可证(如底部所确认)。我不相信它被设置为一个库,但我确信您可以轻松地将示例 WinCap 函数的接口绑定到一个库中。
I haven't done this myself before, but when I googled around (as I'm sure you have), I ran into this:
http://www.codeproject.com/KB/GDI/barry_s_screen_capture.aspx
It looks as if it should do what you're asking reasonably easily (for Windows), and it has no license associated with it (as confirmed at the bottom). I don't believe its set up as a library, but I'm sure you could bind the interface to the sample WinCap functions into one with reasonable ease.
使用屏幕捕获精简版
https://github.com/smasherprog/screen_capture_lite
这是一个 C++ 库,跨平台
use screen capture lite
https://github.com/smasherprog/screen_capture_lite
This is a C++ library and cross-platform