Tassarion Vesryn | 6 May 08:36 2016
Picon

Free course published

Hello,

as you comment a few days ago, I'm doing a course in graphic programming that is closely related to SDL.

There are already several parts of the course available. The course is only in Spanish, but I think to be one of the most spoken languages in the world will not be problem.

I think this being well enough to be the first course

To do spam I have omitted the link to the course, those interested who tell me and sent it. I remind you that the course is free.

Thank you
_______________________________________________
SDL mailing list
SDL <at> lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
hardcoredaniel | 4 May 19:46 2016
Picon

WinRT support for SDL_WarpMouse* possible?

Hi,

I have successfully built SDL's WinRT port :-) My only pitfall was that I was using another drive (not C:) where the app will successfully compile but never run :-(

Currently my app won't work properly, because it expects a working "SDL_WarpMouseInWindow". The README states that it is currently not supported. Is it possible to support it with the current Windows SDKs for Win10 at all, or do I have to look for alternatives?

Regards,

Daniel

_______________________________________________
SDL mailing list
SDL <at> lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
ace491 | 3 May 22:50 2016
Picon

Memory Leak in SDL_SetError when using std::thread

I created a bug report because I'm getting a memory leak when SDL_SetError is called from a thread created by std::thread instead of SDL_Thread.
There is more related information in the report.
https://bugzilla.libsdl.org/show_bug.cgi?id=3317
_______________________________________________
SDL mailing list
SDL <at> lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
Naith | 1 May 23:25 2016
Picon

Re: Trying to use scancode to get key input.

I answered your question in this post: https://forums.libsdl.org/viewtopic.php?t=11858
_______________________________________________
SDL mailing list
SDL <at> lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
AmigaBlitter | 1 May 14:45 2016
Picon

Migrating from SDL 1.2 to SDL2

Since the previous thread i opened gone wild, i opened a new thread about migrating software from SDL version 1 to SDL version 2.

I have now a problem related to SDL_ACTIVEEVENT.
If i understood correctly, it's now changed to SDL_WINDOWEVENT.

Consider now the following:








Code:

SDL_Event event;

case SDL_ACTIVEEVENT:
      if (event.active.state & SDL_APPINPUTFOCUS && !event.active.gain) {
           DEBUG.LOG("Lost input focus\n");
           ...
          ...
       ]



now event.active.state and event.active.gain doesn't exist anymore.

How can i change this?

Thank you very much
_______________________________________________
SDL mailing list
SDL <at> lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
ancientcc | 1 May 06:27 2016

(android)Modify Play Audio Mechanism

On android, play audio is by creating a new thread(SDL_RunAudio), once app go into background, the thread will be suspended, result in app can not play audio when background.

 

To support play audio when background, I modified the audio play mechanism, it uses Service(). By the way, add a hint(SDL_HINT_BACKGROUND_AUDIO) whether to allow the play audio when the background.

 

Source code on Github: https://github.com/freeors/SDL

_______________________________________________
SDL mailing list
SDL <at> lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
bjornw2 | 19 Apr 23:26 2016

Re: OSX: Relative mousemode is accelerated, should be raw(?)

Actually I just stumbled upon a related bug (about raw events not working properly) when I just upgraded my game to SDL 2.0.4.

On my Macbook with OSX El Capitan (10.11), SDL_SetRelativeMouseMode(SDL_TRUE) breaks the SDL_MOUSEMOTION events completely, you don't get any events - neither with the trackpad nor with a real USB mouse. Mousebutton events and keyboard events work fine.

Setting the additional SDL_SetHint(SDL_HINT_MOUSE_RELATIVE_MODE_WARP, "1") makes it work, but has the side-effect that if you jitter the mouse around a bit, OSX pop ups a mega-large mousepointer for a few seconds which SDL doesn't seem to know how to hide. I guess as some kind of sight-impaired help..

Anyway, my interpretation is that the relative mouse mode seems to be broken on OSX 10.11 and SDL 2.0.4 as far as I can tell, when it tries to use raw events (which it should try without the hint set).

On Linux, the same code works fine with SDL 2.0.4 and SetRelativeMouseMode. Haven't tried on Windows yet.
_______________________________________________
SDL mailing list
SDL <at> lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
JaSONOfficial | 1 Apr 03:53 2016

Linking errors with SDL2 2.0.4 under mingw with Eclipse CDT

Hi, I first want to say that I am new to C++ Programming and even more new to SDL. I normaly never post on forums but I have a problem and after over 10 hours of research, I still have not find a fix to my problem.

I added the Header files of SDL in the include folder of my compiler (C:\MingW\include) and after adding all the library files of SDL in the lib file of MingW (C:\MingW\lib) like many tutorials told me to do on the Internet. But even though I perfectly linked my compiler to the files using Eclipse I get : cannot find lSDL2 and cannot find lSDL2main when I try to build my program using Eclipse. I am sorry for the poor description of my problem and for the bad usage of the English language.

Thanks a lot !

A 15 years old programmer in distress.
_______________________________________________
SDL mailing list
SDL <at> lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
alex_dja | 19 Mar 19:47 2016
Picon

[Android target]How to make SDLSurface(java) bg transparent?

Hello, everybody!
I'm writing extention under openfl. This is a haxe lib which has SDL backend in native platforms.
Could you please tell how to make transparent java view(SDLSurface class)background with sdl to have possibility see another android native view under it?
What changes must be done in cpp code(maybe some sdl attributes) and in java android tempate?
l'll be appreciate for any help:)
_______________________________________________
SDL mailing list
SDL <at> lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
Killean | 29 Mar 02:18 2016
Picon

[Windows] SDL_GetDesktopDisplayMode and Missing shcore.dll

Windows 7 Ult x64 developing on Visual Studio 2010, all C++ Redist packages (2008-2015) have been installed, upon calling SDL_GetDesktopDisplayMode it returns 0, and calling SDL_GetError returns the message: "Failed Loading SHCORE.DLL: The specified module could not be found." I understand the missing DLL part (its not there in sys32 or sys64), but am I missing something (else)? Is Windows 7 not supported (research suggests shcore appears in Windows 8 and beyond)? Or is this a bug that I should be submitting to the tracker?

Here is the code I am using to reproduce the error:








Code:

#include
#include

int main (int argc, char * argv[]) {
   bool ProgramLoop = true;
   int WindowWidth = 640;
   int WindowHeight = 480;

   SDL_Window * Window = NULL;
   SDL_Event e;

   if (SDL_Init(SDL_INIT_VIDEO | SDL_INIT_AUDIO)       printf("SDL_Init: %s\n", SDL_GetError());
      ProgramLoop = false;
   }

   if (ProgramLoop) {
      SDL_DisplayMode Mode;
      if (SDL_GetDesktopDisplayMode(0, &Mode) != 0) {
         WindowWidth = Mode.w;
         WindowHeight = Mode.h;
      }
      else {
         printf("SDL_GetDesktopDisplayMode: %s\n", SDL_GetError());
         ProgramLoop = false;
      }
   }

   if (ProgramLoop) {
      Window = SDL_CreateWindow("Test", SDL_WINDOWPOS_UNDEFINED, SDL_WINDOWPOS_UNDEFINED, WindowWidth, WindowHeight, SDL_WINDOW_SHOWN);

      if (Window == NULL) {
         printf("SDL_CreateWindow: %s\n", SDL_GetError());
         ProgramLoop = false;
      }
   }

   while (ProgramLoop) {
      while (SDL_PollEvent(&e) != 0) {
         if (e.type == SDL_QUIT) {
            ProgramLoop = false;
         }
      }
   }

   if (Window != NULL) {
      SDL_DestroyWindow(Window);
      Window = NULL;
   }

   return 0;
}


The how and why: I am a fresh graduate of Lazy Foo's House of Game Programming. While I was in the process of making a game, for academic purposes I thought I would start playing around with some of the different flags such as SDL_WINDOW_FULLSCREEN. To my surprise, this meant forcing my widescreen monitor to stretch 640x480 across it. While I understand that is how my monitor is choosing the handle the situation, it was not the desired effect. So I started looking around for how to force the 4:1 aspect ratio in SDL full screen, and I came across a post explaining the situation. I would need to go to full screen, and then only render the 4:1 area.

At this point I understood I could always just use SDL_WINDOW_FULLSCREEN_DESKTOP, get the windows dimensions and only render to the area I want... But this is for my academic curiosity, so I wanted to get the desktops resolution, and then set the CreateWindow dimensions and use SDL_WINDOW_FULLSCREEN. I found out that one way I can accomplish this is by using GetDesktopDisplayMode. And that is when I got the error, and then I spent pretty much the entire day researching the DLL.

In the midst of researching, I also checked 6 other Windows 7 computers and 2 Windows 10 computers. All of the Windows 7 computers were missing the DLL, but the Windows 10 computers had it. My research suggests that this is not part of any C++ redist package (possibly proven by the fact that 5 of the 6 had all redists from 2008 to 2015 installed), and that it first appears in Windows 8. The latter is an assumption because aside from people saying some game doesn't work in Windows 7 because of missing this DLL, the first actual error reports of other applications using it are from Windows 8.1 and 10.

So this goes back to my question above; am I missing a package that would install this on Windows 7? Like a Windows feature, or some redist package? Or for that matter if this DLL is actually missing from Windows 7, does that mean that SDL (or just that function) will not be supporting Windows 7? Or did I stumble across an undesired behavior and I should report this to the SDL bug tracker?
_______________________________________________
SDL mailing list
SDL <at> lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
Kelvin | 31 Mar 19:59 2016
Picon

Trying to use scancode to get key input.

The wiki seems to be missing a ton of code samples, so I'm sorry if this seems like a stupid question. I'm trying to make a function that gets an integer to represent the scancode of a key then pass it to SDL from a Squirrel-scripted VM. I tried to use SDL_GetKeyFromScancode(), but it won't let me use an integer as input, so how to I turn an integer into an SDL_Scancode? I can't pass SDL_Scancode directly from Squirrel, or if i can, I don't know how.
_______________________________________________
SDL mailing list
SDL <at> lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Gmane