Skip to content

Instantly share code, notes, and snippets.

@kuetsuhara
kuetsuhara / maya2019.txt
Last active August 5, 2022 09:18
Linux Maya 2019 - require Libraries
View maya2019.txt
sudo yum install libssl1.0.0 gcc libssl-dev libjpeg62 alien csh tcsh libaudiofile-dev libglw1-mesa elfutils libglw1-mesa-dev mesa-utils xfstt xfonts-100dpi xfonts-75dpi ttf-mscorefonts-installer libfam0 libfam-dev libcurl4-openssl-dev libtbb-dev
sudo yum install -y mesa-libGLU-devel libXp.x86_64 libXmu.x86_64 libXpm.x86_64 fontconfig-devel libXinerama.x86_64 gamin libXrender libXcomposite gstreamer gstreamer1-plugins-base libXcursor libXtst.x86_64
sudo yum install -y libXrender libXcomposite gstreamer gstreamer1-plugins-base libXcursor libXtst.x86_64
@kuetsuhara
kuetsuhara / bt.html
Last active April 1, 2020 13:39
さくっと“ガジェット”が作れる!「micro:bit」と「Node-RED」で、超簡単Web Bluetooth通信
View bt.html
<html>
<head>
<title>micro:bit</title>
<script
type="text/javascript"
src="/microbit.js"
></script>
</head>
<body>
<button id="find">find</button>
@kuetsuhara
kuetsuhara / button_listen.js
Last active December 7, 2017 11:46
node-red connect to microbit "button listen"
View button_listen.js
var BBCMicrobit = context.global.microbit
var BUTTON_VALUE_MAPPER = ['Not Pressed', 'Pressed', 'Long Press'];
console.log('Scanning for microbit');
BBCMicrobit.discover(function(microbit) {
console.log('\tdiscovered microbit: id = %s, address = %s', microbit.id, microbit.address);
microbit.on('disconnect', function() {
console.log('\tmicrobit disconnected!');
@kuetsuhara
kuetsuhara / microbit_let_text.js
Last active December 7, 2017 11:10
node-red connet to microbit
View microbit_let_text.js
var BBCMicrobit = context.global.microbit
var text = 'Hello there';
console.log('Scanning for microbit');
BBCMicrobit.discover(function(microbit) {
console.log('\tdiscovered microbit: id = %s, address = %s', microbit.id, microbit.address);
microbit.on('disconnect', function() {
console.log('\tmicrobit disconnected!');
});
View example.json
{"Entries":
[
{
"Name": "a",
"BC": 0,
"LN": 121.45,
"RT": 1.47197,
"SC": 1
},
{
View AFileLoad.m
void AFileLoad::BeginPlay(){
Super::BeginPlay();
// Load
FString aFullPath = FPaths::GameSavedDir();
aFullPath += "example.json";
FString JsonStr;
FFileHelper::LoadFileToString(JsonStr, *aFullPath);
View HelloWorld.h
#pragma once
#include "GameFramework/Actor.h"
#include "Http.h"
#include "HelloWorld.generated.h"
/**
*
*/
UCLASS()
View skyboxmeshCustom
public void Change( Material skybx ){
// 表示されているmeshを削除
GameObject[] examples = GameObject.FindGameObjectsWithTag("SkyMesh");
for( int i = 0; i < examples.Length; i++){
Destroy(examples[i]);
}
// 新たにメッシュを設定
this.material = null;
View CiuchbaseLiteSync
//まずは、以下のプロパティを宣言します。
@property (nonatomic, strong) CBLReplication *pull;
@property (nonatomic, strong) CBLReplication *push;
//そして、以下のようなメソッドを作ります。
- (void)syncServer{
// sync method
AppDelegate *ap = ApplicationDelegate;
View CoucbaseLite sync Notif
- (void) observeValueForKeyPath:(NSString *)keyPath
ofObject:(id)object
change:(NSDictionary *)change
context:(void *)context
{
// push & pull Action
if (object == self.pull || object == self.push) {
// レプリケーションモードを取得