Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
puregoの活用例
Search
aethiopicuschan
March 28, 2024
Programming
0
240
puregoの活用例
EbitengineぷちConf #2での発表資料
aethiopicuschan
March 28, 2024
Tweet
Share
More Decks by aethiopicuschan
See All by aethiopicuschan
EbitengineでGUIツール作ってみた
aethiopicuschan
0
2.1k
Other Decks in Programming
See All in Programming
Scalable Customer Journey Orchestration (CJO)
lewuathe
0
370
DMMプラットフォームがTiDB Cloudを採用した背景
pospome
9
4.1k
障害対応を起点としたもっといい開発と運用のサイクル作りのためにできること / Hatena Enginner Seminar #29
polamjag
0
270
Random\Randomizer クラスで日常のあれこれを解決しよう! / Random\Randomizer class solves familiar trouble
cocoeyes02
0
250
Fragment Composition of GraphQL
quramy
7
1.1k
Tailwind CSSを本気でカスタマイズする方法
fsubal
14
5.4k
Polars入門
daikikatsuragawa
1
110
if constexpr文はテンプレート世界のラムダ式である
faithandbrave
3
660
TCAとKMPを用いた新規動画配信アプリ 「ABEMA Live」の設計
tomu28
1
120
Prepare for Jakarta EE 11 - Performance and Developer Productivity
ivargrimstad
0
940
R言語の環境構築と基礎 Tokyo.R 112
bob3bob3
0
270
二郎系ラーメンのコールで学ぶ AST 解析
memory1994
PRO
7
1.7k
Featured
See All Featured
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
245
20k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
660
120k
Build The Right Thing And Hit Your Dates
maggiecrowley
25
2k
Designing on Purpose - Digital PM Summit 2013
jponch
111
6.5k
Gamification - CAS2011
davidbonilla
76
4.6k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
22
1.6k
From Idea to $5000 a Month in 5 Months
shpigford
378
45k
Navigating Team Friction
lara
179
13k
Building Adaptive Systems
keathley
32
1.9k
How GitHub (no longer) Works
holman
305
140k
StorybookのUI Testing Handbookを読んだ
zakiyama
13
4.6k
Robots, Beer and Maslow
schacon
PRO
155
7.9k
Transcript
$IBO"FUIJPQJDVT&CJUFOHJOFͪ$POG QVSFHPͷ׆༻ྫ
ࣗݾհ w νϟϯɾΤνΦϐΫεͱਃ͠·͢ɻ w ҩྍܥϕϯνϟʔͰαʔόαΠυͷΤϯδχΞΛ͓ͯ͠Γ·͢ɻ w લճͷͪ$POGͰ-5͍͖ͤͯͨͩ͞·ͨ͠ɻ w IUUQTHJUIVCDPNBFUIJPQJDVTDIBO
QVSFHPͱͳʹ͔ w DHPΛΘͳ͘ͱ$ͷ͕ؔୟ͚Δʂ w IUUQTHJUIVCDPNFCJUFOHJOFQVSFHP
QVSFHPͱͳʹ͔ αϯϓϧίʔυ package main import ( "fmt" "runtime" "github.com/ebitengine/purego" )
func getSystemLibrary() string { switch runtime.GOOS { case "darwin": return "/usr/lib/libSystem.B.dylib" case "linux": return "libc.so.6" default: panic(fmt.Errorf("GOOS=%s is not supported", runtime.GOOS)) } } func main() { libc, err := purego.Dlopen(getSystemLibrary(), purego.RTLD_NOW|purego.RTLD_GLOBAL) if err != nil { panic(err) } var puts func(string) purego.RegisterLibFunc(&puts, libc, "puts") puts("Calling C from Go without Cgo!") } FCJUFOHJOFQVSFHPͷ3&"%.&͔ΒҾ༻
׆༻ྫͦͷ OBOPEBWPJDFWPYDPSFΛར༻͢ΔϥΠϒϥϦ w ʮͣΜͩΜʯͳͲͰ༗໊ͳ70*$&709ͷίΞϥΠϒϥϦΛୟ͘ɻ w JP3FBE$MPTFSͱͯ͠ѻ͑ΔXBWϑΝΠϧΛग़ྗ͢Δ͜ͱ͕Ͱ͖Δɻ w IUUQTHJUIVCDPNBFUIJPQJDVTDIBOOBOPEB
׆༻ྫͦͷ $VCJTN(P6OP ff i DJBM-JWF%$VCJTN4%,GPS(PMBOH w -JWF%ͷ$VCJTN$PSFϥΠϒϥϦΛୟ͘ɻ w &CJUFOHJOF͚ͷϨϯμϥΛ࣮ࡁΈɻ w
ຊͷۄʂ w IUUQTHJUIVCDPNBFUIJPQJDVTDIBODVCJTNHP
$VCJTN4%,ͷߏ IUUQTEPDTMJWFEDPNDVCJTNTELNBOVBMDVCJTNDPSFBQJSFGFSFODFΑΓҾ༻
׆༻ྫͦͷ $VCJTN(P6OP ff i DJBM-JWF%$VCJTN4%,GPS(PMBOH w σϞΛߦ͍·͢ɻ