Skip to content

Commit

Permalink
⬆️
Browse files Browse the repository at this point in the history
- Kotlin 1.2.30 eap 16
- Gradle 4.5.1
- Lwjgl 3.1.6
  • Loading branch information
elect86 committed Feb 15, 2018
1 parent 075265e commit b674928
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 deletions.
6 changes: 3 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ apply plugin: 'com.github.johnrengelman.shadow'

buildscript {

ext.kotlinVersion = '1.2.21'
ext.kotlinVersion = '1.2.30-eap-16'

repositories {
jcenter() // shadow
Expand All @@ -31,7 +31,7 @@ dependencies {

compile "org.jetbrains.kotlin:kotlin-stdlib:$kotlinVersion"

compile 'com.github.kotlin-graphics:gli:0cfe6c23ec96604e80574ae795d34b99bd45fe19'
compile 'com.github.kotlin-graphics:gli:cb51db0be2c0e1b720859f27c1ed338ab38715f6'

testCompile 'io.kotlintest:kotlintest:2.0.7'

Expand All @@ -46,7 +46,7 @@ dependencies {
ext.lwjglNatives = "natives-macos"
break
}
ext.lwjglVersion = "3.1.5-SNAPSHOT"
ext.lwjglVersion = "3.1.6-SNAPSHOT"
compile "org.lwjgl:lwjgl:${lwjglVersion}"
compile "org.lwjgl:lwjgl-glfw:${lwjglVersion}"
compile "org.lwjgl:lwjgl-jemalloc:${lwjglVersion}"
Expand Down
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-4.4.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-4.5.1-bin.zip
4 changes: 2 additions & 2 deletions src/main/kotlin/gln/buffer/block.kt
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ object Buffer {
inline fun bindBase(index: Int) = GL30.glBindBufferBase(target, index, 0)

inline fun mapRange(length: Int, access: Int) = mapRange(0, length, access)
inline fun mapRange(offset: Int, length: Int, access: Int): ByteBuffer = GL30.glMapBufferRange(target, offset.L, length.L, access)
inline fun mapRange(offset: Int, length: Int, access: Int) = GL30.glMapBufferRange(target, offset.L, length.L, access)

inline fun flushRange(length: Int) = flushRange(0, length)
inline fun flushRange(offset: Int, length: Int) = GL30.glFlushMappedBufferRange(target, offset.L, length.L)
Expand Down Expand Up @@ -233,7 +233,7 @@ object MappedBuffer {
}

fun mapRange(length: Int, access: Int) {
buffer = GL30.glMapBufferRange(target, 0L, length.L, access)
buffer = GL30.glMapBufferRange(target, 0L, length.L, access)!!
}

lateinit var buffer: ByteBuffer
Expand Down
12 changes: 6 additions & 6 deletions src/main/kotlin/gln/buffer/map.kt
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ import org.lwjgl.opengl.GL45
import java.nio.ByteBuffer


fun glMapBufferRange(target: Int, length: Long, access: Int): ByteBuffer = GL30.glMapBufferRange(target, 0, length.L, access)
fun glMapBufferRange(target: Int, length: Int, access: Int): ByteBuffer = GL30.glMapBufferRange(target, 0, length.L, access)
fun glMapBufferRange(target: Int, offset: Int, length: Int, access: Int): ByteBuffer = GL30.glMapBufferRange(target, offset.L, length.L, access)
fun glMapBufferRange(target: Int, length: Long, access: Int) = GL30.glMapBufferRange(target, 0, length.L, access)
fun glMapBufferRange(target: Int, length: Int, access: Int) = GL30.glMapBufferRange(target, 0, length.L, access)
fun glMapBufferRange(target: Int, offset: Int, length: Int, access: Int) = GL30.glMapBufferRange(target, offset.L, length.L, access)

fun ByteBuffer.glMapBufferRange(target: Int, length: Long, access: Int): ByteBuffer = GL30.glMapBufferRange(target, 0, length.L, access, this)
fun ByteBuffer.glMapBufferRange(target: Int, length: Int, access: Int): ByteBuffer = GL30.glMapBufferRange(target, 0, length.L, access, this)
fun ByteBuffer.glMapBufferRange(target: Int, offset: Int, length: Int, access: Int): ByteBuffer = GL30.glMapBufferRange(target, offset.L, length.L, access, this)
fun ByteBuffer.glMapBufferRange(target: Int, length: Long, access: Int) = GL30.glMapBufferRange(target, 0, length.L, access, this)
fun ByteBuffer.glMapBufferRange(target: Int, length: Int, access: Int) = GL30.glMapBufferRange(target, 0, length.L, access, this)
fun ByteBuffer.glMapBufferRange(target: Int, offset: Int, length: Int, access: Int) = GL30.glMapBufferRange(target, offset.L, length.L, access, this)

fun ByteBuffer.map(target: Int, access: Int) = GL15.glMapBuffer(target, access, this)
fun ByteBuffer.map(target: Int, access: Int, length: Int) = GL15.glMapBuffer(target, access, length.L, this)
Expand Down

0 comments on commit b674928

Please sign in to comment.