- 1,111
- 47
- 420
Крч есть у меня такой вот код:
Да, да тригеритесь на скалу. Суть в том что он должен был бы загрузить картинку из потока, но он тупа даже не входит в метод read (
Scala:
override def bindTexture(resource: Resource): Unit = {
if (!resource.isTexture) throw new RuntimeException(s"$resource is not a texture")
textures.get(resource) match {
case Some(texture) =>
texture.bindAsTexture()
case None =>
getInput(resource) match {
case Some(input) =>
val image = ImageIO.read(input)
val unit = image.toGLTexture
textures.put(resource, unit)
unit.bindAsTexture()
case None =>
bindTexture(emo)
}
}
}
ImageIO.read(input)
). Вопрос собсвенна пачему?