mono

Unity打包WebGL所遇到的坑!!!

被刻印的时光 ゝ 提交于 2020-07-28 09:25:46
WebGL打包过程可真是异常坎坷,开发过程中会有各种坑,大概总结了一下,记录下来。 网络请求问题: 1.Http请求使用C#中请求方式,是不支持的,必须使用Unity的Http请求UnityWebRequest/WWW方式。 using (var webRequest = UnityWebRequest.Get("https://www.baidu.com/")) { yield return webRequest.SendWebRequest(); if (!webRequest.isNetworkError && !webRequest.isHttpError) Debug.Log(webRequest.downloadHandler.text); } using (var webRequest = UnityWebRequest.Post("https://www.baidu.com/","参数")) { yield return webRequest.SendWebRequest(); if (!webRequest.isNetworkError && !webRequest.isHttpError) Debug.Log(webRequest.downloadHandler.text); } 2.经常出现的问题就是跨域问题,开发过Web的人员都知道怎么解决

.NET Core 对龙芯的支持情况和对 .NET Core 开发嵌入式的思考

谁都会走 提交于 2020-07-28 08:33:15
.NET Core 对龙芯的支持情况和对 .NET Core 开发嵌入式的思考 目录 .NET Core 对龙芯的支持情况和对 .NET Core 开发嵌入式的思考 一,遗憾的尝试 二,.NET Core在嵌入式下的几点不足 1,不支持前几年的CPU 2,测试的硬件设备较少 3,支持兼容的系统版本较少 4,体积依然太大 5,依赖库比较伤脑筋 三,.NET Core 龙芯移植的进展和资料 一,遗憾的尝试 前些天看到了张队公众推送的《 Asp.Net终于可以在龙芯服务器上运行啦:Jexus成功完成对国产系列CPU的适配 》,联想到上一周与朋友在龙芯捣鼓 .NET Core,就想写一下关于 .NET Core 在龙芯下的资料。 Jexus Web Server 能够在龙芯服务器上跑,但是 ASP.NET 呢?.NET Core 呢?安装什么版本的 Mono ?Jexus 作者的文章表达有点模糊呀~ 上一周与朋友在龙芯上面为了部署 .NET 项目,颇费心机。朋友公司中标政府项目,开发好 .NET Core 做的项目后,才发现要部署的服务器是龙芯的,.NET Core 无法在上面运行。 服务器有什么有 Mono 4.x,可以创建简单的 Proparm.cs ,编译出程序,使用 mono xx.exe 运行,可是把项目放进去编译不出来~想编译安装 Mono 6.x 也不行,中间有些过程报错。

WebFlux快速上手

帅比萌擦擦* 提交于 2020-07-24 17:01:36
一、新建项目 示例使用IDEA快速创建基于SpringBoot的工程。 springboot 2.3.1 java 8 WebFlux 必须选用Reactive的库 POM 依赖 <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-webflux</artifactId> </dependency> 二、Controller WebFlux 的Controller 可以沿用SpringMVC 的方式,但是返回结果需要使用Mono或者Flux。 创建一个接口,返回http状态码 import org.springframework.http.HttpStatus; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; import org.springframework.web.server.ServerWebExchange; import

How to set font from file in Pango and Mono

你说的曾经没有我的故事 提交于 2020-06-16 03:03:13
问题 I have simple application that prints text and determines its size in pixels. static void Main(string[] args) { Application.Init(); var screen = Screen.Default; var layout = new Pango.Layout(PangoHelper.ContextGetForScreen(screen)); layout.FontDescription = new FontDescription(); layout.FontDescription.Family = "Times New Roman"; layout.FontDescription.Size = Units.FromPixels(18); layout.SetText("My Text"); int width; int height; layout.GetPixelSize(out width, out height); Console.WriteLine("

Proper way to create a Flux from a list of Mono's

有些话、适合烂在心里 提交于 2020-05-29 13:06:31
问题 Lets say I have a API operation that consumes a List of CustomObjects. For every one of those objects it calls a service method that creates a Mono. How do I create a Flux from those Mono objects in an idiomatic and therefore non-blocking way? What I've come up with for now is this. I changed the method names to better reflect their intended purpose. fun myApiMethod(@RequestBody customObjs: List<CustomObject>): Flux<CustomObject> { return Flux.create { sink -> customObjs.forEach { service

Proper way to create a Flux from a list of Mono's

匆匆过客 提交于 2020-05-29 13:06:23
问题 Lets say I have a API operation that consumes a List of CustomObjects. For every one of those objects it calls a service method that creates a Mono. How do I create a Flux from those Mono objects in an idiomatic and therefore non-blocking way? What I've come up with for now is this. I changed the method names to better reflect their intended purpose. fun myApiMethod(@RequestBody customObjs: List<CustomObject>): Flux<CustomObject> { return Flux.create { sink -> customObjs.forEach { service

Can run program with Mono but not with Visual Studio Mac

六月ゝ 毕业季﹏ 提交于 2020-05-16 03:19:09
问题 So I have a C# program that I'm making in Visual Studio Mac 2019. It uses the SFML.Net framework which depends on a dynamic library: libcsfml-graphics.2.5.0.dylib . Internally, the framework has a method called sfRenderWindow_createUnicode(...) . This method uses a DLLImport for CSFML.graphics . If I run the program in Visual Studio, I get a DllNotFoundException with message csfml-graphics . In my global config file for Mono, I have a DLL Mapping: <dllmap dll="csfml-graphics" target="libcsfml

Unity3D - Build Failed because of “[Unity] ERROR: An asset is marked with HideFlags.DontSave but is included in the build:”

倖福魔咒の 提交于 2020-05-15 05:55:32
问题 Using Unity Cloud Build Service , i my build failed because of "[Unity] ERROR: An asset is marked with HideFlags.DontSave but is included in the build:" error. What I've done so far: 1) i have tried to delete Project Setting and reopen Unity but build is still failed... 2) Change all "Arial" font to custom font on prefab and on all scene, but still failed... Below are compact log of Unity Build Service: 1207: [Unity] WARNING: Shader Unsupported: 'Hidden/BlitToDepth' - Pass '' has no vertex

MySql.Data.MySqlClient.Replication.ReplicationManager throws an System.TypeInitializationException

会有一股神秘感。 提交于 2020-05-08 19:46:02
问题 I'm having trouble with my code to access a MySQL Database. Everytime I try to open my connection, a System.TypeInitializationException is thrown by MySql.Data.MySqlClient.Replication.ReplicationManager . Here is my code: DataTable results = new DataTable("Results"); using (MySqlConnection connection = new MySqlConnection("SERVER=127.0.0.1;DATABASE=foo;UID=bar;PASSWORD=foobar;")) { using (MySqlCommand command = new MySqlCommand(queryString, connection)) { command.Connection.Open(); //throws

C# The type or namespace name `List' could not be found. But I'm importing System.Collections.Generic;

橙三吉。 提交于 2020-05-07 21:22:54
问题 I'm having an error The type or namespace name `List' could not be found. Are you missing a using directive or an assembly reference? Sample code: using UnityEngine; using System.Collections; using System.Collections.Generic; public class city1 : MonoBehaviour { public static List<string> items = new List (); public static List<double> itemsprice = new List(); public static List<double> qu = new List(); } I'm using mono if it matters. 回答1: The issue comes from your instantiation of new List()