Changeset ad31ec7 in opengl-game


Ignore:
Timestamp:
Aug 21, 2019, 4:01:09 AM (5 years ago)
Author:
Dmitry Portnoy <dmp1488@…>
Branches:
feature/imgui-sdl, master, points-test
Children:
c8c6da8
Parents:
1187ef5
Message:

Fix the SDL overlay in Windows 10

File:
1 edited

Legend:

Unmodified
Added
Removed
  • vulkan-game.cpp

    r1187ef5 rad31ec7  
    254254         }
    255255
    256          // Might need SDL_RENDERER_TARGETTEXTURE to create the SDL view texture I want to show in
    257          // a vulkan quad
    258256         gRenderer = SDL_CreateRenderer(window, -1, SDL_RENDERER_ACCELERATED | SDL_RENDERER_PRESENTVSYNC);
    259257         if (gRenderer == nullptr) {
     
    262260         }
    263261
    264          uiOverlay = SDL_CreateTexture(gRenderer, SDL_PIXELFORMAT_RGBA8888, SDL_TEXTUREACCESS_STREAMING, SCREEN_WIDTH, SCREEN_HEIGHT);
     262         uiOverlay = SDL_CreateTexture(gRenderer, SDL_PIXELFORMAT_RGBA8888, SDL_TEXTUREACCESS_TARGET, SCREEN_WIDTH, SCREEN_HEIGHT);
    265263         if (uiOverlay == nullptr) {
    266264            cout << "Unable to create blank texture! SDL Error: " << SDL_GetError() << endl;
     
    11241122         // I only need this here for the width and height, which are constants, so just use those instead
    11251123         SDL_QueryTexture(texture, nullptr, &a, &w, &h);
    1126          //cout << "TEXTURE INFO" << endl;
    1127          //cout << "w: " << w << endl;
    1128          //cout << "h: " << h << endl;
    11291124
    11301125         createImage(w, h, VK_FORMAT_R8G8B8A8_UNORM, VK_IMAGE_TILING_OPTIMAL,
Note: See TracChangeset for help on using the changeset viewer.