# Regame - Cloud Gaming Engine
[简体中文](README.zh-CN.md) | English
`Regame - Cloud Gaming Engine` is a set of technologies developed by Edge computing team of [Ksyun](https://www.ksyun.com/) to serve the cloud game scene.
Cloud gaming is a method of playing video games that is done using remote hardware. You don't have to download or install games locally, just begin playing the game immediately because it is being run on remote servers.
Cloud gaming engine is a core technology to host ordinary games on remote server and start cloud gaming service.
`Regame` is still under development. It would be great if you could help.
[Download Regame v0.4 here](https://ks3-cn-beijing.ksyun.com/liuguang/regame_v0.4.zip)
Demo videos (Chinese):
- [01-Regame Cloud Gaming Demo - Street Fighter](https://www.bilibili.com/video/bv1jt4y1r7GT) - bilibili
- [01-Regame Cloud Gaming Demo - Street Fighter](https://www.ixigua.com/6898563893564703239) - ixigua
- [01-Regame Cloud Gaming Demo - Street Fighter](https://www.zhihu.com/zvideo/1314567244832530432) - zhihu
- [09-Regame WebRTC - Accelerate the cloud trip of enterprise business - English subtitle](https://www.bilibili.com/video/BV1g34y1U7RL) - 哔哩哔哩
- [09-Regame WebRTC - Accelerate the cloud trip of enterprise business - English subtitle](https://www.ixigua.com/7023285940831552031) - 西瓜视频
- [09-Regame WebRTC - Accelerate the cloud trip of enterprise business - English subtitle](https://www.zhihu.com/zvideo/1436363494992445440) - 知乎
## 1. Requirements
### Server
| Target | Minimum | Recommended |
| --- | --- | --- |
| System | Windows 7, 8, 8.1, 10 | Windows 10 |
| GPU | NVIDIA GPU | GTX 1080Ti, RTX 2070S tested |
| Software | GeForce Experience | latest GeForce Experience |
| Driver | GeForce Game Ready Driver | latest GeForce Game Ready Driver |
### Client
| Target | Minimum | Recommended |
| --- | --- | --- |
| System | Windows 7, 8, 8.1, 10 | Windows 10 |
| CPU | ANY | amd64 |
## 2. Basic
- `cgh` use Hook technology to capture image, support most of DirectX games, such as Cyberpunk 2077, Street Fighter.
- `cge` use FFmpeg to encode audio and images `cgh` captured into streaming.
- `cgc` use FFmpeg to decode audio and video frames, and use SDL2 to play audio and show images.
[![Data Flow](doc/cg.png)](doc/cg.gv)
## 3. QuickStart
[FAQ](doc/faq.md)
### cge
The `Cloud Gaming Engine`.
You can launch `cge` directly, which will apply default options.
Run `cge --help` to see all options:
```
KSYUN Edge Cloud Gaming Engine v0.4 Beta
Usage:
-h [ --help ] Produce help message
--audio-bitrate arg (=128000) Set audio bitrate
--audio-codec arg (=libopus) Set audio codec. Select one of {libopus, aac,
opus}
--bind-address arg (=::) Set bind address for listening. eg: 0.0.0.0
--disable-keys arg Disable scan codes. eg: 226,230 disable ALT;
227,231 disable WIN
--donot-present arg (=0) Tell cgh don't present
--hardware-encoder arg Set video hardware encoder. Select one of
{amf, nvenc, qsv}
--gamepad-replay arg (=none) Set gamepad replay method. Select one of
{none, cgvhid, vigem}
--keyboard-replay arg (=none) Set keyboard replay method. Select one of
{none, cgvhid}
--mouse-replay arg (=none) Set mouse replay method. Select one of {none,
cgvhid}
--log-level arg (=info) Set logging severity level. Select one of
{trace, debug, info, warning, error, fatal}
-p [ --port ] arg (=8080) Set the service port
--video-bitrate arg (=1000000) Set video bitrate
--video-codec arg (=h264) Set video codec. Select one of {h264, h265,
hevc}, h265 == hevc
--video-gop arg (=180) Set video gop. [1, 500]
--video-preset arg Set preset for video encoder. For AMF, select
one of {speed, balanced, quality}; For NVENC,
select one of {p1, p2, p3, p4, p5, p6, p7,
slow, medium, fast}; For QSV, select one of
{veryfast, faster, fast, medium, slow, slower,
veryslow}; otherwise, select one of
{ultrafast, superfast, veryfast, faster, fast,
medium, slow, slower, veryslow, placebo}
--video-quality arg (=23) Set video quality. [0, 51], lower is better, 0
is lossless
```
You can press `Ctrl+C` to stop it gracefully.
### regame-authenticator
`cge` uses [regame-authenticator](https://github.com/ksyun-kenc/regame-authenticator) to verify login.
[![regame-authenticator](doc/regame-authenticator.png)](doc/regame-authenticator.gv)
### cgh
Some hook dlls for capturing pictures from D3D game.
### cgi
A tool for injecting hook dll into game process.
[![Hook game](doc/cgi.png)](doc/cgi.gv)
```
Allowed options:
-h [ --help ] Produce help message
-d [ --dynamic ] arg Use dynamic injecting
-e [ --exec ] arg Path of the executable
-a [ --arg ] arg Arguments of the executable
-c [ --cd ] arg Current directory for the executable
-i [ --imagename ] arg Image name of the process being injected.
-w [ --wait ] arg (=1,000) Wait before injecting. unit: ms
--lx86 arg Path of x86 library to inject into process
--lx64 arg Path of x64 library to inject into process
```
### cgvhid
Cloud gameing Virtual HID driver. For replaying controller event on server.
![Hook game](doc/cgvhid.png)
### cgvidd
Cloud gameing Virtual Indirect Display Driver. For capturing screen on server.
### video_source
A tool for testing. Just run it, and it will generate simple pictures and write them as video frames to shared memory, then notify `cge` to fetch. You can use `cgc` to see these pictures.
It also can be used to test latency.
Video Reference (Chinese):
- [05-Regame Cloud Gaming Engine: Latency Test](https://www.bilibili.com/video/BV1KU4y147ks/) - bilibili
- [05-Regame Cloud Gaming Engine: Latency Test](https://www.ixigua.com/6918363287298146823) - ixigua
### cgc
A simple client to work with `cge`.
```
Ksyun Edge Cloud Gaming Client v0.3 Beta
Usage:
-h [ --help ] Produce help message
--audio-frame-delay arg (=2) Set audio frame max delay, [0, 8]
-f [ --fullscreen-state ] arg (=none) Set fullscreen state, can be one of
{none, real, fake}
-l [ --list-hardware-decoder ] List hardware decoder
-d [ --hardware-decoder ] arg Set hardware decoder
-r [ --remote-host ] arg (=127.0.0.1) Set remote host
-p [ --remote-port ] arg (=8080) Set remote port
--top-most arg Keep the main window always on top
-u [ --username ] arg Set username
--verification-code arg Set verification code
--volume arg (=100) Set volume, [0, 100]
```
### cgs
A WebRTC server works together with `cge`, to serve web clients.
## 4. Setting Up Your Build Environment
### 4.1 VS2019
[Reference .vsconfig](doc/.vsconfig)
![VS2019](doc/vs2019.jpg)
### 4.2 Boost
Install [Boost](https://www.boost.org/) and set `BOOST_ROOT` environment variable to install directory. [Details](https://blog.umu618.com/2020/09/11/umutech-boost-1-installation/)
Boost compile command:
```
# For MTRelease configuration
.\b2 --address-model=64 runtime-link=static
```
Video Reference (Chinese):
- [06-Regame Cloud Gaming Engine FAQ: Compile Boost](https://www.bilibili.com/video/BV1P5411J7L8/) - bilibili
- [06-Regame Cloud Gaming Engine FAQ: Compile Boost](https://www.ixig
没有合适的资源?快使用搜索试试~ 我知道了~
基于c++ + VS2019开发的云游戏引擎工程
共211个文件
h:51个
cpp:36个
c:22个
需积分: 5 0 下载量 113 浏览量
2021-11-01
17:47:10
上传
评论
收藏 1.25MB ZIP 举报
温馨提示
基于c++ + VS2019开发的云游戏引擎工程
资源推荐
资源详情
资源评论
收起资源包目录
基于c++ + VS2019开发的云游戏引擎工程 (211个子文件)
HookSpecific_x64.asm 10KB
HookSpecific_x86.asm 7KB
itab.c 277KB
thread.c 61KB
decode.c 30KB
yuv.c 28KB
barrier.c 19KB
install.c 18KB
reloc.c 17KB
stealth.c 14KB
caller.c 13KB
udis86.c 13KB
uninstall.c 7KB
syn-intel.c 7KB
syn.c 6KB
syn-att.c 6KB
acl.c 6KB
alloc.c 5KB
error.c 5KB
service.c 5KB
string.c 4KB
memory.c 4KB
dllmain.c 3KB
file.c 2KB
.clang-format 706B
.clang-tidy 2KB
MTRelease-x64.cmd 425B
Release-x64.cmd 425B
Release-x64.cmd 425B
MTRelease-x64.cmd 425B
device.cpp 48KB
hook_dxgi.cpp 30KB
cgvhid_client.cpp 29KB
hook_d3d9.cpp 19KB
cge.cpp 18KB
video_encoder.cpp 16KB
sdl_hack.cpp 16KB
entry.cpp 15KB
debug.cpp 14KB
audio_encoder.cpp 13KB
game_control.cpp 13KB
sound_capturer.cpp 12KB
hook_d3d9.cpp 9KB
game_session.cpp 9KB
captureyuv.cpp 8KB
cgvhid_test.cpp 8KB
audio_resampler.cpp 7KB
manual_video_source.cpp 7KB
cgvhid.cpp 7KB
cgi.cpp 7KB
video_source.cpp 6KB
engine.cpp 5KB
game_service.cpp 5KB
gacutil.cpp 5KB
authenticator.cpp 4KB
driver.cpp 4KB
vigem_client.cpp 3KB
driver.cpp 2KB
dllmain.cpp 2KB
dllmain.cpp 1KB
process.cpp 1KB
cgvhid_reset.cpp 778B
cgc.cpp 616B
pch.cpp 611B
pch.cpp 611B
pch.cpp 17B
EasyHook.def 1KB
devcon-LICENSE 3KB
devcon.exe 82KB
devcon.exe 75KB
EasyHookDll.vcxproj.filters 7KB
cge.vcxproj.filters 4KB
cgc.vcxproj.filters 3KB
captureyuv.vcxproj.filters 2KB
cgvhid.vcxproj.filters 2KB
d3d9yuv.vcxproj.filters 2KB
cgvhid_test.vcxproj.filters 1KB
cgvhid_reset.vcxproj.filters 1KB
cgi.vcxproj.filters 1KB
manual_video_source.vcxproj.filters 1KB
video_source.vcxproj.filters 1KB
yuv.vcxproj.filters 1KB
.gitignore 54B
.gitmodules 112B
cg.gv 967B
regame-authenticator.gv 571B
cgi.gv 442B
sdl_internal.h 26KB
itab.h 15KB
easyhook.h 13KB
cgvhid.h 13KB
types.h 7KB
vhid_common.h 7KB
string.h 6KB
decode.h 5KB
DriverShared.h 5KB
protocol.h 4KB
rtl.h 4KB
extern.h 4KB
hook_d3d9.h 4KB
共 211 条
- 1
- 2
- 3
资源评论
do622
- 粉丝: 5
- 资源: 48
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功