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
import SwiftUI | |
import RealityKit | |
import Metal | |
struct MetalWavyPlaneView: View { | |
@State private var phase: Float = 0.0 | |
@State private var mesh: LowLevelMesh? | |
@State private var timer: Timer? | |
let resolution = 250 | |
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
import SwiftUI | |
import RealityKit | |
struct WavyPlaneView: View { | |
@State private var phase: Float = 0.0 | |
@State private var mesh: LowLevelMesh? | |
@State private var timer: Timer? | |
let resolution = 60 | |
var body: some View { |
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
#version 150 | |
#define MAX_TEXTURES 2 | |
uniform sampler2DArray textures; | |
uniform int texID; | |
in vec2 vTexCoord; |
-
gcc 4.8
-
Homebrewを使って入れた
brew install https://raw.github.com/Homebrew/homebrew-versions/master/gcc48.rb --enable-all-languages
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
// g++ -g -O0 -Wall -fPIC -I/usr/local/include/ -L/usr/local/lib/ -lmsgpack main.cc -o main | |
#include <iostream> | |
#include <msgpack.hpp> | |
struct Result { | |
public: | |
msgpack::type::raw_ref message; | |
Result() {} | |
MSGPACK_DEFINE( message); |
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
#include <msgpack.hpp> | |
#include <vector> | |
#include <map> | |
#include <iostream> | |
#include <cstdio> | |
struct point_t { | |
float x; | |
float y; | |
float z; |