Where communities thrive

  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
Repo info
  • Oct 09 13:21
    halvnykterist commented #1912
  • Oct 04 21:20
    est31 closed #1962
  • Oct 04 21:20
    est31 commented #1962
  • Oct 03 20:43
    Rami-Slicer commented #1962
  • Oct 03 04:50
    est31 commented #1962
  • Oct 03 03:56
    unlimitedbacon commented #1962
  • Sep 25 02:04
    jvcmarcenes closed #1963
  • Sep 25 01:55
    jvcmarcenes edited #1963
  • Sep 25 01:54
    jvcmarcenes opened #1963
  • Sep 19 05:04
    JerryChCN synchronize #1957
  • Sep 17 19:23
    Rami-Slicer opened #1962
  • Sep 12 18:30

    est31 on master

    Fix texture tutorial color spac… Merge pull request #1961 from d… (compare)

  • Sep 12 18:30
    est31 closed #1961
  • Sep 12 16:44
    dcz-self opened #1961
  • Sep 12 12:34
    est31 commented #1960
  • Sep 12 12:27
    vavra123 commented #1960
  • Sep 12 12:26
    vavra123 commented #1960
  • Sep 11 10:39
    vavra123 opened #1960
  • Sep 06 20:29

    est31 on v0.30.2


  • Sep 06 20:29

    est31 on v0.30.1


Tom Hulton-Harrop
Hello there! Very recently discovered glium after getting interested in Rust and it's absolutely fantastic! Huge props! Just got indexed drawing to work and am on a journey of discovery. Really impressive stuff! Excited to learn more! Thanks!
tyoc213 (David L)
Hi there, Im trying to follow open.gl and I have this code https://gist.github.com/tyoc213/997b85418c54333ecb4f which has the same order of: vertex and colors and also the index buffer is the same as https://open.gl/drawing#Elementbuffers
But that will be my output which is a little different, is there something I'm doing wrong or I should not expect the exact same result as the screenshoot in the tut?
tyoc213 (David L)
For people that read this, the problem was with srgb and how glium corrects it, so you need to create the program with "normal rgb" as: let program = program!(&display, 150 => { vertex: vertex_shader_src, fragment: fragment_shader_src, outputs_srgb: true}).unwrap();
Jeroen Bollen
How would I go about constructing a Cubemap texture? There doesn't seem to be a constructor?
Peter Bay Bastian
How would I go about using glium with nalgebra? I tried enabling the nalgebra feature, but I'm told by cargo that glium doesn't have that feature
oh, seems nalgebra and cgmath support was removed as per this commit tomaka/glium@d08048f
Peter Bay Bastian
what do i do then?
Jonathon Walsh
I'm having an odd problem using glium that I'm curious if anyone else has seen. My program runs fine on Windows, and the example programs run fine on my mac, but when I run my program on the mac there's no window that appears and I can't get glium to give me any sort of useful debug info.
Fedor Logachev

hey guys! just asked on irc, but maybe someone here knows too :)

fn draw_foo<T : Surface>(surf : &mut T, textures : Vec<(String, Texture2d)>) {
  let uniforms  = ?;
  surf.draw(...., uniforms, ...)

I cant found any ways to pass compile unknown count of textures to my shader

Maik Klein
@tomaka Do you still think that Rust needs a better math library? See https://www.reddit.com/r/rust_gamedev/comments/4pa35k/is_there_value_in_creating_a_new_math_library/
Aaron Muir Hamilton
Hey folks; is there any way to draw quads in glium?
(aside from monotonously filling the index buffer with the regular [idx++, idx++, idx--, idx++, idx++, idx++] nonsense)
In my GLES2 applications I just flood the index buffer with this nonsense because there is no other way, but IIRC OpenGL 3.3 should still have GL_QUADS
I have question, is Vulakano application capable of porting to Android? Has anybody ever experience of game or engine developement with it?
I know it has a winit part but, I have some problem to build the traingle example for Android, and I have really like to know is this gonna be a promising library for android developemt?
Hello, my English is very poor, so I use Google Translate.
I have a problem has always wanted to not understand, although the problem can be bypassed.
why textures implement AsUniformValue is impl AsUniformValue for &'a TextureType
not for TextureType? in the as_uniform_value(), code is UniformValue(*self, None), self: &'a Texture...
impl AsUniformValue for SrgbTexture2d {
    fn as_uniform_value(&self) -> UniformValue {
        UniformValue::SrgbTexture2d(self, None)
this can success compile, for what reason choose impl UniformValue for &'a TextureX? Is to avoid memory safety issues in this code?
I want to do this, but I'm afraid of causing problems, so come ask if this will cause any problems.
thanks very much!
David Harvey-Macaulay
Hello, what's the difference between a Buffer and a BufferView? Intuition tells me a BufferView is a subset of a Buffer and so a BufferViewSlice must be a subset of a BufferView. This is the result I need but according to the documentation there seems to be no difference between the construction of a BufferView versus a Buffer at all.
Fedor Logachev
@tomaka Hello! I made quick port of glium_text to rusttype https://github.com/not-fl3/glium_text - it works well for quick protyping and dont requires additional binary dependencies. Code is not clean, and I didnt found a way to get all characters from rusttype like you did with truetype, so I dont think that you need it in main repo.
But it works well for me, and I am thinking about publish it on crates.io with different name, like glium_text_rusttype, do you have any thoughts about it?
Valera Rozuvan

Hey guys! Quick question. In OpenGL, when you have something like:

vec3 A = vec3(1.0, 2.0, 3.0);
A.xy = -A.yx;

A will now become:

{-2.0, -1.0, 3.0}

(In GLSL to be more precise. This is possible due to "swizzling". But in this particular case - I am in a bit of a doubt.)

What is the equivalent of glfwGetTime
I'm trying to perform a rotation, should I have my own timer, or does glutin/glium have a similar function
Thanks in advance! :D
I've got another question:
What is the glium parameter equivalent of:
I've tried using all the blend functions with OneMinusSourceAlpha and it doesn't work
There is white stuff on the edge of the image as well as having a black background
If I run this in OpenGL it will make things transparent and it will remove that white stuff around the edge of the png
To my first question:
        let params = glium::DrawParameters {
            blend: glium::Blend::alpha_blending(),
            .. Default::default()
And to my second:
// At the start of your program
let instant = Instant::now()
// Later
instant.elapsed().as_secs() as f64 + instant.elapsed().subsec_nanos() as f64 * 1e-9) as f32