当前位置:网站首页>KlakNdI 同步画面简单使用
KlakNdI 同步画面简单使用
2022-07-17 02:09:00 【心前阳光】
插件地址
作用
局域网内同步画面
重要脚本
NdiSender:发送视频流;可以设置NdiName;
NdiReceiver:接收视频流;通过设置Ndi Name接收画面;
NdiFinder:查找视频流的NdiName。
实例
- 设置一个用于显示的场景,场景中任一对象挂载NdiSender,打包该场景;
- 设置一个用于接收的场景,场景中任一对象挂载NdiReceiver和NdiTest脚本;添加一个RawImage,用于显示画面;打包该场景;
- 运行打包文件。
using Klak.Ndi;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
//接收画面
public class NdiTest : MonoBehaviour
{
public NdiReceiver ndiReceiver;//接收画面
public RawImage image;//显示接收的画面
List<string> test = new List<string>();
void Update()
{
if (test.Count == 0)
test = (List<string>)NdiFinder.EnumerateSourceNames();//查找 ndiname
if (test.Count > 0)
{
ndiReceiver.ndiName = test[0];//设置ndiname
image.texture = ndiReceiver.texture;//设置纹理 显示画面
}
}
}
边栏推荐
- 【LeetCode】735. 行星碰撞
- XX City high school network topology overall planning configuration
- 神器网站目录,全都是刚需好用的网站
- Browser cannot open tensorboard
- Laravel's problem
- Gnome boxes virtual machine creation and installation
- Dive Into Deep Learning——2.2数据预处理
- 通过Dao投票STI的销毁,SeekTiger真正做到由社区驱动
- Unity using Sqlite
- Local storage localstorage ⽤ method details
猜你喜欢

Edge detection method -- first order edge detection

2022电工杯:5G 网络环境下应急物资配送问题(优化)

Jmeter常用功能-参数化介绍

机器学习库Scikit-Learn(线性模型、岭回归、插入一列数据(insert)、提取所需列、向量机(SVM)、聚类)

基于Matlab的男女声音信号分析与处理

MySQL addition, deletion, query and modification (basic)

leetcode 222. Number of nodes of a complete binary tree (required)

Laravel's problem

GNOME-BOXES虚拟机创建安装

367. Effective complete square (necessary for entry)
随机推荐
Subline快捷操作
Number of supported question banks and examination question banks of swiftui examination question bank project (tutorial includes source code)
波士顿房价分析作业总结
Dive into deep learning - 2.2 data preprocessing
通过OpenHarmony兼容性测评,大师兄开发板与丰富教培资源已ready
How to use iota keyword in go language
Bias and variance
SwiftUI 考试题库项目之支持题库和考试题库数量(教程含源码)
【LeetCode】745. 前缀和后缀搜索
Le cinquième jour de trois questions par jour à luogu
渗透测试-02漏洞扫描
Through openharmony compatibility evaluation, the big brother development board and rich teaching and training resources have been ready
二分查找(leetcode704.很简单必会的)
Operator, assignment statement, structure description statement
Chapter II: news topic classification tasks
MySQL master-slave setup
第二章:新闻主题分类任务
367. Effective complete square (necessary for entry)
Reptile learning (5): teach you reptile requests practice hand in hand
How to paste data in Excel into CXGRID