-
-
Notifications
You must be signed in to change notification settings - Fork 92
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Problems trying to run self-built version #163
Comments
Sounds like SDL2 can't initialize a screenmode? Another test would be if you could start a minimal SDL2 application in your system, to see if that initializes correctly or not. Something simple, like opening a screen and displaying a bitmap there for example, would be enough. |
@midwan: all my SDL2 programs work fine (I am an SDL2 contributor myself, so that's not the problem at all). |
@vanfanel could you try the current "dev" branch instead? I've merged dev-sdl1 and dev-sdl2 into one, and made several corrections afterwards... |
@midwan I have just built the "dev" branch and it works! Well, I can see the GUI (nice font and cursor! yay!) but I have seen a big problem: if I save a configuration (a default Amiga500 configuration without changing ANYTHING) and then load it again, clicking "START" will make the emulator exit back to the commandline. |
@vanfanel Yeah, there are some glitches left there after the merge and latest changes, which I'll be working on the next few days. Hopefully we'll sort them all out soon and get it back to working 100% :) |
@midwan I have also seen some unnecessary libs being linked: -licui18n -licuuc -licudata... I will be testing this "dev" branch in the next days: non-working config file loading is a bit of a show-stopper fir now, but as soon as that is working, it will be GREAT! 💃 |
@vanfanel Those will be removed, they were added with the latest updates but if they are not necessary, we will take them away. |
That's very good to hear! Most CD32 stuff is already between #ifdefs already anyway (look for #ifdef CD32 in the code. It's all there. ) so it's a small task really. |
@vanfanel interesting idea, I'll check it out in a few tests... |
Can you run amiberry without the configuration file? Does it start up? |
@solskogen : It runs fine without a config file, I explained it already. According to @midwan , if I have understood him right, the dev branch is broken at the moment so loading a config file and then hitting "START" does not work. I am waiting for him to fix it to build again and test. |
Heh, sorry. Didn't read the whole thread. |
@vanfanel It currently doesn't crash, but I still must have something broken as at least in my tests, I only get a black screen after "start". I can return to the GUI normally, but can't see anything in the emulation screen. I'll keep working on it until it's fixed of course... :) |
@vanfanel hm, strange, I tested the same exact files on another fresh distro (Stretch Lite) and it works. :) Please let me know if you find a problem as well! |
@vanfanel The latest commit should have addressed these problems, please give it another try and let me know if you still have a problem! |
@midwan : Yes! Latest git version on the dev branch allows to load configs and click START, good! :) Also, I have noticed there are problems with the sound: once on a while, there are "too long" samples (music gets out of rythm in games like Lemmings). I guess this is because the audio buffer is depleted. I believe you are syncing emulation to video, which is a great idea because this way I see perfectly smooth scrolls, etc. But you need to resample the audio to compensate. (I am talking about an NTSC Amiga chipset on a 60HZ physical display, where the difference is minimal I guess) PD: The audio problems do not seem to happen if I run amiberry on an EXACT 50HZ physical video mode (CEA mode number 19, you can set it via tvservice) and I emulate a PAL chipset, because it's 50.0000 on both sides. But for NTSC, there's no exact equivalent between the NTSC chipset refresh rate and a physical video mode. |
@vanfanel thanks for the details, In SDL1, we manually do vsync based on the information we get from the display. If there's a difference between the emulated chipset and the actual display (e.g. emulating a PAL Amiga on a 60Hz screen) then we adjust the drawn frames accordingly - but we don't do much for the audio, which is probably why you see the glitch. Perhaps going to libretro would be the best approach to this, depending on the effort required to fix it. |
@vanfanel Could you give that a try and see if it's any better for you? Keep in mind that it's not fully polished yet, more work is needed on it and it hasn't been tested much (only tested under Raspbian Stretch, using the Legacy driver, launching it directly from the console for now). |
@midwan : Just tried this with the dispmanx direct path. Aside from that, I think a DispmanX backend is not a good idea anymore, use SDL2 instead since SDL2 runs on KMSDRM+GLES, which is the future in the Pi anyway. Dispmanx is a dead path too, and there are no real benefits. |
@vanfanel Regarding Dispmanx, I realize that it's considered "deprecated" but it's still faster than using SDL2, even when it's using the "rpi" driver. The KMSDRM driver was consistently slower for me, and more buggy as well. Maybe it will eventually mature enough to change that, but for now it's just not fast enough when compared to using dispmanx... |
@midwan : SDL2 supports KMSDRM and Dispmanx. In both cases, GLES is used for rendering. Anyway, SDL2 abstracts the underlying windowing API for you, and has good video synchronization on the Pi, so I wouldn't invest time in custom backends: SDL2 is alright. You use SDL2 and you know the emulator will run in everything that SDL2 runs on, no need to worry about dispmanx, kms...etc. |
With SDL2 (lastest from mercurial) compiled with kmsdrm and fkms, sysinfo tells me that the emulated machine is somewhat faster than with SDL1 and dispmanx. But the mouse is really sloppy and not as "slick" as with SDL1. |
@solskogen : If you want a smooth cursor movement with SDL2, you need to set a PHYSICAL 50Hz video mode. I use mode CEA 19, and I set it with the tvservice command before executing amiberry. |
@vanfanel I was referring to using Dispmanx directly, not through SDL2. The KMSDRM option didn't seem any faster in my tests, and at the same time I had some glitches: mouse input seemed a bit buggy, the texture refresh didn't always clear the previous frame as it should, etc. Perhaps I missed something in my environment? In that case, I'd love to give it another shot... Is there some documentation on how to "properly" set this up? What I did was download the latest SDL2 sources (2.0.7 currently), do a "configure" (does that pick up the kmsdrm option or do I need to enable it with a parameter?) and then "make" and "make install" like the README says... @solskogen How did you test this? In my tests I run benchmarks (which give numbers so they are easy to compare) but also tested various demos and games, checking for framerate drop and choppy audio (if it starts to struggle, the audio will break up also). For example the "World of Commodore 92" demo has a section with zooming in/out effects, that always went under 50FPS in SDL2 with "rpi", but it managed to stay at 50 when using Dispmanx directly (in SDL1 and the new SDL2 target). |
@vanfanel Edit: It seems you have to disable the "rpi" driver otherwise it has higher priority, and it fails to initialize if you've switched to KMS. I see that some of the glitches with the mouse are not there (they must have been related to the x11 driver then) and you can launch it from the console as well. The framerate is still lower, so I'll see if I can find the reason for that. It's reporting 33 fps on PAL and around 24-25 fps on P96 modes, instead of 50 and 60 respectively. That would be the reason you see a choppy mouse movement and benchmarks being faster (because you essentially have "frameskip"), but it will also show choppy audio/video if you try to run a demo. |
You can run like this: "SDL_VIDEODRIVER=kmsdrm ./amiberry"
…On Sun, Dec 31, 2017 at 6:48 AM, Dimitris Panokostas < ***@***.***> wrote:
@vanfanel <https://github.com/vanfanel>
After checking a bit more, it seems that I had missed a dependency:
libgbm-dev was not installed, so the kmsdrm driver was not used in SDL2 in
my tests.. Doh!
I will run another batch of tests with that, though I'm not sure if I have
to disable the "rpi" driver to make also, after reading that they may have
conflicts with each other?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#163 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AA-P6LwaduZQbDXeN92oJKBFJQQBAOTbks5tFyAbgaJpZM4Q38hx>
.
|
I only tested with sysinfo.
On Sun, Dec 31, 2017 at 9:29 AM, Christer Solskogen <
christer.solskogen@gmail.com> wrote:
… You can run like this: "SDL_VIDEODRIVER=kmsdrm ./amiberry"
On Sun, Dec 31, 2017 at 6:48 AM, Dimitris Panokostas <
***@***.***> wrote:
> @vanfanel <https://github.com/vanfanel>
> After checking a bit more, it seems that I had missed a dependency:
> libgbm-dev was not installed, so the kmsdrm driver was not used in SDL2 in
> my tests.. Doh!
> I will run another batch of tests with that, though I'm not sure if I
> have to disable the "rpi" driver to make also, after reading that they may
> have conflicts with each other?
>
> —
> You are receiving this because you were mentioned.
> Reply to this email directly, view it on GitHub
> <#163 (comment)>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/AA-P6LwaduZQbDXeN92oJKBFJQQBAOTbks5tFyAbgaJpZM4Q38hx>
> .
>
|
@vanfanel I think it would be best to clean up this thread... The main issue about not being able to compile/run the emulator is now fixed, so we should close that. There's a separate issue / suggestion to have CD32 support as an option in the Makefile, and one about the audio resampling for 60Hz. We should open those as separate issues to better monitor what's still open and what's done, and not get lost in big lists of discussions... :) I'll close this one and open those 2, feel free to comment if you have any further observations! |
Hi,
I am trying to run a self-built version of the sdl2-dev branch, and all I get is that it returns to the system prompt (x-less system here, no X installed at all).
I have tried passing a basic Amiga 500 config file in text .conf format, where the kickstart file and path are specified (in fact it lives in the same directory where the emulator is).
./amiberry-sdl2-dev a500.conf
It keeps returnning to the commandline prompt. Seems to init and deinit SDL2, however, as I can see the SDL2 cursor briefly.
Any basic instructions would be good.
These are the contents of the a500.conf file:
kick.rom lives in /home/pi/amiga/kick.rom
Thanks!
The text was updated successfully, but these errors were encountered: