Skip to content
프로젝트

소개

Kotlin Multiplatform 3D graphics wrapper for Google's Filament engine, featuring first-class Compose Multiplatform integration across Android, iOS, Desktop, and Web.

디자인 및 미디어

이 수치를 측정하는 방법

측정된 스타 증가

in 24h
+1
in 7 days
+1
in 15 days
+2
in 1 month
+6

서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.

README.md

Original

Filament KMP

Maven Central License Filament Kotlin Compose Multiplatform

Filament KMP brings Google's Filament physically based renderer to Android, iOS, Desktop and Web from one Kotlin API, with an optional Compose Multiplatform layer on top.

▶ Try the live web demo — every sample scene, in your browser.

The same scene rendering on Android, iOS, Desktop and Web
FilamentSceneView(
    modifier       = Modifier.fillMaxSize(),
    cameraState    = rememberCameraState(initialEye = Position(0f, 1f, 4f)),
    postProcessing = PostProcessing(bloom = Bloom(strength = 0.2f)),
) {
    Skybox(color = LinearColor(0.1f, 0.12f, 0.15f))
    IndirectLight(irradiance = SphericalHarmonics.NeutralStudio)   // soft ambient, no file to load
    DirectionalLight(direction = Direction(0.3f, -1f, -0.5f), intensity = LightIntensity.LuminousPower(100_000f))
    GltfInstance(asset = rememberGltfAsset { Res.readBytes("files/Duck.glb") })
}
  • One API everywhere — the Kotlin API is written once in commonMain over a C API generated from Filament's headers, so it behaves the same on every platform.
  • Filament's own API — same classes, names and defaults as Filament's C++ API, so Filament's docs apply directly.
  • Compose optional — filament, gltfio, filament-utils and filamat are plain bindings: drive Engine / Renderer / SwapChain on your own surface, or render headless (guide).

[!NOTE] Unofficial project. A community-maintained wrapper, not affiliated with, endorsed by, or supported by Google or the Filament team.

Platforms

Platform Backend
Android (minSdk 24) OpenGL ES / Vulkan
iOS Metal
Desktop / JVM — macOS 11+, Windows 10+, Linux (glibc 2.38+) Metal / Vulkan / OpenGL, JDK 17+
Web (JS & Wasm) WebGL 2.0

Quick start

// settings.gradle.kts
dependencyResolutionManagement {
    repositories {
        mavenCentral()
        google()
    }
}
// build.gradle.kts
kotlin {
    sourceSets {
        commonMain.dependencies {
            // Compose integration (pulls in the engine), or just "…:filament:0.11.1" without Compose.
            implementation("io.github.erkko68.filament:filament-compose:0.11.1")
        }
    }
}

The same coordinates work on every target. Per-platform setup (iOS linking, Web prebuilts, Desktop natives) is in Getting Started.

Modules

Artifact Description
filament Core renderer — Engine, Scene, View, Renderer, Camera, Texture, Material.
filament-compose Compose Multiplatform integration — FilamentSceneView, scene DSL, camera state, post-processing.
gltfio glTF / GLB loading — AssetLoader, FilamentAsset, Animator.
filamat Runtime material compilation — MaterialBuilder.
filament-utils Camera manipulators, HDR/KTX loaders, math helpers.

All under io.github.erkko68.filament, one shared version. Coordinates and per-target dependencies: Modules.

Documentation

For engine concepts (PBR, lighting, materials), see Filament's own Engine and Materials docs.

Samples & showcase

License

Apache License 2.0. Filament itself is also Apache-2.0 licensed by Google.

관련 프로젝트 살펴보기

불러오는 중…