-=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- (c) WidthPadding Industries 1987 0|424|0 -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=-
Socoder -> Off Topic -> AGAWFrame

Page : 1 2 3 4 5 6 7 8 9 10 11 12 Prev 13 14 Next
Posted : Thursday, 19 April 2018, 03:47
rychan
Your Framework is, quite simply, amazing!
Posted : Thursday, 19 April 2018, 04:20
rockford
Indeed. When can we get our hands on it?
Posted : Thursday, 19 April 2018, 04:28
Jayenkai
I’m in two minds whether to or not. It's become incredibly JayCode!!!

-=-=-
''Load, Next List!''
Posted : Thursday, 19 April 2018, 04:36
rockford
TBF though, we'd only need the functions, which wouldn't need to be looked at 99.9% of the time. Please don't make me use SDL!!!
Posted : Thursday, 19 April 2018, 05:03
Jayenkai
I've still got to work out ALL the audio on the 3DS side of things, first.
Going to be a bastard to do that, as .. for whatever reason.. the emulator's refusing to play any audio, so it's going to be a case of coding blind (*deaf!), then copying it over to the hardware, crossing my fingers, and seeing if it's worked!!

.. Yeah, not fun.. :\



That's nice, though!

-=-=-
''Load, Next List!''
Posted : Thursday, 19 April 2018, 05:09
rockford
Have you tried a different EMU?

TBH Sound is a bastard on all formats though - wrong format and/or frequency or size and the sound/music either plays - correctly or not, or doesn't play at all for no obvious reason.
Posted : Thursday, 19 April 2018, 05:13
Jayenkai
I don't think there IS a different 3DS Emu!! Or at least, I can't find one, anyway.
It's Citra or nothing..

-=-=-
''Load, Next List!''
Posted : Thursday, 19 April 2018, 08:41
Jayenkai
Update on audio.

I've successfully managed to load the .wav data into memory.
Or at least, I've managed to load a couple of the .wavs, the two menu blips.
As soon as it then tries to load the jingle, it goes "OH FUCK!! THIS IS HUGE!!!" and dies on its arse due to memory issues.

Hmmm..

This might be a fairly significant stumbling block..

More thinking is required, methinks..

-=-=-
''Load, Next List!''
Posted : Thursday, 19 April 2018, 13:26
Jayenkai
.. Really struggling with the audio.
Fucknuts...

-=-=-
''Load, Next List!''
Posted : Thursday, 19 April 2018, 14:32
rockford
Put it down and have a play on something. Come bak to it fresh. If all else fails, ask on 3DS dev forums.
Posted : Thursday, 19 April 2018, 15:16
Jayenkai
Yep.
Shutdown mode activated!
Currently watching a bunch of Defunctland videos...

-=-=-
''Load, Next List!''
Posted : Friday, 20 April 2018, 04:40
Jayenkai
OK, let's see if we can figure out why "Logo.png" isn't working on the 3DS.

*tweak*
*tweak*
Nope..
Let's try outputting the error code.
"83"
OK, now let's open the lodepng.cpp file, and see if we can find what's generating error 83!
...

...

Linkage

EVERYTHING.
There are 81 instances of the number 83 in the script.
Every single fucking error code that I can find in the entire fucking script is the same god damned "83"... That doesn't help me AT ALL!!!!


God damnit!!!

-=-=-
''Load, Next List!''
Posted : Friday, 20 April 2018, 14:01
Jayenkai
I'm going to have to put a limit on spritesheet sizes, I think.
192x192 pixels seems to be the biggest that lodepng can cope with.

If I make my own spritesheet in memory, I can seemingly get up to 512x512 before it fucks up, but lodepng struggles.
I think it might be something to do with the actual decompressing of the png, rather than the overall size, but I'm not 100% sure.

Anyhoo, current Flappyness!


View on YouTube

-=-=-
''Load, Next List!''
Posted : Friday, 20 April 2018, 23:03
Dabz
Canny!

Dabz
Posted : Sunday, 22 April 2018, 07:25
Jayenkai
Trying to load audio again, this morning, and am noticing a rather odd thing.
It seems that it fails if the audio I try to load is larger than a certain number of bytes.. More specifically it seems to be happening when I Malloc certain high numbers. Like, the memory is definitely there, as I can Malloc a high number a hundred times and it's fine.. but if I do a single Malloc of too high a number, that’s when it all fucks up..

It "feels" as if the 3DS has somehow segmented the memory into chunks, and if I try to Malloc over that single chunk limit, that’s when it fucks up.

Further investigation is, of course, required.. but .. assuming I can figure out how to actually PLAY the audio data, it looks like I might be getting sound going, soon!!

-=-=-
''Load, Next List!''
Posted : Sunday, 22 April 2018, 17:18
Dabz
Sorta like a page frame overflow?

I have no other means to describe it really, but depending how memory is mapped, could you malloc odds and sods and that will keep it confined, but going big big overflows the frame limit?

Do I even know what I'm on about?

What year is this?

Who's the President?

Memory can be weird... Just look at how the CPC draw's its shite from &C000 to &FFFF, that was heart breaking when you first tried displaying sprites!

Dabz

-=-=-
Intel Core i5 6400 2.7GHz, NVIDIA GeForce GTX 1070 (8GB), 8Gig DDR4 RAM, 256GB SSD, 1TB HDD, Windows 10 64bit
Posted : Monday, 23 April 2018, 08:56
Jayenkai
Boy, I tell ya.. Trying to get Audio working is being a complete arse!!!

-=-=-
''Load, Next List!''
Posted : Tuesday, 24 April 2018, 06:50
Jayenkai


Ignoring Audio for today, I’ve decided to tackle the screens, instead.
The top screen's "3D" has been activated, and it does indeed work.. .. after fucking hours trying to figure out why it wasn’t working.
Turns out it was the same issues which was causing my earlier "moves all the co-ords" thing with the sprites. That was also happening when I would attempt the "other eye" and also the bottom screen.
So, lots more complex maths are in the Framework, and I’ll need to stress test it all.

Currently only the lines are being drawn in 3D. I need to add depth parameters to all my sprite routines.

But.. yeah.. it's working!!
The bottom screen methodology is also being figured out, and should be more-or-less a doddle to get to work.

But first, stress testing, because I’m not sure it'll manage to keep up with everything I’m throwing at it.

-=-=-
''Load, Next List!''
Posted : Tuesday, 24 April 2018, 09:37
Jayenkai
Flappadiddle-Doo seems perfectly fine with 3D mode on, drawing essentially 3 screens worth of objects. (Left eye, Right eye, Bottom screen)

That is to say..
1) 3D Mode is piss easy to implement, in my framework. Game.SetDepth(depth); the same as you would Game.SetAlpha(alpha); Game.SetRot(angle); and Game.SetCol(r,g,b);
Rects, Lines, Text, Circles, Sprites, etc.. They all obey the Depth!

2) I just played Flappadiddle Doo with 3D mode switched on!!

3) OH MY GOD!!!!

I really, really need to get the audio working, now.


Note : The bottom screen is currently a duplicate of the top screen. Work will soon begin on moving the menu and scores down there.

-=-=-
''Load, Next List!''
Posted : Tuesday, 24 April 2018, 11:58
rockford

Posted : Tuesday, 24 April 2018, 14:19
shroom_monk
It's possible that the memory issue you're describing is due to memory fragmentation, Jay. When you malloc X bytes of memory, the system needs to find you a single, solid, unbroken X bytes of memory that is free. But it might not be able to find such an unbroken range, depending what else has already been allocated, even if the sum total of free space exceeds what you're asking for.

For example (making up some numbers), say you have 1GB of RAM total, and you allocate six 100MB chunks of memory. What might sensibly happen is that these all get allocated one after the other, with 400MB of free space at the end. Then you delete the second and fourth chunks, leaving some 100MB gaps. The largest free chunk of memory is the 400MB at the end, but there's 600MB free overall. But if you try to malloc 500MB, it will fail, because there's no unbroken 500MB to put it in.

That's a contrived example, of course, but you can probably imagine that the longer your game goes on running for, allocating and deallocating, the more fragmented your memory might become! Big game engines often implement their own memory management system to get around this, where they land-grab a massive chunk (gigabytes) of memory as soon as they start when they can be fairly certain they'll get it, and then organise how that memory is allocated manually, to ensure it meets their requirements. Not that I'm suggesting that's a worthwhile use of your time for your framework.

There are other possibilities for what your problem is, of course (like what Dabz was mentioning earlier) - I don't really know anything about how the 3DS does its memory allocation. Just throwing this one into the mix as something to be aware of.

-=-=-
A mushroom a day keeps the doctor away...

Keep It Simple, Shroom!
Posted : Tuesday, 24 April 2018, 14:29
Jayenkai
If it is fragmentation it's certainly not MY fragmentation!! This is during load, so I've not loaded/freed/etc things. They're literally only just loading for the first time!

I'm thinking it's either just part of the way the 3DS's memory is set up or possibly something to do with the whole "You have to hack the 3DS with the homebrew launcher to get it running in the first place" thing.
.. Could be either.

I'm managing to work around it, now that I know exactly what's causing the many (MANY!) issues I was having.
It's certainly going to be interesting designing games that run well on both a 400x240 display, and a 1920x1080 one, without requiring god-awful unrecognisable art assets!

fwiw, one of my biggest arrays (Grid[]) has had to be shrunk down to 64Kb, the audio file limit also seems to be about 64Kb, and when loading images that seems to crap out at around the same size, too. So I'm definitely thinking it's probably an internal memory block size, or something.

-=-=-
''Load, Next List!''
Posted : Friday, 27 April 2018, 09:31
Jayenkai
The past week or so, I've been working with the following (approximate) code.

1. csndinit() to initialise the audio doohickey.
2. Load wave into buffer.
3. Switch to next audio channel (0-7)
4. Stop current audio in channel, if any.
5. csndPlaySound.. Play audio from buffer, into selected channel.

And it just hasn't been working, at all, no matter how hard I try.
I tried loading in different methods. I tried using alt-buffers inbetween plays. I tried so much debugging information to ensure the audio's still in memory when I go to play it, that you'd swear I was slowly going crazy.

Today, I found the problem.


.... Audio channels start at 8.. Every single fucking time that I'd been trying to play audio on channels 0-7, it was silent, because it didn't know wtf I was trying to do.

Gee, thanks for THAT error message, guys!!

*sigh*
OK, basic audio's finally bloody well working.

Next challenge.. OGG Streaming.

-=-=-
''Load, Next List!''
Posted : Friday, 27 April 2018, 15:16
Jayenkai

View on YouTube

Damn.. game's crashing when trying to stream the ogg.
Have gone back to just doing plain wav files for now, and I guess I’ll be ogging again, tomorrow!

-=-=-
''Load, Next List!''
Posted : Wednesday, 02 May 2018, 18:03
Jayenkai

View on YouTube

yaaargh!!!!!

-=-=-
''Load, Next List!''
Page : 1 2 3 4 5 6 7 8 9 10 11 12 Prev 13 14 Next