| 更新: | 2024-05-20 |
|---|---|
| 作者: | @voluntas |
| バージョン: | 2024.1 |
| URL: | https://voluntas.github.io/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using UnityEngine; | |
| using UnityEngine.UI; | |
| using System.Collections.Generic; | |
| public class UILineRenderer : Graphic | |
| { | |
| [SerializeField] Texture m_Texture; | |
| [SerializeField] Rect m_UVRect = new Rect(0f, 0f, 1f, 1f); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| * 平行光源の光の強さは、光源の方向のみに依存するので、各頂点の明るさは、法線 n と、光源の方向 l の内積(の関数)になります。 | |
| * 反射光の光の強さは、ライトベクトルと視線への反射ベクトルのハーフベクトルと面法線の内積で計算します。 | |
| * 環境光は計算量が多いので、単に色を乗せるだけで済ませます。 | |
| ※ライトベクトルおよび視線の反射ベクトルは、モデルの回転に対する逆行列を掛けることで正しく表示されます。 | |
| ライトが固定して、ポリゴンが回る=ポリゴンを固定して、ライトを逆方向に回す | |
| ``` | |
| <script id="vs" type="x-shader/x-vertex"> | |
| attribute vec3 position; // 頂点属性:頂点座標位置 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /***************************************************************************** | |
| * directsound.c: DirectSound audio output plugin for VLC | |
| ***************************************************************************** | |
| * Copyright (C) 2001-2009 VLC authors and VideoLAN | |
| * $Id: 2f5b9f46d3739e513d875b950eaf4d2df641f9dc $ | |
| * | |
| * Authors: Gildas Bazin <[email protected]> | |
| * | |
| * This program is free software; you can redistribute it and/or modify it | |
| * under the terms of the GNU Lesser General Public License as published by |
| 更新: | 2022-03-18 |
|---|---|
| 作者: | @voluntas |
| バージョン: | 2022.1 |
| URL: | http://voluntas.github.io/ |
Get Git log in JSON format
git log --pretty=format:'{%n "commit": "%H",%n "abbreviated_commit": "%h",%n "tree": "%T",%n "abbreviated_tree": "%t",%n "parent": "%P",%n "abbreviated_parent": "%p",%n "refs": "%D",%n "encoding": "%e",%n "subject": "%s",%n "sanitized_subject_line": "%f",%n "body": "%b",%n "commit_notes": "%N",%n "verification_flag": "%G?",%n "signer": "%GS",%n "signer_key": "%GK",%n "author": {%n "name": "%aN",%n "email": "%aE",%n "date": "%aD"%n },%n "commiter": {%n "name": "%cN",%n "email": "%cE",%n "date": "%cD"%n }%n},'The only information that aren't fetched are:
%B: raw body (unwrapped subject and body)%GG: raw verification message from GPG for a signed commit
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def Process.gsub pat, sub | |
| mem = File.open('/proc/self/mem', 'r+') | |
| maps = File.open('/proc/self/maps') | |
| maps.each do |map| | |
| from, to, perms, offset = map.scan(/(\h+)-(\h+) (\S+) (\h+)/)[0] | |
| if perms['rw'] | |
| from, to = [from, to].map { |addr| addr.hex + offset.hex } | |
| data = mem.tap { |m| m.seek from }.read(to - from) rescue next |
WebRTC スタックについて
| 作: | @voluntas |
|---|---|
| バージョン: | 0.0.3 |
| url: | https://voluntas.github.io/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Retrieves all the rows in the active spreadsheet that contain data and logs the | |
| * values for each row. | |
| * For more information on using the Spreadsheet API, see | |
| * https://developers.google.com/apps-script/service_spreadsheet | |
| */ | |
| function readRows() { | |
| var sheet = SpreadsheetApp.getActiveSheet(); | |
| var rows = sheet.getDataRange(); | |
| var numRows = rows.getNumRows(); |