Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Xsinh/Shloader

Open more actions menu

Repository files navigation

Shloader

Maven Central

Simple lib for loading glsl scripts from row directory

Example

  • No longer need to write scripts in code as String() make glsl-scripts in raw dirctory:

Снимок экрана 2020-04-12 в 18 39 16

  • Now you can simple load scripts by means of static loadShader method
private fun attachShaders() {
        val pointVertexShader: Int =
            loadShader(GLES20.GL_VERTEX_SHADER, R.raw.vertex_shader, context)

        val pointFragmentShader: Int =
            loadShader(GLES20.GL_FRAGMENT_SHADER, R.raw.fragment_shader, context)

        programId = GLES20.glCreateProgram()

        GLES20.glAttachShader(programId, pointVertexShader)
        GLES20.glAttachShader(programId, pointFragmentShader)
        GLES20.glLinkProgram(programId)
    }

Integration

version of 1.0.1 not work, use 1.0.0

repositories {
    // ...
    mavenCentral()
}
dependencies {
    // ...
    implementation 'io.github.xsinh:shloader:1.0.0'
}

About

Simple lib for loading glsl scripts from row directory

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Morty Proxy This is a proxified and sanitized view of the page, visit original site.