Archive for the ‘visuals’ Category

h1

OGRE integration

June 6, 2009

Well, I’m beginning to integrate OGRE, and lemme tell you… it’s growing on me. I also find that it can actually be quite slim when you leave out the utility components and do most things yourself. I just want it’s fantastic material system. I’m beginning to figure out just how unbelievably moddable this can make the game as well. In addition to loading an Actor file for every ship, that actor file will reference an OGRE material and mesh file, which is also fully moddable. I’ve also mastered the material abstraction system. For example, you can create a base class material called ship_material that implements normal mapping and paralax mapping over a main texture with all textures referenced by alias, then extend it with set_texture_alias on each ship, so none of that fancy shit has to be replicated, just say which textures to use and reference the .mesh in the Actor file. bam! I love modularity.

Advertisements
h1

Continuum Engine

June 3, 2009

That’s the name I have for it now.  It’s a badass name, no?

Anyway, I’ve got 3demon engine working as a rendering engine for now, but I still hate the Irrlicht style shadows it uses.  It IS a branch of Irrlicht.  They’re just so… broken.  They don’t even have a consistent appearance across subsystems.  OpenGL has a different volume method from D3D9 in it.  I want something like OGRE, but I absolutely hate the way it’s organized.

Does anyone have an idea as to what I should do?  I don’t want to use my own rendering engine because I’d like the focus of this project to be on the game itself this time, not every little technical thing to support it.  I will give OGRE a shot, and if that’s how it has to be, so be it.  But do you absolutely HAVE to use the ReferenceApp layer?  That, I put to you, is TERRIBLE API design.

h1

first post in a long while + some erosion progress

March 15, 2009

Well apparently school takes up time.  So it’s been a while.  But here goes:

I got all A’s on my midterms, so fuck YES!  I feel happy about that.  Good times.  I have been spending an increasing amount of time with other people as well.  I know, crazy right?  It’s me.  Apparently some people don’t hate my guts, and I seem to have met some in person.  They are decidedly cool.  Hence that last post about Travis’ birthday.  So, yeah.

What else?  Oh, making progress on the Qix clone, Erosion.  Here you go:

It has a game state machine with GAME OVER and gameplay states and whatnot.  It has much better graphics now, I implemented bloom with my old shader framework and improved the color scheme.  You can die, and I’ve even got gamepad working with rumble on collisions and all.  You will also notice that I replaced the simple bouncing bar with a bar with a thruster in a damped system that actually semi-tries to follow you.  Enjoy this clip:

h1

famous last words…confirmed

January 8, 2009

So I’m REALLY starting to freak out that maybe won’t get in to college.  Because while I’m certainly eligible, I got this crappy email that tells me: “yeah, you want a student loan?  this is your student ID, which you’ve had since before you were even sudo admitted.”  thanks for being clear, assholes.  I only have ONE WEEKEND to register for classes and get my fukken act together if I’m even in, which I don’t know, because they AREN’T BEING CLEAR.

Okay, thank you for your cooperation in terms of listening to a rant.  WAIT!  IT’S NOT OVER!  Some drunk fucker wandered in to our garage and started knocking things over!  Full story here.

But anyway.  Those it-should-be-easy-to-get-depth-targets-to-work-in-Direct3D last words?  Yeah.  Apparently, it can’t handle rendering to a depth texture, so you have to create a depth stencil render target.  But you can’t just use that.  Ohhh, no.  Apparently depth components can’t be reinterpreted without shaders.  This makes no sense, as OpenGL has had this capability FOREVER.  So it actually takes a simple pixel shader to copy from the depth target to a usable texture, a red only format texture.  Talk about clumsy and stupid.

So the long and short of it is that I now have to have two classes of rendertarget, (yes, even for OpenGL as I can’t break unified API,) one for color and the other for depth.  In OpenGL, it’s actually the same class with two settings.  In Direct3D, it’s two seperate classes.  pfft.  I don’t like it, but I’m pleased to say that the actual API needs only ONE outwardly apparent change.  The CreateRenderTargetTexture() method now has a new argument: targetmode, which can be RAVEN_RENDER_TARGET_COLOR or RAVEN_RENDER_TARGET_DEPTH.  The rest is transparent.

Sooo… yeah.  Workin’ on it.

h1

WOOOOOOO GDB WINS!

January 6, 2009

So, I managed to isolate EVERY KNOWN BUG in RAVEN so far, and fixed them.  I feel good about that.  In addition, rendertargets are working in Direct3D.  I will add a depth target texture  for Direct3D rendertargets soon.  I also fixed the font not pixel perfect issue with Direct3D.  I had to shift the X,Y coordinates by -0.5, because apparently even untransformed vertices in Direct3D are not mapped directly to pixels.  Stuuuuuupid.  And I also added an alpha argument to the material constructor because having to set it after the fact is just plain hackish.  That also solved the fact that alpha wasn’t explicitly initialized, causing consistency problems.  Big time.  Another bug that was fixed.

All thanks to my l337 programming sk1lz and GDB.  Is there anything GDB can’t do?  Excellent debugger AND payload delivery system if you happen to be a hacker!

All I have to do at this point is get the Direct3D rendertarget working with a depth texture and stick in HLSL support.  It shouldn’t be too difficult (famous last words…lol) so stick around.  Then I can maybe add bitmap font support!  I’ll probably take an Irrlicht approach on that one, I really like their method.  I feel like this project is seriously trucking along!

And… I really hope I get my ACT results back soon enough to register for classes.  I feel somewhat worrisome.  If I can’t follow through, I’ll have to wait ’till next year.  And then I’ll have to wait and feel bad about myself… sigh.  Here’s hoping.

EDIT!

Seeing as how no one has commented yet, I feel fine just editing this post.  Here are some screenshots of the rendertargets working in Direct3D!  OpenGL is exactly the same in appearance, so really no need to post them.

If that isn’t just balling, I don’t know what is.  Next up:  HLSL support!

h1

wooo, fonts! and materials! and manga?

January 5, 2009

FONTS ARE FINALLY WORKING IN DIRECT3D!!!

They are!  There’s kind of a texture sampling issue with it, but that’s insignifigant, and they look fine.  It might just be shitty Direct3D texture coordinate precision I can’t do a damn thing about.  So here’s the screenies:

Direct3D 9 Test (fonts aren’t quite pixel perfect):

OpenGL Test (fonts are pixel perfect):

It may be a fencepost error on pixel ratio calculation that causes the font pixel precision problem in Direct3D.  I’ll fix that.  But hey, I can now finally get rendertargets working in Direct3D.  Then I’ll implement HLSL support with the same shader object class interface, and I’ll be up to snuff.  I’ll finally be able to start expanding the functionality again.  One thing I want to do is to add a streaming mode for vertex buffers so I can do dynamic vertex stuff.

Hey, did you notice the tasty per vertex alpha there?  The backface culling is disabled for this test, as it would keep us from getting this cool semi-transparent cube effect.  I have a boolean material setting in the material class that lets you switch between using material and vertex colors.  This is clearly vertex colors.

As you can see, I’ve also separated the specular component in OpenGL (using the extension, no multiple pass techniques unless it’s REALLY neccesary) in order to mimic the behavior which is default and usually used for 3D games in Direct3D.  The applications I develop for this should have as consistent and standard an appearance across platforms as much as possible, and this is really the best specular look (fixed pipeline wise anyway) for most surfaces.  If it’s otherwise, there’s always a shader for that.

I’ll have it all caught up on the Direct3D end soon.  At which point, further feature development begins.  Here’s something I want to add: Windows builds will use DirectInput for input.  This will allow me to code for my gamepad, yay! 🙂  GNU/Linux will use xorg devices for gamepads, same as all devices on GNU/Linux.  I may need to borrow a friend’s joystick to code for that.  We’ll see.

But hey!  I just recently started drawing manga again, which was my original art style.  I used to only draw manga, which I shifted out of at one point.  But I thought I’d make  another crack at it, and let me tell you.  NOT like riding a bicycle.  I’m just getting back in to it, this is a doodle I did just  a while ago:

I made this in The GIMP.  All tablet, no paper.

Yeah, I know.   Her shoulders are a bit too broad.  I don’t mind it though, the super feminized look is kind of rediculous to see in EVERY female character.  It starts to get redundant and unrealistic if overidealized.  Just saying.  But cool, no?

That’s about it.

h1

lighting problems: resolved

December 27, 2008

Just a quick post: lighting issues are RESOLVED.  When you set the ambient source to color for Direct3D it multiplies and OpenGL adds.  So I just have to do that part manually for Direct3D and everyone’s happy as a clam.