Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
87 user(s) are online (82 user(s) are browsing Forums)

Members: 2
Guests: 85

afxgroup, VooDoo, more...

Support us!

Headlines

 
  Register To Post  

« 1 ... 10 11 12 (13) 14 15 16 ... 74 »
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@MickJT

Esc might be a bug. I see game uses:

https://sourceforge.net/p/tuxfootball/ ... e/src/gameengine.cpp#l115

SDL_GetKeyboardState returns array that should be indexed with SDL_ScanCodes. So m_quitKey should be SDL_SCANCODE_ESCAPE.

bad_alloc...can you find out the line?

Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
I don't recall it saying a line number before. It's just a complete system freeze now when I go to "Redefine Keys". No shell output. That's the last testing I can do for a week. The game doesn't take long to port though if you want to grab the git repo and have a look.

Edit: Very quickly rebuilt with SDL_SCANCODE_ESCAPE and now the escape key works. Got the bad_alloc message back now:

terminate called after throwing an instance of 'std::bad_alloc'
what(): std::bad_alloc

I could edit the source and see exactly where it breaks or freezes, but I don't have the time now, and for a little while.

By the way, are you sure that SDLK_ESCAPE needed to be changed and not an indication of a larger problem? If I recall correctly, checkkeys didn't report the Key Pressed/Released (or maybe it was the "Text:" line it didn't show) when pressing Escape, unlike any other character.

Edit 2: It's the "Text:" line that doesn't show, but it looks like that's probably normal (Cursor Keys & Enter don't show it either). Gotta go now!


Edited by MickJT on 2016/7/16 19:23:37
Edited by MickJT on 2016/7/16 19:25:27
Edited by MickJT on 2016/7/16 19:32:44
Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@MickJT

Yes, documentation is here https://wiki.libsdl.org/SDL_GetKeyboardState

Checkkeys also reports escape pressed/released. But what it should report for text?

Regarding bad_alloc, it's also game issue that it doesn't try-catch the error. However, we have to debug why allocation failed.

Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
r135 is supposed to merge 2.0.4 modifications into our branch. Patch was 7 megabytes (pain) so I expect there to be new issues.

One obvious problem is that .so is not generated at the moment. As a workaround, remove -no-undefined from generated makefile (libtool's flag). Hopefully we could get rid of pthreads dependency with SDL2.

Testautomation seems to give some failures and there are probably some unimplemented backend functions but they will be added later.


Go to top
Re: SDL2
Quite a regular
Quite a regular


See User information
@Capehill


Great!

Hope to try soon.

Retired
Go to top
Re: SDL2
Home away from home
Home away from home


See User information
@Capehill

Here you are, found another game that has the "shift to the right" issue

Mystery House SDL1 Correct Alignment
Resized Image

Mystery House SDL2 Shifted Alignment
Resized Image
(PuTTy log)
[OS4_WarpMouseWarping mouse to 542118
[OS4_WarpMouseBuilding event structure
[OS4_WarpMouseFire!
[
OS4_WarpMouseDone
[OS4_DestroyRendererFreeing renderer bitmap 0x450A29A8
[OS4_SetDisplayModeDesktop mode passed
[OS4_SetWindowFullscreenTrying to set 'Hi-Res Adventure #1: Mystery House (Apple II/English)' into window mode
[OS4_SetWindowFullscreenWindow 'Hi-Res Adventure #1: Mystery House (Apple II/English)' is being destroyedmode change ignored
[OS4_WarpMouseWarping mouse to 542116
[OS4_WarpMouseBuilding event structure
[OS4_WarpMouseFire!
[
OS4_WarpMouseDone
[OS4_HideWindowCalled
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_SetWindowGrabInternalWindow 0x4B01CBC0 ('Hi-Res Adventure #1: Mystery House (Apple II/English)'input was released
[OS4_ShowCursorHiding cursor
[OS4_SetPointerForEachWindowSetting pointer object/type 0x4B01F2A4/16 for window 0x4B01CBC0
[OS4_DestroyWindowCalled for 'Hi-Res Adventure #1: Mystery House (Apple II/English)' (flags 0xB)
[
OS4_CloseWindowInternalClosing window 'Hi-Res Adventure #1: Mystery House (Apple II/English)'
[OS4_CloseScreenInternalClose screen 0x4B01A590
[OS4_GL_FreeBuffersCalled
[OS4_GL_UnloadLibraryCalled
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_GL_LoadLibraryCalled 0
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_CreateWindowOpen fullscreen window with delay
[OS4_ShowWindowCalled
[OS4_RaiseWindowCalled
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_SetDisplayModeOpening screen id 1342182144640*480*24
[OS4_SetWindowFullscreenTrying to set 'Hi-Res Adventure #1: Mystery House (Apple II/English)' into fullscreen mode
[OS4_SetWindowFullscreenSystem window doesn't exist yet, let's open it
[OS4_GetIDCMPFlagsCalled
[OS4_GetWindowFlagsCalled
[OS4_GetScreenForWindowFullscreen
[OS4_CreateWindowInternalTrying to open window 'Hi-Res Adventure #1: Mystery House (Apple II/English)' at (1000,528of size (560x384)
[
OS4_CreateRendererCreating renderer for 'Hi-Res Adventure #1: Mystery House (Apple II/English)' (flags 0x0)
[
OS4_CreateRendererVSYNCoff
[OS4_ActivateRendererAllocating VRAM bitmap 640*480*32 for renderer
[OS4_UpdateClipRectCliprect: (0,0) - 640*480
[OS4_GetOutputSizew=640h=480
[OS4_SetWindowGrabInternalWindow 0x4B01CBC0 ('(null)'input was released
[OS4_WindowEventCalled with event 12



The Kite SDL1 Correct Alignment
Resized Image

The Kite SDL2 Shifted Alignment
Resized Image
(PuTTy log)
[OS4_DestroyRendererFreeing renderer bitmap 0x2D200478
[OS4_SetDisplayModeDesktop mode passed
[OS4_SetWindowFullscreenTrying to set 'The Kite (Version 1.3.e/Windows/English)' into window mode
[OS4_SetWindowFullscreenWindow 'The Kite (Version 1.3.e/Windows/English)' is being destroyedmode change ignored
[OS4_WarpMouseWarping mouse to 264255
[OS4_WarpMouseBuilding event structure
[OS4_WarpMouseFire!
[
OS4_WarpMouseDone
[OS4_HideWindowCalled
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_SetWindowGrabInternalWindow 0x4F60F108 ('The Kite (Version 1.3.e/Windows/English)'input was released
[OS4_ShowCursorHiding cursor
[OS4_SetPointerForEachWindowSetting pointer object/type 0x46721C74/16 for window 0x4F60F108
[OS4_DestroyWindowCalled for 'The Kite (Version 1.3.e/Windows/English)' (flags 0xB)
[
OS4_CloseWindowInternalClosing window 'The Kite (Version 1.3.e/Windows/English)'
[OS4_CloseScreenInternalClose screen 0x4671F758
[OS4_GL_FreeBuffersCalled
[OS4_GL_UnloadLibraryCalled
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_GL_LoadLibraryCalled 0
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_CreateWindowOpen fullscreen window with delay
[OS4_ShowWindowCalled
[OS4_RaiseWindowCalled
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_SetDisplayModeOpening screen id 1342313216800*600*24
[OS4_SetWindowFullscreenTrying to set 'The Kite (Version 1.3.e/Windows/English)' into fullscreen mode
[OS4_SetWindowFullscreenSystem window doesn't exist yet, let's open it
[OS4_GetIDCMPFlagsCalled
[OS4_GetWindowFlagsCalled
[OS4_GetScreenForWindowFullscreen
[OS4_CreateWindowInternalTrying to open window 'The Kite (Version 1.3.e/Windows/English)' at (880,420of size (800x600)
[
OS4_CreateRendererCreating renderer for 'The Kite (Version 1.3.e/Windows/English)' (flags 0x0)
[
OS4_CreateRendererVSYNCoff
[OS4_ActivateRendererAllocating VRAM bitmap 800*600*32 for renderer
[OS4_UpdateClipRectCliprect: (0,0) - 800*600
[OS4_GetOutputSizew=832h=600
[OS4_UpdateViewportCliprect: (0,0) - 832*600
[OS4_DestroyRendererFreeing renderer bitmap 0x46743EB8
[OS4_SetDisplayModeDesktop mode passed
[OS4_SetWindowFullscreenTrying to set 'The Kite (Version 1.3.e/Windows/English)' into window mode
[OS4_SetWindowFullscreenWindow 'The Kite (Version 1.3.e/Windows/English)' is being destroyedmode change ignored
[OS4_HideWindowCalled
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_DestroyWindowCalled for 'The Kite (Version 1.3.e/Windows/English)' (flags 0xB)
[
OS4_CloseWindowInternalClosing window '(null)'
[OS4_CloseScreenInternalClose screen 0x4671F758
[OS4_GL_FreeBuffersCalled
[OS4_GL_UnloadLibraryCalled
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_GL_LoadLibraryCalled 0
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_CreateWindowOpen fullscreen window with delay
[OS4_ShowWindowCalled
[OS4_RaiseWindowCalled
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_GetDisplayBoundsx=0y=0w=2560h=1440
[OS4_SetDisplayModeOpening screen id 13424442881280*720*24
Gronk
...
[
OS4_SetWindowFullscreenTrying to set 'The Kite (Version 1.3.e/Windows/English)' into fullscreen mode
[OS4_SetWindowFullscreenSystem window doesn't exist yet, let's open it
[OS4_GetIDCMPFlagsCalled
[OS4_GetWindowFlagsCalled
[OS4_GetScreenForWindowFullscreen
[OS4_CreateWindowInternalTrying to open window 'The Kite (Version 1.3.e/Windows/English)' at (727,370of size (1105x700)
[
OS4_CreateRendererCreating renderer for 'The Kite (Version 1.3.e/Windows/English)' (flags 0x0)
[
OS4_CreateRendererVSYNCoff
[OS4_ActivateRendererAllocating VRAM bitmap 1280*720*32 for renderer
[OS4_UpdateClipRectCliprect: (0,0) - 1280*720
[OS4_GetOutputSizew=1280h=720
[OS4_SetWindowGrabInternalWindow 0x4F60F8E8 ('(null)'input was released
[OS4_WindowEventCalled with event 12


Edited by Raziel on 2016/11/8 7:31:19
Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@Raziel

Thanks for log. How much shift you get? Any chance for a screenshot? Did you say it doesn't happen always?

Go to top
Re: SDL2
Home away from home
Home away from home


See User information
@Capehill

I updated the post above to show what the difference is.

I found another one and probably will find even more games with this issue

It happens every time with at least the two games mentioned above.

In the other thread where i said it didn't happen anymore i was using the SDL1 build for testing

Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@Raziel

Finally checked those logs. It looks like SDL2 opens a new screen but when window is created, it uses some strange x/y coordinates for position (would have expected 0,0). I have to do some fullscreen tests.

Go to top
Re: SDL2
Home away from home
Home away from home


See User information
@Capehill

Thanks a lot

Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@Raziel

When programmer passes SDL_WINDOWPOS_CENTERED parameter, SDL2 most likely uses the information of the first stored display, which on our system is probably your Workbench screen. Then it calculates new window coordinates based on the dimensions of your WB screen, which might not match the application's expectations...that explains funny readings in the serial log.

For now, it looks as if the most simplest solution would be to ignore SDL2's window centering code and center the window on AmigaOS backend side. This solution needs a bit more testing before commit.

As a workaround, you can try to pass X=0, Y=0 for your window.

Go to top
Re: SDL2
Home away from home
Home away from home


See User information
@Capehill

I wouldn't know how to do that...i can't code

Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@Raziel

Here https://wiki.libsdl.org/SDL_CreateWindow

Try locating that function call from your game code and replace x and y parameters with zeroes.

Alternately please compile r139 and tell me if problem still there..

Go to top
Re: SDL2
Home away from home
Home away from home


See User information
@Capehill

Thank you

The in source change to 0, 0 made the game screen start at, of course, 0, 0

But there are still important portions cut off as you can see in the picture
Resized Image

I haven't tried building SDL2 myself as i wouldn't know how to properly create libraries, i leave that to the pros to not stir up any more dust when reporting errors i made myself on the way of building sdl2

Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@Raziel

Looking at the earlier serial log, we can observe that window width was less than 640. I am not sure why is that, did game want it or did SDL2 screw it somehow?

Please, if you have time, try compiling r139. I know that Davide can build SDL2 without issues, for example. It should work, unless your SDK is somehow broken. (ok, .so build is currently broken, it's a known issue)

I hope we could have another SDL2 release this year, but there are still some open issues.

Go to top
Re: SDL2
Quite a regular
Quite a regular


See User information
@Capehill

I will compile R139 asap.


Retired
Go to top
Re: SDL2
Quite a regular
Quite a regular


See User information
@thread


Capehill released version 164.

Works very well.

Can't wait to have a system opengles2 compatible to test.


Don't forget to support the projects.

Retired
Go to top
Re: SDL2
Home away from home
Home away from home


See User information
@AmigaBlitter

Released where ?
Officially still the old r119 on Sourceforge, atleast you mentioned the progressing internal version to compile

Go to top
Re: SDL2
Quite a regular
Quite a regular


See User information
On sourceforce there is R164.
Tomorrow will be on os4depot, i guess.


Retired
Go to top
Re: SDL2
Home away from home
Home away from home


See User information
@samo79

Guess he was talking about the code revision in trunk.

There wasn't a build released for some time now

Go to top

  Register To Post
« 1 ... 10 11 12 (13) 14 15 16 ... 74 »

 




Currently Active Users Viewing This Thread: 1 ( 0 members and 1 Anonymous Users )




Powered by XOOPS 2.0 © 2001-2024 The XOOPS Project