![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
c#
会思考的猴子
这个作者很懒,什么都没留下…
展开
-
PHP服务器 c#客户端 UDPSocket 连接
php命令行 需要将你的php添加到环境变量PHPserver:<?php// error_reporting(E_ALL | E_STRICT);// $socket = socket_create(AF_INET, SOCK_DGRAM, SOL_UDP);// socket_bind($socket, '192.168.0.110', 9000);// $from = '';// $port = 0;// $msg = "nosubscriber";// wh..原创 2021-01-21 14:20:07 · 327 阅读 · 0 评论 -
C# socket 异步
服务器using System;using System.Collections.Generic;using System.IO;using System.Linq;using System.Net;using System.Net.Sockets;using System.Text;using System.Threading;namespace Server{ ...原创 2019-07-11 22:51:51 · 404 阅读 · 0 评论 -
C# 调用命令行执行Cmd命令
1.不知道为啥 process.StartInfo.Arguments = "/c" + "start D:/Tim/Bin/QQScLauncher.exe"; 这个执行命令一定要加/c ,/c ,/c,重要的事说3遍 才能正常编译并运行cmd /c dir:是执行完dir命令后关闭命令窗口;cmd /k dir:是执行完dir命令后不关闭命令窗口。 process.Sta...原创 2018-11-17 18:12:41 · 6419 阅读 · 0 评论 -
Ffmpeg 将视频分解成多张图片以及多张图片合成视频
1.将视频分解成多张图片-y 覆盖以前的图片%04d 输出的图片的命名格式ffmpeg -y -i Desktop/FfmpegVideos/10.avi Desktop/FfmpegImages/%04d.png 2.多张图片合成视频 只是将上面视频分解的 图片 和 视频的文件路径替换一下就行了-framerate 帧率ffmpeg -y -framer...原创 2018-11-17 17:38:37 · 9617 阅读 · 0 评论 -
ios端无法播放mp3音频 ffmpeg mp3 转aac
最近用到ffmpeg,需要把mp3转成aac,调用以下命令参数: 如果不加 -strict experimental ios端可能播放MP3音频失败ffmpeg -i xxx.mp3 -acodec aac -strict experimental -ab 128k -ar 16k -ac 2 -y xxx.aac参数定义:ab :码率ar :采样率ac :声道 ...原创 2018-09-15 11:31:02 · 1740 阅读 · 0 评论 -
c# 图片转Base64 Base64转图片
先将图片转成 Base64 转成图片,再将 return 回来的 base64Str 直接赋值给 Base64ToImage(string base64) 函数(图片转出来的 base64 太长 我就不贴了,记得将图片路劲换成自己图片的路径哦,GoodNight!) static void Main(string[] args) { // 脸部识别...原创 2018-09-28 21:11:28 · 17563 阅读 · 2 评论 -
VS2017增加c#控制台应用程序的模板
1. 找到你的 VS 安装程序2. 打开后 勾选 .NET 桌面开发3.重启原创 2018-09-28 20:48:27 · 3108 阅读 · 1 评论 -
c# 字符串分割
string[] configAry; configAry = s.Trim().Split(',');原创 2018-10-12 17:36:48 · 802 阅读 · 0 评论 -
Unity tcp 聊天室
1.服务端using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Threading.Tasks;using System.Net.Sockets;using System.Net;using System.Threading;/// <...原创 2018-10-11 10:08:07 · 544 阅读 · 0 评论 -
c#编写一个程序,用while语句,求出 1+(1+2)+(1+2+3)+...+(1+2+3+...+10)之和
int i = 1, j = 1, s = 0, s1 = 0;while (j <= 10) {while (i <= j) {s += i;i++;}s1 += s;j++;}Console.WriteLine (s1);// ! 注意 这里的 / 号 要使用 float 类型;不能使用 int 类型// 编一个程序,用whil...原创 2018-09-19 17:33:59 · 10326 阅读 · 0 评论 -
C# 中取绝对值的函数
System.Math.Abs(float value);原创 2018-09-19 16:33:11 · 32920 阅读 · 0 评论 -
C# 获取指定文件夹下的所有文件名
比较经常用的是第二种 String path = @"X:\xxx\xxx"; //第一种方法获取指定格式 var files = Directory.GetFiles(path, "*.txt"); foreach (var file in files) Console.Write...原创 2018-09-18 17:49:13 · 4964 阅读 · 0 评论 -
c# udp
1.接收using System;using System.Collections.Generic;using System.Linq;using System.Net;using System.Net.Sockets;using System.Text;using System.Threading.Tasks;namespace ConsoleApplication1{...原创 2018-08-15 14:48:14 · 1347 阅读 · 0 评论 -
c# ftp
using System;using System.Collections.Generic;using System.IO;using System.Linq;using System.Net;using System.Security.Cryptography;using System.Text;using System.Windows.Forms; class UpL...转载 2018-07-20 20:30:13 · 378 阅读 · 0 评论 -
C#递归加递归乘
using System;namespace Test2{class Recursion{public long mul (long n){//第一种递归乘if (n > 1) {return n * mul (n - 1);} else {return 1;}// 第二种递归乘// if (n == 1 || n == 0原创 2018-01-01 15:57:57 · 398 阅读 · 0 评论