nuklear icon indicating copy to clipboard operation
nuklear copied to clipboard

why experiment not working?

Open sp00ck opened this issue 7 years ago • 0 comments

I put before main loop a clear background and delay. I get black window, no color why? How draw on background?

    ctx = nk_sdl_init(win);
    bg.r = 0.94f, bg.g = 0.83f, bg.b = 0.52f, bg.a = 1.0f;
.........  
/* my copy code */
    SDL_GetWindowSize(win, &win_width, &win_height);
    glViewport(0, 0, win_width, win_height);
    glClear(GL_COLOR_BUFFER_BIT);
    glClearColor(bg.r, bg.g, bg.b, bg.a);
    SDL_GL_SwapWindow(win);
    SDL_Delay(1400);
/* end my code */

    while (running)
    {
        /* Input */

Why i cant change colorbefore main loop? In loop exist any magic functions?

sp00ck avatar Feb 18 '19 10:02 sp00ck