OpenGL 3.2 in Pioneer

Posted by | Posted in Game Development, Pioneer | Posted on 19-11-2014

I just merged in my changes to update Pioneer to use OpenGL 3.2 on Windows/Linux/OSX and since I haven’t posted about anything in a while now seemed like a good time to describe those changes, and why I’ve made them.

Pioneer has been using OpenGL 2 for many years now, it even supported the fixedfunctionpipeline until not long ago and it’s rendering system has stopped Pioneer from being ported to run on mobile class devices which typically use OpenGL ES. It used methods that have become deprecated including the matrix stacks, built-in lighting and texture coordinate structures and had several performance sapping calls to glGet* functions.

Over time I have removed all of the glGet* function calls, which improved performance and consistency but put off the really big rewrite to refactor everything to use our own matrix stacks, lighting and texturing for a long time. Eventually the lure of modern Vertex Array Objects tempted me and I bit, sadly this broke the OSX version of the game and I didn’t even notice for a few weeks.

This was the straw that broke the camels back. I knew that OpenGL 3.2 would work on OSX/Linux and Windows for most people from experiments/rewrites I had done, but struggling along with all of the old crud and extensions was taking up a lot of time and making it almost impossible to progress.

Perhaps a better coder could have found the magic combination of incantations required to make everything work across of them and retain the OpenGL 2.x setup we had but I am only human so that Sisyphean task could go and kiss my ass.

There will be no talk of the “future” in this post since I’ve learnt my lesson that discussing it just means it gets sidetracked and won’t happen within anything like the timeframe I thought it would. Of course these changes means that there will be bugs, there will be performance issues and opportunities, there will be features that people will magically want adding in zero time ;) and so on and so forth. We’ll just have to deal with them as they occur.

NB: I have removed the links to the older 2.x compatible executables as they were removed from the download page at some point.

Andy

Birthday Depression

Posted by | Posted in climate change, environment, film, Life, movie, plot | Posted on 31-07-2014

I might possibly be crazy as no-one else I know seems to get this way about their approaching Birthday so I thought I’d jot down how I feel as I approach 35.

Yep, 35 years old. An age that’s neither too old nor too young, for me it’s something of a nothing year. Just like all of the others.

Let us take my 30th as an example. I wasn’t worried about my 30th Birthday except in one specific way: It was my 30th therefore people would expect something of it.

A party, drunken nights out, some big event. The trouble was that like most of my birthdays I really couldn’t have given a shit.

The day was saved by Danni who organised a great day, with drinking, showed the original (and as far as I’m concerned: only) Transformers: The Movie at a small local cinema, with more drinking and celebrating as the evening went on. Just as well she did too because otherwise I’d have been sat at home with a beer/wine reading a book.

In the here and now as my 35th approaches my parents are asking me to update my Amazon wish list. I use it as a sort of bookmark for “things I will never buy and don’t really need/want but they looked shiny when I was browsing that one time…“. Friends ask/demand that I do or do not do parties and drinks and things either when they are or are not around, and many people seem to want to know what I plan-to-do.

On any given day I have no plans, ever. This isn’t some stubborn male thing, although it is more prevalent amongst my male peers I’ve noticed, perhaps it’s because we’re completely out of control of our lives.

Whenever I do make plans I inevitably discover that they conflict with someone else’s plans which were laid down during the time of William the Conquerer and are apparently recorded in the Bayern Tapestry so why didn’t I check that or at least respond to the FaceBook invite (I’m not on FaceBook)? Inevitably these plans take, at least historical, precedence and once this has happened for the 500th time (I’m a slow learner) you get the feeling that no-one gives a shit what your plans were anyway even if they don’t conflict with someone else’s, so why make them if it’s an exercise in futility?

Thus I find that like so many male peers I totally suck at planning things. So, no, I don’t have anything planned for my 35th.

Now the depression part.

Well I’m getting older, I’ve noticed it of course. I’ve been going to the gym and seeing a personal trainer for almost 2 years now. We’ve changed my diet, my drinking and I’m much more active. This has resulted in me achieving a little better health than absolute stasis. I am slightly fitter than I was, slightly less fat, slightly stronger and much, much, poorer. Oh fine I am also quite a lot happier that I’ve achieved that much rather than the stubborn and rapid decline that I was previously going through ;)

Still the fact remains that I’m greyer and things creak and ache more than they used too. These aren’t things I feel like celebrating or enjoying. The good bits sure, but most of those don’t revolve around this bizarre present giving ritual we’ve built up around “Birthday’s” as a special thing. It feels more “Hallmark(tm)” than Birthright. I long ago grew out of presents, most of the stuff I want I buy myself but more importantly the things that I want are either outside of the price range people can afford, or simply intangible.

I don’t want more stuff or possessions instead I want time-off, happy friends, world peace, good news, all sorts of hippy thoughts and mumbo jumbo like that. Now the thought of costing my friends money to buy me a round, or get me a gift disturbs me. It’s the opposite of what I want for them, from them, or our friendship. Sure when I was younger I loved getting toys, books, t-shirts and I still do get part of that feeling when they’re given as honest gifts but something has soured about the experience because I as an adult know it has cost them something in time, effort and money which are 3 things that I finally realise are more than just words.

All of this culminates in some mess of dreaded expectations, plans that’s don’t exist and a feeling of responsibility that I really should have done something with my life by now all because of a single date that comes by every damned year. It’s all atop the things that are already bothering me.

To end all this then please don’t get me wrong: If you enjoy your Birthday and celebrate it then I will be right there, buying you drink and handing you the gift that I spend time, effort and money getting for you and wishing you a sincere and heartfelt Happy Birthday – whatever you do just don’t entrust me with planning anything (see above) for it.

We are all different though, so as we would celebrate your Birthday as you would wish, could we just sort of … relax when it comes to mine? I’ll be out for a beer at some point – I would have been anyway. I’d prefer to buy my own drinks, and to only have between 2 and 4 in the entire night. No cards, no gifts, no crazy shit (crazy shit is alarmingly normal for me), I’d prefer to read a book, watch a film and chill out without organising, or being organised against my will.

That’s a Happy Birthday.

Andy

Making more work

Posted by | Posted in Game Development, Pioneer | Posted on 09-03-2014

After taking a look at the awesome No Man’s Sky videos and artwork I decided that enough was enough: Pioneers terrain engine must die!

Now I’ve been “meaning” to do something about it for several years, and I have done bits of work too it over the years: reduced it’s memory footprint drastically, refactored it internally, multi-threaded it with a job system, numerous optimisations etc. There’s some things though that I’ve just left well alone.

That time is over: yesterday I merged some work-in-progress code that takes the underlying GeoSphere code and splits it into 3 classes: BaseSphere, GeoSphere and GasGiant.

In future there will be more splits because Stars are still rendered with the GeoSphere system meant for CONSTRUCTING PLANETS! That won’t do at all.

It also means separate shaders, materials and all manner of other technical bits which means that the way gas giants are generated and rendered can now start to diverge drastically and rapidly without worrying about breaking the way that stars or rocky planets are created. Even just doing this much has taken a surprising amount of time mostly because I do this as a hobby and don’t have a lot of opportunity to dedicate too it. Also my real job tends to leave me without an awful lot of spare mental capacity at the end of a day.

Progress s progress though and there’s  couple of other things coming up.

  1. I’ve been working on implementing terrain texturing, which you can read about on the forum, and am currently writing the system to manage to tiles and build the texture atlas.
  2. GPU generation of gas giant textures, hopefully allowing for less CPU work and bigger textures, possibly updating them in realtime someday in the future.
  3. Placing instanced detail objects – think trees, rocks, grass etc – this ones very very early work though don’t expect it … for a long time!

I haven’t forgotten the Oculus Rift stuff either, it’s just a little bit down the priority list.

Oh and I am now on Twitter, although I haven’t figured out why yet.

Oculus Rift and Pioneer Space Sim progress

Posted by | Posted in Game Development, Oculus Rift, Pioneer | Posted on 20-02-2014

Yes progress, real progress!

That there is a video of the Intro menu being rendered onto a quad, and the 2nd video is of the ingame GUI/HUD being rendered onto a Quad.

The things that I DON’T show are the messed up sector/system view screens, or the projected city/planet/object names which go all over the place and the Quad isn’t centred because I’ve just been hacking in it’s position without a care in the world :)

 

I should have been in bed about an hour ago, g’night!

Oculus Rift and new cockpit model.

Posted by | Posted in Game Development, Pioneer | Posted on 04-01-2014

screenshot-20140104-150433screenshot-20140104-150435screenshot-20140104-150451screenshot-20140104-150507screenshot-20140104-150540screenshot-20140104-150543screenshot-20140104-150547screenshot-20140104-150549screenshot-20140104-150551screenshot-20140104-150555screenshot-20140104-150624screenshot-20140104-150637screenshot-20140104-150642screenshot-20140104-150644

 

Pretty, better in motion but I haven’t gotten a way to record yet :)

A new year!?!

Posted by | Posted in Game Development, Life, Pioneer | Posted on 04-01-2014

Seems I haven’t updated since September.
Well I got a new job, I’m now working on Unreal Engine 4 via my employer Pitbull Studios.

Still doing Pioneer stuff, I’ll post a review of work done and work to do some time soon-ish.

2 weeks already?

Posted by | Posted in Game Development, Life, Pioneer | Posted on 13-09-2013

Wow time really flies when you’re … um, reading books and going to the gym more often?

Ok so I have been doing some programming on Pioneer; fixed up the solutions & projects for VS 2012 & 2013 Preview (I could do VS2010 too but am not touching 2008!) to deal with latest changes, fixed the GLEW changes to get it all building and compiling and then took up the Oculus Rift integration again – that’s a bit hairy that stuff since I’m having to modify a LOT of stuff in Pioneers rendering process.

Anyway the result so far is the following;

  • distortion shader working,
  • head tracking working,
  • rendering two cameras to a framebuffer working.

screenshot-20130911-205145

So all done huh? Nope, not by a long shot.

There’s a lot of other stuff that needs to be done to get a 3D projection + FOV + view offsets for each eye and a few other bits before we actually get a working 3D view and I haven’t worked through all of that yet since I’ve been busy with time consuming other stuff.

Unexpectedly, probably only to me, some of it is just stuff that didn’t used to take much time at all but is now quite time consuming.

Take going to the gym, this is what it used to work out like:

  • Leave work & walk to gym (11 mins)
  • Get changed (3-ish mins)
  • Exercise (30 mins)
  • Shower and get dressed (10-ish mins)
  • Hurry back to work stopping at Tescos (15 mins)

I think that in truth that used to usually take about 1 hour and 15 minutes, sometimes longer if we’d been doing leg work and I couldn’t walk as fast on the way back. Now however I’m coming in from Beeston which entails an extra train journey, and because I don’t choose when the trains run I have to catch them based on which one gets me there _before_ my session with my personal trainer. This means that I’m getting in quite a bit earlier, but that I’m travelling for much longer and due to the scheduling granularity of the trains… well, I left the house at 11:30am and got home today at 15:00pm just to do a 30 minute session. I could have gotten home earlier today, but decided that since I’d be missing one train anyway I got a haircut (I’m male, so if it takes more than 10 minutes to cut my hair then something is wrong). So I could have shaved 30 minutes off that (Train schedule) but even so it’s around the 3 hour mark to go to the gym just once.

Everything has scaled similarly though, popping out to get milk was to the nearby Tesco Express and less than 10 minutes but now involves walking across Beeston to the big 24 hour Tescos (or further for Sainsburys) because that’s the nearest one that does the Lactofree stuff. I’ve also been getting to the doctors (knee injury and anxiety attack stuff), dentists (keep flossing!!!) and the talking therapy place for an assessment (I’m not mad, might want to work on my confidence in a couple of months – quitting was the right thing to do apparently!).

At first I was worried about how this was going ot impact on two of my stated goals from the previous post:

  1. Work through some UDK tutorials – the new job is on Unreal Engine 4 so I think getting a footing in the tech’ will be good for me,
  2. Work through Frank D Luna’s D3D 11 tutorials but convert them to OpenGL 4.0 – Been meaning to do this for a while, it’s a good ramp up and parallels these SlimDX posts,

…but screw that, I’ve really really really (emphasis!!!) needed this downtime to get myself sorted and simply running into yet more challenging stuff and then freaking out about that wasn’t going to help anyone least of all me.

My plans haven’t changed, I still want to dive into the UDK stuff – I have it all installed and a selection of tutorials ready, I’ve just pushed the start of it back until this weekend or Monday. That takes the pressure off me for doing the Pioneer Oculus Rift integration which is acting like a pressure valve and gentle reentry into doing some coding again for fun.

Now though I’m going to go and tidy up downstairs before Danni gets home. She’s started at a secondment to a new primary school which is in Special Measures. It’s taking a lot of her time and mental capacity, everyone there is under tremendous pressure, so I’m trying to suck less at the housework. Of course I come from a position of sucking _utterly_ to begin with but I am getting less awful :)

 

Andy

I’ve left Crytek

Posted by | Posted in Life | Posted on 01-09-2013

Well this should probably be another post about Pioneer and it’s terrain generation / rendering, instead that’s all taken a back seat as things have gone steadily more wrong at Crytek and I’ve finally quit.

I wish I could put my finger on the “what” of went wrong but I’ve struggled to do so.

The effects however are much easier to list:

  • anxiety
  • panic attacks
  • no concentration at all
  • some truly terrible code (embarrasingly bad at times)
  • really struggling to implement even basic algorithms because of all the above

I finally got some medication to control the panic attacks and have been referred for other help but suffice to say that whatever the combination of things wrong with my time at Crytek it simply didn’t matter anymore, I had to get out.

Seeing that things were not right I started looking for something else and decided that I had enough strong leads – and with one offer on the table already – it was simply time to get out.

 

Friday 30th August was my last day and for that last week I didn’t need to take the anti-panic-attack medication once during the proceeding week.

I felt much better, I felt enthusiastic again, I had energy, I even started doing some coding at home and on Pioneer after months of twiddling with projects and solution updates.

 

I accepted the offer I’d had, it’s a work from home role and I’ll discuss it in another post in the future, that starts on the 30th September so I have a bit of a break to get better again.

To that end I’m going to do a few things:

  1. Work through some UDK tutorials – the new job is on Unreal Engine 4 so I think getting a footing in the tech’ will be good for me,
  2. Work through Frank D Luna’s D3D 11 tutorials but convert them to OpenGL 4.0 – Been meaning to do this for a while, it’s a good ramp up and parallels these SlimDX posts,
  3. Get back to doing Pioneer coding – I have a massive to do list for this,
  4. Cycle around the nature reserve more and in town when I go during the day,
  5. Keep going to the gym and eating healthily.

That’s a lot of things but I’m not going to fit them all into a month :D these are things I’ll simply be starting in this month, and taking slowly so as not to get overwhelmed. I suspect I’ll stop the UDK ones once I’m up to speed at the new job and I’ll be flexible with myself about all of the above, doing more or less as I see fit and when I feel fit.

 

Right now… off out for Sunday lunch with Danni and other friends :)

More “recovery” don’t ya know!

Yeti

 

PS: I should probably on reflection, add that Crytek isn’t a bad place to work, far from it, lots of people seem to really like it. All of the above is solely how *I* have found it.

To shard, or not to shard?

Posted by | Posted in Game Development, Pioneer | Posted on 01-07-2013

To shard, or not to shard? Is the wrong question.

I came across a bit hard on sharding in my last and have rightly been called on it a couple of times so I’m just going to quickly clarify.

When You Should Have a Shard:

You will be have various “shard“s your game at least two in fact.

Read the rest of this entry »

Space MMO – Pioneer-alike

Posted by | Posted in Game Development, Pioneer | Posted on 29-06-2013

Space game MMOs… A brain dump:

I’ve been inspired to brain dump by a post on the Paragon forum.

To quote:

Will multiplayer be instanced or MMO style?
If MMO will players be able to transverse to other servers/galaxy’s with their ships,equipment and credits?

Now, leaving aside the question of what they might mean behind instancing, lets instead think about how a space game like Paragon, not Pioneer note, Paragon might choose to implement an MMO gameplay model.

NB: Paragon is a sort of daughter project to Pioneer. It’s forked from the Pioneer codebase and occasionally pulls in work we do. However Paragon has it’s own developers, development and game specific code, scripting, storyline and art. I’ll be discussing these things from being a Pioneer developers point of view.

Read the rest of this entry »