View 06_bump_sdl2_metal.rb
# coding: utf-8 | |
# | |
# Ref.: bgfx/examples/06-bump/bump.cpp | |
# https://github.com/vaiorabbit/sdl2-bindings | |
# | |
require 'rmath3d/rmath3d' | |
require 'sdl2' | |
require_relative '../../bindings/ruby/bgfx.rb' | |
require_relative './logo.rb' | |
require_relative './utils.rb' |
View 06_bump_imgui.rb
# coding: utf-8 | |
# | |
# Ref.: bgfx/examples/06-bump/bump.cpp | |
# https://github.com/vaiorabbit/ruby-opengl/tree/master/sample | |
# | |
require 'rmath3d/rmath3d' | |
require 'opengl' | |
require 'glfw' | |
require_relative '../../bindings/ruby/bgfx.rb' | |
require_relative './utils.rb' |
View 06_bump.rb
# | |
# Ref.: bgfx/examples/06-bump/bump.cpp | |
# https://github.com/vaiorabbit/ruby-opengl/tree/master/sample | |
# | |
require 'rmath3d/rmath3d' | |
require 'opengl' | |
require 'glfw' | |
require_relative '../../bindings/ruby/bgfx.rb' | |
require_relative './utils.rb' |
View 01_cubes.rb
# | |
# Ref.: bgfx/examples/01-cubes/cubes.cpp | |
# https://github.com/vaiorabbit/ruby-opengl/tree/master/sample | |
# | |
require 'rmath3d/rmath3d' | |
require 'opengl' | |
require 'glfw' | |
require_relative '../../bindings/ruby/bgfx.rb' | |
require_relative './logo.rb' |
View 00_helloworld.rb
# | |
# Ref.: bgfx/examples/00-helloworld/helloworld.cpp | |
# https://github.com/vaiorabbit/ruby-opengl/tree/master/sample | |
# | |
require 'opengl' | |
require 'glfw' | |
require_relative '../bindings/ruby/bgfx.rb' | |
require_relative './logo.rb' | |
OpenGL.load_lib() |
View bgfx.rb
require 'ffi' | |
# | |
# Typedefs | |
# | |
FFI.typedef :uint16, :Bgfx_view_id_t # [HACK] Hard-coded. Seems we can't get information about this from current 'bgfx.idl'. | |
FFI.typedef :int, :Bgfx_fatal_t |
View launch.json
{ | |
// IntelliSense を使用して利用可能な属性を学べます。 | |
// 既存の属性の説明をホバーして表示します。 | |
// 詳細情報は次を確認してください: https://go.microsoft.com/fwlink/?linkid=830387 | |
"version": "0.2.0", | |
"configurations": [ | |
{ | |
"name": "Debug Local File", | |
"type": "Ruby", | |
"request": "launch", |
View destroy_like.rb
#! /usr/bin/env ruby | |
# coding: utf-8 | |
# Usage: | |
# - Set environment variables 'TWITTER_CONSUMER_KEY', 'TWITTER_CONSUMER_SECRET', 'TWITTER_ACCESS_TOKEN' and 'TWITTER_ACCESS_TOKEN_SECRET' beforehand | |
# - $ ruby destroy_like.rb [tweet id] | |
# Ref.: https://developer.twitter.com/en/docs/tweets/post-and-engage/api-reference/post-favorites-destroy | |
require 'json' |
View launch.json
// Ref.: https://github.com/Microsoft/vscode-go/issues/219#issuecomment-449621513 | |
{ | |
"version": "0.2.0", | |
"configurations": [ | |
/* Configuration for normal debugging | |
{ | |
"name": "Launch", | |
"type": "go", | |
"request": "launch", | |
"mode": "auto", |
View SequenceDiagram3.plantuml
@startuml | |
hide footbox | |
participant ":Order" as O | |
participant "careful : Distributor" as CD | |
participant "regular : Distributor" as RD | |
participant ":Messenger" as M | |
/' skinparam lifelineStrategy solid '/ | |
skinparam lifelineStrategy dashed |
NewerOlder