摘要: 问题: 如何让两个透明视频叠加播放 解决播放: 1:使用Unity自带的shader,shader代码如下所示 2:准备好格式为两个mp4的视频文件,并且提前下载安装好QuickTime,导入Unity当中,将视频文件由Videoclip改为MovieTexture 3:建立新的Material材质 阅读全文
posted @ 2019-06-25 14:46 玄~轩逸 阅读(949) 评论(0) 推荐(0) 编辑
摘要: 问题: Unity中实现播放透明的MP4视频时出现黑点 解决办法: 使用Unity自带的shader去除黑点 1:shader代码如下所示 2:准备好格式为mp4的视频文件,并且提前下载安装好QuickTime,导入Unity当中,将视频文件由Videoclip改为MovieTexture 3:建立 阅读全文
posted @ 2019-06-25 14:37 玄~轩逸 阅读(2981) 评论(0) 推荐(0) 编辑
摘要: 问题: 当使用Video Player播放带有alpha 通道的视频时带有黑色背景 解决方式: 使用文件格式为WEBM的视频,对视频文件进行的修改 在RawImage中,将New Render Texture以及视频添加进去,就能正常播放透明视频了 阅读全文
posted @ 2019-06-25 09:20 玄~轩逸 阅读(2859) 评论(0) 推荐(0) 编辑
摘要: 问题: 强制设置程序运行的分辨率 解决办法: 在程序开始运行时就对分辨率进行设定 设定方法如下: void GetResolution() { int width = Screen.currentResolution.width; int height = Screen.currentResolut 阅读全文
posted @ 2019-05-31 14:17 玄~轩逸 阅读(787) 评论(0) 推荐(0) 编辑
摘要: private string GetRegistData(string name) { string registData; RegistryKey hkml = Registry.CurrentUser; RegistryKey software = hkml.OpenSubKey("Software", true); ... 阅读全文
posted @ 2019-05-31 13:38 玄~轩逸 阅读(1000) 评论(0) 推荐(0) 编辑
摘要: using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Threading.Tasks; using Sys... 阅读全文
posted @ 2019-05-28 13:40 玄~轩逸 阅读(323) 评论(0) 推荐(0) 编辑
摘要: 1:button控件的生成方式 Button button = new Button(); button.Size = new Size(80, 80); button.Location = new Point(10, 10); button.Text = "aa"; this.Controls.A 阅读全文
posted @ 2019-05-28 10:30 玄~轩逸 阅读(341) 评论(0) 推荐(0) 编辑
摘要: public void GetRay(){ public float range = 100f; Ray shootRay = new Ray(); RaycastHit shootHit; int shootableMask; shootableMask = LayerMask.GetMask... 阅读全文
posted @ 2019-05-24 10:55 玄~轩逸 阅读(187) 评论(0) 推荐(0) 编辑
摘要: using UnityEngine; using System.Collections; using System; using System.Net; using System.Net.Mail; using System.Net.Security; using System.Security.Cryptography.X509Certificates; public class... 阅读全文
posted @ 2019-05-24 10:55 玄~轩逸 阅读(433) 评论(0) 推荐(0) 编辑
摘要: //解析和输出XML public void showXml() { string filepath = Application.dataPath + @"/my.xml"; if(File.Exists (filepath)) { XmlDocument xmlDoc = new XmlDocument(); xmlDoc.Load(filepath); ... 阅读全文
posted @ 2019-05-24 10:54 玄~轩逸 阅读(187) 评论(0) 推荐(0) 编辑