Go Back   Project64 Forums > General Discussion > Open Discussion

Reply
 
Thread Tools Display Modes
  #551  
Old 23rd May 2014, 01:20 AM
MarathonMan's Avatar
MarathonMan MarathonMan is offline
Alpha Tester
Project Supporter
Senior Member
 
Join Date: Jan 2013
Posts: 454
Default

Quote:
Originally Posted by HatCat View Post
As of last night I started to learn OpenGL programming from some basic 1.1 tutorials. It actually looks very interesting and fun, as it resembles what I was learning with OpenAL 1.1 versus OpenAL 1.0.
Be aware that the vertex/shader model in newer OpenGLs has completely replaced the fixed-pipeline model of 1.x... The vertex/shader model will yield significantly more performance for things like filters and the like. For stuff like blitting the image to a window, though, 1.x is fine.
Reply With Quote
  #552  
Old 23rd May 2014, 05:20 AM
HatCat's Avatar
HatCat HatCat is offline
Alpha Tester
Project Supporter
Senior Member
 
Join Date: Feb 2007
Location: In my hat.
Posts: 16,256
Default

I'm not sure that's relevant anyway since VI filtering does not pertain to 3-D vertices or shading, just bitmap filtering. mudlord did say something about being able to use GLSL or something to prevent the GPU from going idle during the VI filters, though.

Either way, it's obvious that the RDP is like 30x slower than VI filters, so exactly how this VI fix is done does not concern me atm.

Quote:
Originally Posted by RPGMaster View Post
Well I guess I should take a break from emulator stuff since I can't even compile half the stuff I want to work on ;/ .
You can do it!! There's always a way to compile something.

I'd say the hardest thing ever for me to compile was the Pidgin multi-messaging-protocol client for Windows. Their Linux build instructions were like so easy and biased, and like only a small group of people got it to build on Windows.

Anyway, all I really wanted was their IRC plugin to compile, since it's such a small and nice snippet of IRC implementation code to learn from.

Quote:
Originally Posted by Azimer View Post
I've done both... use me as a resource while I am still stalking our feline friend and reading these forums.
I R suspicious!

Quote:
Originally Posted by RPGMaster View Post
There's hardly any material for me to learn from for sound ;/ . I will try and look at zilmar's source though. Hopefully it will compile...
Aw come on. *Hopefully* it will compile?
Have you even downloaded the thing yet? It's not called the "Basic" Audio Plugin for nothing.

I learned about audio threading stuff from it kind of slowly but fairly. Maybe Azi's insight would extra clear some things up.

The only thing I didn't really like about it is that inline assembly code Mr. zilmar used for byte-swapping, but you're a fan for that kind of thing anyway so you ought to be used to that.
Reply With Quote
  #553  
Old 23rd May 2014, 07:38 AM
RPGMaster's Avatar
RPGMaster RPGMaster is offline
Alpha Tester
Project Supporter
Super Moderator
 
Join Date: Dec 2013
Posts: 2,029
Default

Quote:
Originally Posted by HatCat View Post
Aw come on. *Hopefully* it will compile?
Have you even downloaded the thing yet? It's not called the "Basic" Audio Plugin for nothing.

I learned about audio threading stuff from it kind of slowly but fairly. Maybe Azi's insight would extra clear some things up.

The only thing I didn't really like about it is that inline assembly code Mr. zilmar used for byte-swapping, but you're a fan for that kind of thing anyway so you ought to be used to that.
I just now downloaded and compiled it . It's just my style xD. C + inline assembly ftw! Now I have no idea what it's doing or how to improve it lol. At least now I have something to work on that can compile.

Now I have to figure out why I'm getting the "Failed in creation of Play buffer 1" message.

Edit, I had the program print out the error value and got 0x80070057 as the value. So i googled that and got DSERR_INVALIDPARAM as the result. Now I have to see how to fix this.

Last edited by RPGMaster; 23rd May 2014 at 07:42 AM.
Reply With Quote
  #554  
Old 23rd May 2014, 07:54 AM
Azimer Azimer is offline
Project Supporter
Member
 
Join Date: Dec 2005
Posts: 76
Default

Quote:
Originally Posted by HatCat View Post
I R suspicious!
LOL. I find your work intriguing is all and some of it may be of interest to me. I am interested in building a RSP Recompiler and I've always been interested in LLE graphics. Unfortunately, I just don't have the time like I use to so I've enjoyed the discussions.

Quote:
Originally Posted by RPGMaster View Post
More N64 specific. Thanks for the offer. Now I have more motivation . Will a basic plugin be good enough to get me started? After I spend some time with it, I'll have more questions to ask. Lol I suppose I could also try to compile 1964 audio and just test it on 1964.

If I do decide to work on sound, would Xaudio be better than dsound?
Basic plugin is enough to get started. I believe xaudio2 is the API to work with but dsound will give you a good foundation as well. dsound sits on top of xaudio2 from my understanding. I am transitioning my audio plugin from dsound to xaudio2 but will keep the dsound implementation as well for older systems.
Reply With Quote
  #555  
Old 23rd May 2014, 08:36 AM
HatCat's Avatar
HatCat HatCat is offline
Alpha Tester
Project Supporter
Senior Member
 
Join Date: Feb 2007
Location: In my hat.
Posts: 16,256
Default

Heh, yeah I can understand that. Not having time to work on whatever the hell I like to sure does suck, but I'm not really able to compare to zilmar or yourself in that aspect since I haven't been throttled with that feeling since High School or perhaps my last semester of college. I'm not really old enough yet.

That play buffer 1 error in the basic plugin sounds familiar; I vaguely remember getting that when I was playing around with some of the DS functions too. The DSERR_INVALIDPARAM you mentioned means that you must have touched one of the arguments to one or more DirectSound API functions. For example if a WINAPI function expects an operand of TRUE or FALSE, and you say POTATOES (defined to 9001 or w/e), you get DSERR_INVALIDPARAM.

Yeah, the thing about DirectSound, is that Microsoft is going to look down on you for using it now. In the sense of them no longer maintaining the DS layer, it's deprecated. All their top support/enforcements with full audio hardware support etc. request you to use XAudio. So if you're going to use DirectX or a Microsoft Windows audio API, afaik XAudio is the way to go. That was one thing that suanyuan did do right: N64 audio plugin dev suffers from the fact that virtually every win32 audio plugin out there uses a single API, DirectSound.

The concept of SDL is interesting in my experience, but for audio I wouldn't recommend it. SDL is mostly good if you suck at APIs in general, like me, since it gives you a very very very basic functions reference that even I was able to understand. (Hell if this plugin was using SDL instead of DirectDraw, I could just call SDL_SaveBitmap(filename) to write the BMP screenshots instead of spending hours writing my own BMP header spec.) Ultimately though you don't want to finalize something to use SDL for audio. OpenAL is my intention and seems to be today's leading competitor to DirectX audio; the problem is that Microsoft doesn't guarantee that it won't fall back on the old DirectSound software layer if you're doing audio in OpenAL, unless it's run on WinXP with hardware DirectSound3D.
Reply With Quote
  #556  
Old 23rd May 2014, 10:09 AM
RPGMaster's Avatar
RPGMaster RPGMaster is offline
Alpha Tester
Project Supporter
Super Moderator
 
Join Date: Dec 2013
Posts: 2,029
Default

Quote:
Originally Posted by HatCat View Post
That play buffer 1 error in the basic plugin sounds familiar; I vaguely remember getting that when I was playing around with some of the DS functions too. The DSERR_INVALIDPARAM you mentioned means that you must have touched one of the arguments to one or more DirectSound API functions. For example if a WINAPI function expects an operand of TRUE or FALSE, and you say POTATOES (defined to 9001 or w/e), you get DSERR_INVALIDPARAM.
The thing is, all I literally did was set it to release mode, and added the library directory for dxguid and then compile.. I guess I downloaded a modified version?

Where can I find the official source?

Lol I totally didn't know you could debug dll's in MSVC! I feel like a noob now.

Last edited by RPGMaster; 23rd May 2014 at 10:20 AM.
Reply With Quote
  #557  
Old 23rd May 2014, 10:38 AM
HatCat's Avatar
HatCat HatCat is offline
Alpha Tester
Project Supporter
Senior Member
 
Join Date: Feb 2007
Location: In my hat.
Posts: 16,256
Default

Nobody's holding out on ya. That's the one and only source tree to the Basic Audio Plugin I've ever heard of. I probably starting building it off the source code distributed through the EmuTalk plugins section. That's probably how you acquired it, correct?

I had no problems building it. I don't remember whether or not I had to switch it over from Debug to Release mode though...I think you have to distribute the SUO file or something for the project to remember whether you have it configured to Debug or Release, but that file includes info about your home directory system and your user folders on Windows so I never include that file anyway.
Reply With Quote
  #558  
Old 23rd May 2014, 10:43 AM
RPGMaster's Avatar
RPGMaster RPGMaster is offline
Alpha Tester
Project Supporter
Super Moderator
 
Join Date: Dec 2013
Posts: 2,029
Default

Quote:
Originally Posted by HatCat View Post
Nobody's holding out on ya. That's the one and only source tree to the Basic Audio Plugin I've ever heard of. I probably starting building it off the source code distributed through the EmuTalk plugins section. That's probably how you acquired it, correct?

I had no problems building it. I don't remember whether or not I had to switch it over from Debug to Release mode though...I think you have to distribute the SUO file or something for the project to remember whether you have it configured to Debug or Release, but that file includes info about your home directory system and your user folders on Windows so I never include that file anyway.
I downloaded a zip file off emutalk. I guess I'll try debug then. It had outdated project files like Basic Audio Plugin.dsp.

Edit: I figured out the problem! It's just not compatible with the game I was testing lol... I'll have to keep that in mind from now on, to add more variation to my tests.

Last edited by RPGMaster; 23rd May 2014 at 10:54 AM.
Reply With Quote
  #559  
Old 23rd May 2014, 10:59 AM
HatCat's Avatar
HatCat HatCat is offline
Alpha Tester
Project Supporter
Senior Member
 
Join Date: Feb 2007
Location: In my hat.
Posts: 16,256
Default

Not compatible with the game you were testing?

And what was that? World Driver Championship/Stunt Racer 64? Those games from what I've seen delay the initialization of AI_DACRATE_REG, and since zilmar's audio plugin times the DirectSound buffer creation at AiDacrateChanged this causes the plugin to crash (actually Azimer's audio 0.56 too I think). Jabo's and LaC's audio plugins use a different DirectSound implementation that manages the buffer recreation independent of changes to the AI_DACRATE_REG, somehow...can't remember if I ever found a fix to the issue myself so I probably didn't.
Reply With Quote
  #560  
Old 23rd May 2014, 11:02 AM
RPGMaster's Avatar
RPGMaster RPGMaster is offline
Alpha Tester
Project Supporter
Super Moderator
 
Join Date: Dec 2013
Posts: 2,029
Default

I tested it with Super Smash Bros. Then I was like "wait a minute, why don't I try other games". Then I tried f zero and it works pretty well too. At least now I got something to work with. It's exciting learning something new each day .

Edit: WOW. Compiling with Clang, solved the problem. What a weird coincidence. I love how I find/fix things while doing something else, yet when i try to look for/fix things, I can't figure it out. I just wanted to see if the plugin would run better, using different compilers. What a difference! Also, this plugin is pretty good. Its timing is good and there's no freezes like some other plugins. Really the only issue is maybe compatibility, and the crackling sound.

Last edited by RPGMaster; 23rd May 2014 at 01:07 PM.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT. The time now is 12:07 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.