Sunday 25 June 2017

832 well its still not too bad,

Got the chapter about light in place now and the shaders for vertex and fragment lighting so thats pretty good. a bit more chopping done but no content really lost, I just noticed I was repeating myself a lot

here's the results of the vertex lighting shaders. 1st Screen shows the left model with no light, and right with light.




2nd image has both lit and you can see the lack of light on the belly of the upper ship.


Wasn't at all hard to do, but a bugger to explain simply and maintain a render system that could draw with or without light, thats not normally something I would do, but not to worry it works.



Saturday 24 June 2017

830 they'll kill me a bit less

Shunted some stuff to the Website, and rewrote some overly waffly bits...still more than they want but...hey...


Monday 19 June 2017

870pages my publishers going to kill me

well he's going to anyway for being so late. But I'll eave the edits to them.

Another good day done, I got more of the basic object defines in place to allow the physics code to be visible. Not without issues of course, there are always issues! But despite astonishing heat, and totally useless cooling in the office, I managed to get quite a bit done today, and write it up and endit a few other sections.

Back to work tomorrow though so not going to be able to do much, hopefully today's work will allow me to target the things I need to get done in the breaks.

I will get the MD2 models and lighting system sorted next. They are all working find, but the code is rough and needs a clean up, and a very slight introduction in the text.


Please be over soon...please! I'd like to enjoy this heat, sitting in my back garden with a pitcher of Margarita's not slaving in a hot room in front of 3 screens



Sunday 18 June 2017

is it done yet?

Oh no....but so close, I just wrote up in my main  blog how this last few steps are proving so hard, every thing that can go wrong goes wrong. Small simple tasks I expect to do in 5 mins take 5 hours and so on, its as if nothing I can do will actually work on a Pi.

But that said, I've pushed and pushed and pushed and the last few bits are almost done.. I've  written all the code to create the last few projects, apart from the implimentation of some physics and the rendering of the physics representation objects...that should normally only take a day at most....so expect it to take a month.

groan.

On the plus side, despite all this hassle the actual quality of the projects on the Pi is really amazing to see, its very clear to me that the machine simply isn't being pushed by people and the rather poor quality of games and graphics on offer can easily be exceeded.  So I really do hope my now massive (850 pages)  book encourages people to give these little beasts the attention they deserve it can do so much when its actually coded at its native level.

Ok enough posting...back to work.. No new SBC's bought recently, a few new Nano and Banana's have hit the market that are worth a look but I'm not going to get into them till the book is finished. The Tinkerboard is still the most exciting and its had a few updates to its OS, but still no drivers yet, I won't touch it till it has ES3.1/2 drivers.

Oh and the website is up now at Scratchpadgames.net There's nothing there yet, but I'll start to populate it soon.

Onward and downward, or at last try for a shallow attempt at an upward direction

Tuesday 6 June 2017

And another Giant step

The Skyboxes are working again, transferred from the old projects, and with the model loaders all working as they are supposed to we're up and running again.
the Space and Race games (same framework, different complexity) can now continue

and to add to that, a very serious and strange random bug has been squashed, and the camera is now functioning just fine, its all starting to work again...phew.

Finally moving again

After all the hassle with the car model I was looking forward to moving ermm forward...sadly the car was only 1 of my issues, I also have terrible problems with my skybox, until I realized I was not following the actual advice I put in my book. The part where I said, "always indicate to the user when you have a failure to load data".........yup, I hadn't put the textures in the transfer list so they never got sent to the target for building, so they never got loaded and I didn't have an error notice in the code!!!


Even very old game coders can repeat very basic errors.

And it can suck up time in ways you just can't image. Anyway, the car and skybox are in place again, now to get the track running and activate the physics.


Thursday 1 June 2017

WOW why do the simple things go wrong at the end!

I've had a nightmare couple of days trying to use a particular model in my race demo game. One of the last real coding tasks I had to do.
I wanted to use it for a number of reasons, not least of which is its a very cool model. which also comes with a normal and specular map.

But try as I might I could not get the damn thing to load, There were a range of small issue that stopped it.
The Jpg files didn't load correctly for 1, the obj references a texture on the makers PC, the 1st shape was a convex hull with no texture, there is a transparent window section, there's multiple detail shapes that don't need to be rendered (which is useful to explain occlusion)

Somewhere along the line, the jpgs and or the texture coords got mangled.. though they worked fine in other model viewers, TinyObjloader wasn't having it.

But after 3 days of exporting, in different packages, reducing the vertex counts and a range of other things.. I got it to work.
Behold, a 20,000 face model,  Though I don't have a suitable shader for the windscreen at the moment