自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(4)
  • 资源 (2)
  • 收藏
  • 关注

转载 给struct或union成员两个名称,其中一个用数组元素表示

#include struct Point2d{ union { float pos[3]; struct { float x, y, w; }; };};void main(){ // 1.pos[]数组和x, y, w使用同一片区域,这就使每个分量有了两个名字pos[0] = x, pos[1] = y, pos[2] = w Point2d p2

2016-12-23 19:19:10 645

转载 stl中的全排列算法

1. 需先排序,从小到大用next_permutation float c[] = {1.2f, 32.2f, -1.3f}; std::sort(c, c + 3); do { printf("%.2f %.2f %.2f\n", c[0], c[1], c[2]); } while (std::next_permutation(c, c + 3));2. 从大到小

2016-12-18 09:45:28 295

原创 四面体简单光照渲染+漫游(使用多个ConstantBuffer减小带宽)

建立了三个ConstantBuffer,一个是每一帧都需要从cpu传过来的用来旋转的world矩阵,一个是摄影机操作后传过来的view矩阵,还有一个是只传过来一次的projection矩阵和两个方向光的向量1.lighting.fx// Constant Buffer Variablescbuffer CBChangesEveryFrame : register( b0 ){ mat

2016-12-13 13:15:47 1864

原创 D3D11四面体简单方向光光照渲染

初始化设备大致分这几个步骤:1.Create device2.Create swap chain3.Create a render target view4.Create depth stencil texture5.Create the depth stencil view6.Setup the viewport7.Compile and create the ver

2016-12-12 13:36:32 1120

MySQL-8.0.12下载安装配置方法

1. 下载 2. 解压 3. 环境变量Path加 D:\Program Files\mysql-8.0.12-winx64\bin 4. 在文件夹下新建data文件夹,my.ini文件,my.ini内容为 [mysqld] # 设置3306端口 port=3306 # 设置mysql的安装目录 basedir=D:\Program Files\mysql-8.0.12-winx64 # 设置mysql数据库的数据的存放目录 datadir=D:\Program Files\mysql-8.0.12-winx64\data # 允许最大连接数 max_connections=200 # 允许连接失败的次数。 max_connect_errors=10 # 服务端使用的字符集默认为UTF8 character-set-server=utf8 # 创建新表时将使用的默认存储引擎 default-storage-engine=INNODB # 默认使用“mysql_native_password”插件认证 #mysql_native_password default_authentication_plugin=mysql_native_password [mysql] # 设置mysql客户端默认字符集 default-character-set=utf8 [client] # 设置mysql客户端连接服务端时默认使用的端口 port=3306 default-character-set=utf8 5. mysqld --initialize --console,记下密码 MySQL下载安装配置 分区 MySQL下载安装配置 的第 1 页 6. 管理员模式运行cmd到MySQL根目录运行 mysqld --install 7. 管理员模式cmd到根目录运行net start mysql启动服务,net stop mysql停止服务,可创建管理员模式批处理命令(start mysql service.bat)形如 @echo off >nul 2>&1 "%SYSTEMROOT%\system32\cacls.exe" "%SYSTEMROOT%\system32\config\system" if '%errorlevel%' NEQ '0' ( goto UACPrompt ) else ( goto gotAdmin ) :UACPrompt echo Set UAC = CreateObject^("Shell.Application"^) > "%temp%\getadmin.vbs" echo UAC.ShellExecute "%~s0", "", "", "runas", 1 >> "%temp%\getadmin.vbs" "%temp%\getadmin.vbs" exit /B :gotAdmin if exist "%temp%\getadmin.vbs" ( del "%temp%\getadmin.vbs" ) net start mysql pause

2018-10-17

MySQL8.0.12下载安装配置方法

1. 下载 2. 解压 3. 环境变量Path加 D:\Program Files\mysql-8.0.12-winx64\bin 4. 在文件夹下新建data文件夹,my.ini文件,my.ini内容为 [mysqld] # 设置3306端口 port=3306 # 设置mysql的安装目录 basedir=D:\Program Files\mysql-8.0.12-winx64 # 设置mysql数据库的数据的存放目录 datadir=D:\Program Files\mysql-8.0.12-winx64\data # 允许最大连接数 max_connections=200 # 允许连接失败的次数。 max_connect_errors=10 # 服务端使用的字符集默认为UTF8 character-set-server=utf8 # 创建新表时将使用的默认存储引擎 default-storage-engine=INNODB # 默认使用“mysql_native_password”插件认证 #mysql_native_password default_authentication_plugin=mysql_native_password [mysql] # 设置mysql客户端默认字符集 default-character-set=utf8 [client] # 设置mysql客户端连接服务端时默认使用的端口 port=3306 default-character-set=utf8 5. mysqld --initialize --console,记下密码 MySQL下载安装配置 分区 MySQL下载安装配置 的第 1 页 6. 管理员模式运行cmd到MySQL根目录运行 mysqld --install 7. 管理员模式cmd到根目录运行net start mysql启动服务,net stop mysql停止服务,可创建管理员模式批处理命令(start mysql service.bat)形如 @echo off >nul 2>&1 "%SYSTEMROOT%\system32\cacls.exe" "%SYSTEMROOT%\system32\config\system" if '%errorlevel%' NEQ '0' ( goto UACPrompt ) else ( goto gotAdmin ) :UACPrompt echo Set UAC = CreateObject^("Shell.Application"^) > "%temp%\getadmin.vbs" echo UAC.ShellExecute "%~s0", "", "", "runas", 1 >> "%temp%\getadmin.vbs" "%temp%\getadmin.vbs" exit /B :gotAdmin if exist "%temp%\getadmin.vbs" ( del "%temp%\getadmin.vbs" ) net start mysql pause

2018-10-17

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除