Skip to main content

Programmers

Description

Programmers can talk all about their craft here

Interested in Game Development

Forum

Hi Guys,
I living in Melbourne, vic. I started learning programming languages few years ago and starting developing my first pc/android game in June this year. The game is almost done and now I'm planning on taking up a new project.
I'm looking for people who are interested in Game Developlment. I want to assemble a team of free thinkers who love coding and are willing to learn.
If you're intersted in learning game development and programming or already have some exprience, please contact me.

how do you make a game for ps3,xbox,wii,pc

Forum

how do you start off developing a game

Submitted by Harrison (not verified) on Wed, 10/10/12 - 6:27 PM Permalink

Hey gamer 500, I'm 13. I've been in the same position as you, i hope ik able to help you. in order to make games, you need to learn to program... This can be a daunting task... It Is until you have your (what I call) eureaka moment... Generally youl be in the shower... Maybe having a bath or just relaxing and Boom , everything will make sense. You will understand classes functions EVERYTHING. I still get these but on more complicated problems (like collision detection).

At the moment I'm making my first game in flash. I managed to get the student discount on flash builder which is very easy (I got it with my buss pass). But in terms of what you want to do, I would suggest learning something called unity3D (if you have the money). As I believe unity is basically a multi-platform game engine for 3d games (if you want to make 2d games checkout futile). The only problem would be that unity costs money to release on those platforms you specified.

Another problem I have to present to you is that xBox and PS3 games are not compatible. (As far as I know). PS3/WII/most other consoles use a thing called openGL to render graphics (you don't really need to worry about this). On the other hand xboxes do NOT accept openGL, they use a thing called directX (which is basically microsofts openGL).

I really do recomend flash for getting started though. DO NOT go into python/pygame if you ever want to release your game. The easiest way to start games would be to download flash develop or flash builder trial. Then use an engine to get started (eg. Flixel or flashpunk).

I really hope this helped... If I'm not being specific enough email me: harrison@theshoebridges.com (also HIGH FIVE FOR BEING UNDERAGE AUSSIE INDIES!!!)

Submitted by CraigOZ (not verified) on Wed, 10/10/12 - 6:50 PM Permalink

I would suggest that you have a look at Unity 3D (Unity3d.com) as it is free to learn and can be upgraded to make games on all of the consoles, PC, Mac, Android, iPhone/iPad, Flash, the Web and now the WII.

Submitted by souri on Wed, 10/10/12 - 7:50 PM Permalink

I guess when anyone asks how to make a multiplatform game e.g for ps3, xbox, wii, pc etc, the Unity game engine will most likely be the most popular answer. And I would agree, it's a great choice. However, if you make a game using Unity and you want to release on consoles, you'll need to know that you're jumping completely in the deep end here, and it's gonna cost you a whole lot of money too - more money than you should be putting in for your first ever game.

In fact, the Unity website doesn't disclose the actual cost to license the engine for any of the consoles (PS3, Xbox, Wii etc) since you will need to contact them directly and they'll assess your project and discuss the costs involved to license their engine. To get a Unity game running on iPhone and Android, it is going to set you (using the pro versions) $4,500 US... so if you're thinking about consoles, then it'll undoubtedly cost you a whole lot more in comparison.

I think in your case, you shouldn't be thinking about multi-platform releases and consoles just yet. You need to start off really simple. Games are hard to make, and you're going to have to learn scripting or a programming language first. If you've never done this before, it can be a huge learning curve.

You can get the indie version of Unity to start off with which is free, but you'll need to learn C# to make a game. The other choice that others have suggested is Flash, but you'll need to learn Action Script. There are, however, much easier options out there that will get you to making your first games much quicker. Perhaps try out the free version of the GameMaker studio program?

If you want to make games but you don't want to program, I highly suggest something like Game Salad where you can make games with no programming knowledge at all. There's a free version available which you can export to Mac and PC, and for just an extra $270, you can then put your games out for iPhone and iPad.

Submitted by gamer 500 on Thu, 11/10/12 - 5:46 PM Permalink

Yes, thankyou, I have tried looking into Unity. But when I tried to install it I get a message saying "This requires administrator access to install successfully". I dont know what this means or how to fix it.
If you or anybody else knows what this means, I would be grateful to know

Submitted by gamer 500 on Thu, 11/10/12 - 5:48 PM Permalink

Hey Harrison, thankuuuu sooooo much for your response. Its nice to know there are other kids in the same position as me.
Hope we can keep in touch via this forum and help each other

Submitted by Conor on Mon, 22/10/12 - 11:28 AM Permalink

When you first install Windows on a computer, it asks you to create an administrator username and password. Only the administrator is allowed to modify Windows and install or delete programs. You'll have to ask whoever installed Windows on your computer for the Administrator username and password so you can install new programs.

Anyone else learning javascript this year at CodeYear?

Forum

Just wondering, is anyone else doing the lessons and tutorials at codeyear.com? Any absolute beginners ? How are you finding it all so far?

I've just completed this week's excersizes, and I've got to say it's quite a lot to take in. They've thrown a whole lot of OOP concepts in (objects, methods, inheritance, private/public etc) just this week. I might even do it again, just to let it sink in a bit better.

I got a few of my graphic design buddies to take part in Codeyear and learn some scripting/programming, but they dropped out after the first week. I'm not an absolute beginner with programming, but I did think that they were rushing through the basic concepts pretty darn quick for the first few lessons. No hand holding whatsoever. I think they have realised that however, since the last few weeks were basically revision and covering and explaining some of the concepts presented earlier.

There were some other early hiccups too (which still happens occasionally, apparently) where it would report your code as incorrect when it was fine, and you'd have no way to progress further with the lesson. I could imagine that would be extremely frustrating for people trying to learn this stuff for the first time.

Anyway, let me know what you think...

Submitted by Craig (Grapple… (not verified) on Sat, 18/02/12 - 12:46 AM Permalink

Hey! Yeah, I'm sticking with it. Some lessons are clearer than others, but overall it's good. I think that without the Q&A feature, I'd be sunk, so I'm glad there's a good community of people happy to help each other out.

I had struggled through a *tiny* bit of Unity scripting a while back, but could mostly be considered an absolute beginner (I'm a designer, not a coder). I'm definitely feeling more confident as I go along, so it's clearly working.

I think the main point to note is that the people behind it aren't necessarily educators, they're programmers with an idea to share. So some rough edges to the lessons can be expected. They're working it out as they go, and as you've pointed out, they're already learning more about the teaching process, including revisions now. I guess they'll get better at teaching as we get better at coding.

All in all, I really look forward to the new lesson each week, and it's free! I'd totally recommend it to anyone.

Submitted by souri on Mon, 20/02/12 - 1:40 PM Permalink

Yep, the Q&A feature is a god send. Even if you already completed the lessons for the week, it's still worth going through the Q&A section to see the different approaches people make - there might be a solution that turns out better than yours or makes you think new approaches. I'm gonna be finding the Q&A section more useful from now on though, since the lessons are heading towards the stuff I need to get brushed up on. I'd thought they'd be touching on this stuff somewhere much further down the line, not two months in! It makes me wonder how much they've planning to cram in for the rest of the year.

I really enjoy doing tutorials this way however - rather than reading or watching a video tutorial, things generally sink in better when you're made to try it out yourself. Especially when you fail, and you don't get to go further unless you figure it out.

I've got to say though, Javascript does a few things pretty oddly though. The way to round off numbers is pretty ugly. And how it handles private and public methods isn't as elegant as how it's done in C#. I'm hoping I don't get too used to these workarounds when I get back to C# ;)

Coder wanted for game dev fun!!!

Forum

Hey, I am a games artist looking for a coder for some side project game dev fun! I have a few game ideas in mind but I am also open to game ideas.

I work fulltime at a small games company but would like to focus my spare time on a side project (something I am more passionate about)

I am competent in both 2d and 3d but I am definitely a retro fan and would prefer to do a 2D game.

I'd like to work with some one fun, cool and easy going, not too easy going as I want to see this game done :)

Also I would prefer to work with someone on the Gold Coast as this would make it a lot easier to discuss and exchange ideas, however if I am convinced that we can maintain good communication via correspondence then I dont mind.

Hit me up if you're keen!

jonathan.j.chua@gmail.com

Sphere algorithm help

Forum

Hey guys,

Im trying to create a sphere made with square panels. The panels are all equal size.

Like a soccer ball but with squares. the squares dont have to be touching and the can have gaps between them to see through the ball.

Can anyone help me with an algorithm to correctly place x amount of square panels to create a sphere?

Junks from my head so far...
draw from bottom to top
botttom and top of sphere have smallest radius and increase towards center
panels change angles change angles from top/and bottom 180 deg
particle system maybe

Submitted by redwyre on Wed, 15/07/09 - 6:10 PM Permalink

Are there any certain details about the number of panels that you can exploit? (eg, number of panels might always be a multiple of 4, etc)

This seems like something that would be very difficult to get "correct". I expect something that looks good is enough? What are you trying to do with this? More details would help to find a more appropriate solution, a picture would be good too :)

Submitted by valmo on Sat, 18/07/09 - 5:16 AM Permalink

actually i think what would help me is an algorithm for a soccer ball.
there are 12 pentagons and 20 hexagons in a normal soccer ball.
so 32 panels all up.
it would be good if i can make an x panel soccer ball.
x would probably have to be divisible by some number y.
so it would be good to know what y would be as well.

i could then just change these panels into a squares with gaps.

New games programming blog

Forum

Hi guys,

I've started a new blog at Begin Game Programming

The site is going to offer tutorials in game programming beginning with a 2D game built using Visual C# Express and XNA Game Studio 3.0.

I've a few years experience working as a programmer in the games industry and have decided to share some of my knowledge with the wider community so this is an opportunity for those wishing to learn game programming to follow a program from the beginning and have access to an experienced games programmer for support.

Flash games

Forum

Is anyone doing any flash game development around here? I've had a go an it seems fairly accessible. With all the layoffs recently I would think that there are a few people doing indie flash stuff now.

Submitted by Anonymous (not verified) on Tue, 03/03/09 - 10:56 AM Permalink

i do. :) with flex/as3 and new tools it's a really good environment to work/experiment. and i've noticed many ui are now using flash.

Submitted by Anonymous (not verified) on Tue, 12/10/10 - 9:55 AM Permalink

Yea doing some myself with a mate, working on this at the moment www.bigblockgames.com , its in beta but its sort of a fairly meaty type space trading game. Seems like the perfect time to do it considering the Aus industry is a bit in the dumps right now.

Pointless journal pimping

Forum

In case anyone missed it, or wants to know more, I posted a blog item today with a link to the first in a series of articles I plan on writing about computational mathematics. It's got a long way to go yet, just give it some time :)

- Stephen

Submitted by StephenWade on Fri, 11/07/08 - 7:27 PM Permalink

p.s. i just uploaded a new version of the first part (next part coming soon) that is perhaps a bit easier to read, has less mistakes, and has more diagrams to help visualise what's going on! Hope it's helpful

Submitted by Anonymous (not verified) on Tue, 29/07/08 - 1:21 PM Permalink

Are you going to continue with the series? I found it informative.
P.S. Do programmers even exist here? I found this site about 3 days ago and the programmer side of things seems dead :(

Submitted by Zoid on Wed, 06/08/08 - 9:14 AM Permalink

I like both the articles, please keep them coming. They even convinced me to re-install Matlab from my uni days and start tinkering.

I'm not sure if i can call myself a programmer, but have always enjoyed it, and am hoping to (one day) go through all my matlab studies from engineering (system vibrations, rigid body dynamics etc) and re-learn them to try and work out a way to transfer them to C++, stuff like that. Still learning C++ though; have used a couple of different languages, but not any C languages yet.

Great work, and informative for those who haven't learned differential calculus etc, without needing to go into all the details. Keep 'em coming!

Submitted by StephenWade on Fri, 08/08/08 - 8:36 PM Permalink

Articles will continue ... !

Sadly I didn't get around to doing much C++ for the first two as it was quicker and easier for me to use Matlab to demonstrate. I am MASSIVELY busy studying honours in applied mathematics, so the rate of articles might be slow :)

So yes look forward to a bit of C++ implementation details, and perhaps an example a little bit more applicable to games. I *might* get around to discussing details about rasterisation and rendering of these kinds of things too if I can sort that out with some of my more graphically-minded programmer friends.

How to (software)

Forum

Heyas,
Seeing as not much action happens in here i thought id ask a question relating to the creation of software.
In particular something i want to make (but cant) so want some thoughts on how you guys would do it.

"The visualiser is a design tool created to aid in the concept design of real life Hot Rods. With a lot of time and effort that goes into designing concept sketches the visualiser will speed up the process and at the same time show the user his creation in true 3d all in real time"

The above is my short description of the software.
Does this explain what im wanting? (to a degree)

Basically i want something that visually looks like a 3d modeller (3d max, milkshape etc etc along those lines)
The user can import a basic car model and in turn modify the car with in the software. (wheels, motors etc etc)

My idea was to model each car model, car part , car modification seperatly. Then swap them in and out via the software. Would this be the right way to go?

I guess visual quality would have to be high too or perhaps a low, medium and high resolution option...

There are similar pieces of software out there that i have looked out but most of them are either slow or not visually pleasing. Plus they all use flash MX or similar software, which isnt a bad way to go i guess...

So guys any idea how i could get something like this going?

Cheers
Adam

Submitted by rezn0r on Tue, 15/05/07 - 3:29 AM Permalink

Wow, I think I have the same wish. I have a chopper that I've turned into a bit of a streetrod, and there are literally 1000's of parts you can incorporate... I've always been curious to see just what it'd look like with a snakeskin "Corbin Stinger" seat, shortshot Vance & Hines pipes etc... BEFORE I go and blow $800 per accessory without even seeing how it all fits together.

I've thought about a 3D program with all of the bits and pieces modelled so you can plop them on, but when I imagine it, I think it would end up being a rather junky program.

I quite like the flash based sites that show varous photo angles of the part (like this), for their simplicity, but it's then hard to get a good approximation of how it will look as a whole.

Two Thoughts:

You probably already have a good general idea of what elements you want to add to your Rod... you wouldn?t find yourself modeling the parts that you don?t intend to use on your own project. Have you considered that it may be a better alternative to bolster your skills in a proprietary modeling package, and only model the elements you?re considering? If all of your (usually scant) spare time disappears in your garage, maybe you could put together a good set of specs and references on the parts you?re considering, and work with a modeler here that?s keen to get a bit of extra practice.

If you?re considering this software as a business venture, it may be wiser to again do the modeling from scratch, and offer a service (like Virtual Mechanix except geared towards realworld mechanics). I?ve worked on (or near) enough ?3DSMAX except for X application? projects now to know how much time and money you have to throw at them to get something remotely useful.

My 2 cents.

Cheers,

Scott.

Submitted by melvosh on Tue, 15/05/07 - 11:08 AM Permalink

Scott,
Yep i have seen plenty of those flash style things, i agree they are nifty but...

Speaking of choppers there is a company that does do a chopper chop shop.
http://www.virtual-cycles.com
I actually spoke to them years ago when they were starting out about doing a car version with me, but i couldnt raise the capital to get me in at the time. Im sort of glad i didnt because the program they do is great but not quite what i had in mind.

I can model quite good so its not the modelling aspect im thinking about it was sort of one those "i wish" business ventures i have been pursuing for a number of years.

Yeh i could offer the service to real world car builders but my "idea" in long term was to allow the hobbyist and real builder to play with the software them selves.

But knowing how long it takes to model stuff i think this would be the limiting factor. I mean you couldnt really model every car and every part.
I wanted to limit it to Hot Rods as a start and so on.
I guess another factor would be how detailed do u go on the models...

Cheers
Adam

Programmer activities

Forum

Since it's been so quiet in here, I've been thinking we could liven it up with some programmer challenges or something. Since XNA is freely available and easy to get started with, perhaps we can do some simple challenges with that. Thoughts?

Submitted by Talvash on Mon, 07/05/07 - 8:36 AM Permalink

sounds ok to me, it means it would give me a real reason to download XNA and have a play with it. Till now i've been constintly saying "i'll DL it next week".

Submitted by Brawsome on Mon, 07/05/07 - 2:56 PM Permalink

Well I don't own a 360, so I suppose I'd be out of the XNA challenge. But I've been looking for an excuse to look into LUA lately, don't know if there's an idea for a challenge to do something that involves some very simple LUA. I really don't know much about it at all, but a good place to start if you haven't even heard about it is here: http://www.lua.org/about.html

Submitted by Brawsome on Mon, 07/05/07 - 3:00 PM Permalink

Just off the top of my head "Make a text based adventure game with 10 or more rooms, several inventory items, a goal and several sub-goals and 1 or more NPC's you can talk to. Do it entirely in LUA". I don't even know if this is possible... =0)

Submitted by redwyre on Mon, 07/05/07 - 3:44 PM Permalink

You don't need a 360, XNA is both on PC and Xbox360.

And I *really* hate Lua ;)

Submitted by Talvash on Tue, 08/05/07 - 1:43 AM Permalink

From what i hear it's a pain on te arse to get programs onto the 360 anyway you have to have an xbox (which i don't) am xbox live account, and a XNA dev subscribtion. It's much easier to just make stuff for the PC with it.

Submitted by souri on Tue, 08/05/07 - 6:51 AM Permalink

Why not do a puzzle like game instead?? Perhaps you could even eventually sell on Xbox Live Arcade if it all works out?

Submitted by Kezza on Wed, 09/05/07 - 5:31 PM Permalink

Not for me I'm afraid.
I've just started hammering away at modding UT2004 again.

Submitted by souri on Thu, 17/05/07 - 5:06 AM Permalink

So how's this going? I would love to see some programmer activity happening!!

Submitted by Talvash on Sun, 20/05/07 - 12:19 PM Permalink

Well in standard programmer behavior for this site sod all has happened so far.

I'm downloading XNA now, so i'll have a look at it for a while and see what i end up doing.

Submitted by redwyre on Sun, 20/05/07 - 5:18 PM Permalink

Have to let the word get around before anything starts, and that usually takes a while. But if people are ready and willing we could start soon.

Submitted by souri on Mon, 21/05/07 - 8:55 AM Permalink

Should we promote this is the next Sumea programmer challenge?

Submitted by poser on Sun, 10/06/07 - 12:32 PM Permalink

Some images using particles for a steam effect - really slows down the grapics card though - trying to work out why...
Steam 1
Steam 2
Steam 3
Found out why so slow - too many particles - 600 can just do with 100 and thicken them up / change cycle / speed. Quite quick now.poser2007-06-10 03:58:11

Submitted by Swiftless on Tue, 12/06/07 - 5:57 PM Permalink

I might be interested in the programmer challenge, but have never used XNA. What about a challenge where we can use any compiler and language we want? I think that would draw a larger crowd.

[QUOTE=poser] Some images using particles for a steam effect - really slows down the grapics card though - trying to work out why...
Steam 1
Steam 2
Steam 3
Found out why so slow - too many particles - 600 can just do with 100 and thicken them up / change cycle / speed. Quite quick now.[/QUOTE]

Are you using XNA poser? If you are, I am not sure if you can, but I would look into trying point sprites for fog particles. On my old 6800gts, I could get up to 500,000 point sprite particles in OpenGL, without it slowing down my application. But XNA is Microsoft, so I am betting they want you to use DirectX? And I don't know if that supports point sprites.

Submitted by poser on Wed, 13/06/07 - 2:33 PM Permalink

Hi Swiftless, yes I'm using point sprites or XNA's implementation through HLSL to create particle systems - depends on how far the particles are away and how big the images for them but I can do 10,000's but only if far away which was my misunderstanding. Also, I've discovered post process bloom lighting - please take a look at the newest shot the models look a lot better lit.

Post Process Bloom Shot

Droid on the run - particle weaponposer2007-06-13 07:22:54

Submitted by redwyre on Fri, 29/06/07 - 6:57 PM Permalink

So what are we going to make the challenge? I've been thinking of doing this as two tasks, one not-so-hard task and one hard task. Beginners can start with the not-so-hard task, and tackle the harder one when they finish, and more advanced programmers can go straight to the hard one. eg. Start with the puzzle game starter kit and for the not-so-hard task change the game mechanic to something more like bejeweled, and the hard task is to change it to tetris or something.

Submitted by Maitrek on Sat, 30/06/07 - 2:51 AM Permalink

Run with that I'd say, if too long is spent umm-ing and ahh-ing nothing will happen! Just try to make sure that potential participants are aware of the programming challenge, that's the biggest hurdle :(

Submitted by Maitrek on Sat, 30/06/07 - 2:52 AM Permalink

Perhaps if some of the students here could send out a group email to some of their class-mates about it then that might get some numbers up !

Submitted by souri on Tue, 03/07/07 - 5:13 AM Permalink

I agree, enough of this umming and ahhing crap.

Let's get this show on the road. I'll be chatting to Redwyre on the specifics, but what say we have this challenge starting on August, and ending 4th of November (same day as the ending of the modeller challenge)..

Hopefully I'll find a sponsor for this challenge.

Submitted by richard on Thu, 26/07/07 - 5:11 AM Permalink

Well, I've got another PyWeek coming up. There's a number of folk from Melbourne and interstate playing along now.



I've not been to this board recently as I finally landed myself a job programming OpenGL and Python a few months back and have thrown myself into that :)

Submitted by jnmaloney on Fri, 03/08/07 - 4:26 AM Permalink

[QUOTE=chameleon]"Make a text based adventure game ..."[/QUOTE]

This is a good idea. Text adventures are sorely under-represented these days.

There was some mention of using Lua. Ive used Lua briefly and found it has some nice ways of manipulating text, and is simple enough to learn quickly.

Otherwise, I would probably prefer Python. Or maybe C++, since there's Popcap for 2d and Ogre for 3d.

Perhaps we could all work to a common theme rather than a specific language of framework. That would make it accessible to everyone.

Or there could be a joint sumea challenge-pygame week.

Submitted by yosh64 on Sun, 04/01/09 - 3:57 PM Permalink

Sounds pretty cool to me also, but can XNA be used on linux? as that's not very cool for me :\, I'd even prefer python, maybe use the Blender Game Engine?

Anyhows I usually use C/C++ and my own 3d game/graphics lib :).

edit: Hah, seems I'm rather late to reply, just realised this discussion is very old!

Any programmers still here?

Forum

Hey,

I have noticed that no one has been posting here in the programming section. If we still have any game programmers here, care to let us know what tools you like to use? (Developing Environment and API's)

I will start off.

Compiler: Microsoft Visual C++ 6.0
API's: OpenGL w/GLSL, OpenAL, Win32, DirectX, PhysX

Compiler: Visual Basic 6.0
API's: OpenGL, Win32, Direct3D

Submitted by redwyre on Mon, 26/02/07 - 8:53 AM Permalink

[QUOTE=Swiftless]
Compiler: Microsoft Visual C++ 6.0
API's: OpenGL w/GLSL, OpenAL, Win32, DirectX, PhysX
[/QUOTE]

VC6?? Do you realise that's a pre-standard compiler? Yucky! You should get yourself a copy of Visual C++ Express 2005 :)

Currently the rare coding I get done at home is in XNA Game Studio Express (aka Visual C# Express 2005), where I use XNA.

Submitted by Swiftless on Tue, 27/02/07 - 6:37 AM Permalink

I don't care if it is pre-standard. I don't like Visual C++ Express, and VC6 does everything I require.

So we don't have many programmers here? :'(

Submitted by Kane on Wed, 28/02/07 - 4:43 AM Permalink

I still wander these watery depths occasionally.

I started working full time before Christmas, and have been bogged down since then, and haven't had much time to do much in the way of programming for myself.

I did, however, download the Irrlicht engine and I am going through the tutorials. The only computer graphics experience I have is from a unit at University, but the Irrlicht engine seems strangely easy to use so far.

But yeah, I'm still around.

Submitted by Soul on Tue, 20/03/07 - 11:31 AM Permalink

I'm still lurking, but most of the other coders I knew who hung around here have either given up on games programming, or have real lives to keep them occupied.

As for compilers, I use Visual C++ 2005 Express Edition, or GCC, depending on which platform I'm fiddling with. Used to use VC6, but 2005 is much better, and less expensive :)

Currently I'm using OpenGL, OpenAL and SDL but have previously fiddled with DirectX 9 & the Win32 APIs. It's all pretty much the same to me...

Keep on codin'!

Submitted by Kezza on Thu, 22/03/07 - 10:45 AM Permalink

I'm here, very occasionally. Usually when work drives me completely insane.

VC05ee usually, eclipse if I'm using my linux machine. Still got a preference of OpenGl because of more experience using it, but I've been trying out XNA of late.

Submitted by davidcoen on Thu, 03/05/07 - 1:20 PM Permalink

i have delusions of grandure of being a programmer.

home projects mostly tended to be application architecture with a little directX when eventually reached display, though once alpha at work is over, do want to at least start looking at some of my own code again, learnt a lot in the last 4 years of working as a programmer.

spare time side task at the moment (ie, about 6 hours a week) has been mucking around with second life (just got the viewer to compile) and making tools to export data into it from max...

Submitted by axon on Wed, 30/05/07 - 11:04 AM Permalink

Getting into DX10 and anything using the Geometry shader.

Just picked up Ogre3D for the first time and love it.
Used OgreHaptics to demo some ideas about using VR to train med students about anatomy.

Will soon be flat out with deformation and haptics on GPU related gear.

Will also soon explore Vista and DX10... till then am touching NVidia's CUDA and GLSL (for access to the Geometry Shader without DX10 (thru Vista)).

And if that's not a big enough mish-mash of technologies I've just finished my first J2ME project.

Series 40/60 Phone Stuff:
Eclipse 3.2, Nokia Series 40 SDK, S60 SDK, Carbide J.

C/C++:
Image segmentation using Boost uBLAS and STL.

DirectX9 C# & MDX, Ogre3D (OgreHaptics, oFusion), VC8 (& VC7).... etc

Wish there were 2 of me. Am also running www.airbornerc.com.au and being a dad.

Submitted by Maitrek on Sat, 30/06/07 - 2:47 AM Permalink

Not really a programmer any more, I can do some programming but it's not my forte (I consider myself a mathematics student really). Tend to use VC++ Express edition, not overly familiar with any modern API's (I think maybe four or five years ago I played around with Win32 and OpenGL). I occasionally help out mr Soul up there ^^^ when he runs out of maths talent ;) (frequently)

Submitted by Soul on Sat, 30/06/07 - 2:07 PM Permalink

[QUOTE=Maitrek]I occasionally help out mr Soul up there ^^^ when he runs out of maths talent ;) (frequently)[/QUOTE]

I resent the usage of the word "frequently". "Constantly" would be more accurate

Shader Programming

Forum

Hey guys,

I'm looking at trying my hand at some shader programming and was wondering if anyone has some resources they could point me to that are fairly current. I've checked out some articles on gamedev.net but they were written in 2002 (like http://www.gamedev.net/reference/articles/article1496.asp) and I'm not sure how relevant they still are?

I'm currently a pretty confident programmer and I've done a bit of assembler so I'm not totally inexperienced, just looking for some resources people can recommend.

Thanks!

Submitted by richard on Sat, 02/12/06 - 8:15 AM Permalink

I've been messing around with OpenGL shaders (GLSL) for a few months now. It's fun :)

For references I've been using online tutorials and the orange "OpenGL Shading Language" book by Rost.

I do all my coding in Python* which makes the turn-around from editing source to testing really quick. There's also tools that will let you develop shaders in a GUI but I've not used them (I'm more of a text-mode kinda guy ;)

*: there's recipes in the pygame cookbook if you need examples

Submitted by redwyre on Sat, 02/12/06 - 6:14 PM Permalink

Well, this partly depends on if you want to use DirectX (HLSL) or OpenGL (GLSL or Cg). Personally I use HLSL and I created a small engine using XNA (C#) for the main purpose of playing with shaders :) There are a good amount of docs in the DirectX SDK on HLSL shaders and a few tutorials there as well. Unfortunately, it seems they've removed Effect Edit which allowed you to edit a shader and have it recompile on the fly, but it's not that difficult to write an app that does that for you :)

Submitted by Swiftless on Sun, 11/02/07 - 7:07 AM Permalink

I like to use GLSL because it goes with the whole syntax flow of OpenGL, which I find alot easier to code than Direct3D. I have started some GLSL tutorials on my site, but they are only basic ones and have been covered on many other sites. If you need a hand, give me a shout, I have done alot more than is on my website...

Submitted by axon on Wed, 30/05/07 - 10:51 AM Permalink

[QUOTE=redwyre]Personally I use HLSL and I created a small engine using XNA (C#) for the main purpose of playing with shaders :) There are a good amount of docs in the DirectX SDK on HLSL shaders and a few tutorials there as well.[/QUOTE]

ditto.

Grab yourself the DirectX SDK and the NVIDIA SDK (and the ATI SDK while you're at it). There are tons of examples (e.g. NVSDK10 has 20 DirectX samples and 13 OpenGL samples).

Have a look at the available shader development IDE's available from ATI and NVidia:
- Render Monkey from ATI
- FX Composer from NVidia

FX Composer 2 is about to be released (currently Beta 2 is available to registered developers and those fortunate enough to have made it to GDC2007 would already have had a play).

There's also a more visual tool you might find easier going which can export/import to FX Composer: Mental Mill

[EDIT]
Some links to shader related goodies:
http://developer.nvidia.com/page/opengl.html
http://developer.nvidia.com/page/directx.html
http://ati.amd.com/developer/index.html
http://ati.amd.com/developer/rendermonkey/index.html
[/EDIT]axon2007-05-30 00:53:58

Submitted by yosh64 on Sun, 04/01/09 - 3:48 PM Permalink

hey

If ya into GLSL ya might wanna checkout the OpenGL.org SDK, just a word of warning, although the Lighthouse3D tutorials are pretty cool, there are a couple of errors in the Lighting Tutorials that I seen.

I once tried to email them about it, but their inbox was full, to quote part of my email:


[quote]
The first issue came to my attention after I tried your point light shader, and found there was hardly any light on the walls when I was in a large corridor made of only a single box. I found that you seem only to compute the distance from the vertex to the light position, rather than from the fragment to the light position, used for calculating the light attenuation. So this eliminates one of the (what I think to be) great advantages of per fragment lighting, where the amount of vertices doesn't affect the appearance of light.

The other issue that came to my attention afting finding my point lights didn't seem right, is that you seem to make use of the gl_LightSource[i].halfVector built-in uniform varible in your point/spot light shader.

To be clear, I will just quote Chapter 9.2.2 Point Lights (page 237) of the Orange Book Second Edition, "There are two main differences between point lights and directional lights. First, with a point light source, the direction of maximum highlights must be computed at each vertex rather than with the precomputed value from gl_LightSource[i].halfVector.".

Thus, obviously the gl_LightSource[i].halfVector built-in uniform variable only stores the half vector of a directional light source, and not for a positional point/spot light where it would differ for each vertex. The fact that it's a uniform variable should ring a few alarm bells, hehe :).
[/quote]

Something else I found pretty cool is the parallax and relief bump mapping user submitted examples on codesampler.com, they are much more simple than ya would think, hehe. Hmm, ya might find the other samples handy also, but generally I only like to use these to learn and code things from scratch myself ;).

Also, the GLSL orange book is pretty handy, especially for picking up errors as I done with the LightHouse3D tutorials :).

cyas

NVIDIA CUDA: GPU C-like Compiler

Forum

Shaders, shader fragments, pixel-shaders, vertex-shaders have many uses for custom lighting, GPU accelerated animation, cloth sims and a bunch of cool stuff you can't do on any CPU.

So far HLSL has been the language of choice. Could this be about to change with what appears to be the first truly high level shader language? (HLSL being great and all but tightly constrained by how you pack you passes into textures and instruction limits.)

http://developer.nvidia.com/object/cuda.html

Register yee-selfs and get parallel. It's an exciting development which could bring GPU further away from kitsch and closer into the engine's core.

Who's had a play? Got an LAPACK port for the GPU yet?

Greg

Submitted by redwyre on Fri, 24/11/06 - 8:04 AM Permalink

This seems like it's going to be very nvidia specific, so I think I'll hold out. Though it does look interesting, especially with the 8800 which has 128 cores...

Hopefully DX10 geometry shaders will allow more genereric computations in a portable way

Submitted by Kezza on Tue, 05/12/06 - 2:57 PM Permalink

This undoubtedly will be made into an open standard at some later date. It could potentially make PS3 to PC ports a bit easier if the PC hardware for this gets a good install base.

Wellington Game Jam

Forum

I'm thinking of organizing a Wellington (NZ) weekend / 3-day game jam. I helped out with a Toronto (Canada) game jam earlier this year and now I am in Wellingon, NZ on contract until early Dec.

http://www.tojam.ca

Here is what I am thinking:

72 hours. 10-20 programmers. Up to 10 artists and 3 sound guys. I think the realistic numbers will be 8 programmers (half co-workers), 4 artists and a sound floater.

The rules of the game jam will be easy

1) Complete a game in a weekend. You can use any tech/engine/SDK, but please do not write game logic for the game before the jam starts.

I can secure a space big enough for the participants.

While this event is supposed to be fun and partly-educational, I can't let anyone off the street participate. You will need:

1) Your own PC or laptop.
2) Enough hacker skillz to read input, draw sprites on the screen and basic understanding of game architectures.

Otherwise, you will spend the entire weekend learning tech and getting nothing done. How many people would be interested? And no, I can't hold it anywhere else but Wellington.

XNA Game Studio

Forum

Anyone had a go? Here's some stuff that I've done so far:

Earth model using diffuse, normal, night, and reflection maps

Render to texture, then rendered using a per-pixel sine wave to distort it

Submitted by J I Styles on Mon, 25/09/06 - 6:13 AM Permalink

nifty :)

what's the XNA game studio using for gpu shaders?

Submitted by redwyre on Thu, 28/09/06 - 11:10 AM Permalink

I'm not sure I understand your question, but the shaders are all written in HLSL and stored in .fx files (as you have been able to do in DirectX for a while). Both pictures are using Shader Model 2.0.

Submitted by J I Styles on Thu, 28/09/06 - 12:06 PM Permalink

yup, that answered my question perfectly cheers :)

Submitted by Angelsdragon on Fri, 29/09/06 - 8:42 AM Permalink

Havent had a go yet at the XNA Studio, I really want to but Uni work is kind of limiting the amount of stuff I can do atm :(

Whats the development environment like red? Is it anything like Visual Studio?Angelsdragon2006-09-28 22:43:35

Submitted by tachyon on Sat, 30/09/06 - 10:13 AM Permalink

The dev environment is Visual Studio c# express.

Submitted by redwyre on Sat, 28/10/06 - 11:31 PM Permalink

Had an urge to do an interference pattern shader...

PyWeek challenge #3 is coming up

Forum

PyWeek 3 is scheduled it for the first week of September. The exact dates are 00:00UTC Sunday 3rd September to 00:00UTC Sunday 10th September. Visit the [url="http://www.pyweek.org/"]PyWeek website[/url] to sign up or [url="http://media.pyweek.org/static/rules.html"]read the rules[/url]. The PyWeek challenge:

Embedable scripting languages

Forum

I am currently looking for a scripting language that I will embed into my next engine. I have tried lua, and while it's very easy to setup I'm not really a fan of the language. My current focus is on GameMonkey, which I've heard good things about it. Anyone tried any other languages like Python, Ruby, or any others?

Submitted by Daemin on Mon, 31/07/06 - 4:03 AM Permalink

I've been recently turned into a huge fan of Ruby. Although I don't think it's quite as easily embeddable as some other languages.

Initially I was thinking of developing a game engine in C++ and then using Ruby to script some of the game, however now I'm thinking of making the game in Ruby and only coding the high performance modules in C++. Mainly because all of the mundane file handling stuff - config files, data files, etc - can be more easily coded in Ruby, with far less code that's far more structurally sound.

I also remember seeing Python used in a game, this was in an AGDC talk in 2002 or 2003 (I can't remember), check the AGDC archive for the talk slides and links. Personally I'm not a fan of Python, something about having whitespace be a part of the language formatting.

Submitted by richard on Wed, 02/08/06 - 9:47 PM Permalink

Python's extremely simple to embed in a game. There's also games like EVE Online which are written *in* Python. The common approach is to write the game in Python first, then code any stuff that needs to be sped up in C/C++. With liberal use of third-party libraries (OpenGL, ODE, cgkit, etc) there's actually very little call for C/C++ coding in the end.

Submitted by rezn0r on Wed, 02/08/06 - 10:26 PM Permalink

I quite like Python. I find its XML stuff very handy and easy to use especially. As well as using python to bang out some quick number simulations, I've written a suite of development tools in python to handle one thing or another at work.

Yeah, the whitespace as part of the language formatting can be a drag from time to time... I've always said that if you wanted to make me cry, you'd open my python files and left justify them. :P

Scott.

Submitted by richard on Thu, 03/08/06 - 12:02 AM Permalink

LOL or try to post a snippet to most web forums :)

To counter all this whitespace-hating, I have to say I absolutely love it. Programmers indent anyway (or at least the ones that I employ ;). Why force people to type extra unnecessary stuff at the start and end of blocks?

Submitted by redwyre on Thu, 03/08/06 - 3:04 AM Permalink

Python seems like it would be rather easy to bind to code (since it is more OO out of the box than other languages such as lua, which is just tables of data). I have no problem with the whitespace, I think it's good :)

[code]and you should use
the [ code ][ /code ] tags
for code of any kind :)
[/code]

Submitted by Grover on Fri, 04/08/06 - 10:03 AM Permalink

The main problem with the whitespace in Python, is that it is scope declaration. Now if it were something less trivial, it wouldnt be suh an issue. But it means that valid incorrect code and be easily typed and there is no syntax method to determine if scopes have been incorrectly breeched.

On a small project, its a fairly trivial issue, and rarely pops up. On a large project with hundreds of python files, you go try finding a simple scope problem - errors may rarely appear but the code will be very wrong. Heres a simplistic example:

[code]
if something_happens then
Do_first_good_thing
Do_second_good thing
Do_third_good_thing
[/code]

It might seem trivial, but when these are functions, or simple math then quick visual inspection is often easily missed. I had three instances of this exact problem with a very basic little game myself and a friend made, during the week long pygame comp. And I have seen similar issues in realworld projects with python. Imho, its probably the second most critical flaw of the language. And for me, too easy to create very serious problems, and very hard to debug problems.

What I find most bizarre, is that a simple begin/end scope declaration method (either delcarations or brackets or something!) would be trivial to implement, and remove soooo many issues. I find it odd people just leave it be, and say "oh thats python..", quite odd, with such a nasty syntax flaw.

Submitted by richard on Fri, 04/08/06 - 7:29 PM Permalink

I dunno - that code looks obviously wrong to me. "Do_third_good_thing" is clearly not in the block.

Compare this to the common error in C:
[code]/* Warning: bogus C code! */
if (some condition)
if (another condition)
do_something(fancy);
else
this_sucks(badluck);[/code]

Submitted by Grover on Fri, 04/08/06 - 10:49 PM Permalink

Erm huh? Not talking about C? This is a script language why show a C example?
Its not about whether it is clearly in the block or not - because that third code section can be _anything_.
For example:
[code]
// a is a func param for instance
b = 0
c = 0
if a = 1 then
a = a + 1
b = a + 2
c = a + 3
if c = freddy then
FreddyStuff()
[/code]

See the problem? The code looks valid regardless. It will compile, and run, and just give erroneous results. And thats a very simplistic example. You put in three or four levels of indenting over say 10-20 lines and its a horrible mess in python to discern whether the code that someone wrote is intend to work that way or there is a scope issue. For script, thats insane - because thats often done by designers, whom write script by the bucket load, having a tab cause those sorts of problems is disastserous on a large project (like a game).

And like I said - its something that most languages (especially scripting ones) cater for with simple scoping rules. Whitespace for a scope rule is plain mad. Your example of C too is rarely used by any coders I know, since most places I work at require the use of the brackets as part of their code style guides. This is where script and code most often differ, since programming teams often have very strict standards that are maintained for a clean codebase. Whereas with python, even if the designers stick to pythons scoping rules, the examples Ive shown cant be determined to be correct or incorrect without asking the author. Thats plain dumb.

Submitted by richard on Fri, 04/08/06 - 11:43 PM Permalink

Sorry, but I just noticed you said "whitespace in Python ... is scope declaration". My response was addressing a different issue (that of ambiguity of blocks using optional delimiters, and style guides are a poor patch on a bad design) and I confused the discussion because of that. Again, sorry about that :)

In a nutshell: Whitespace != scope in Python

Scopes in Python are created by modules, functions and class definitions.

I'm not sure what the language is in your second example. If there's a new scope defined in the "if" statement, then sure there'd be an issue. That's simply not the case in Python though...

FWIW, between work and home projects (most of which are open-source with many varied contributors) I've got about 500,000 lines of perfectly maintainable Python code. Seems a bit silly to call these systems "scripts" really. A "script" in my book is a very short, maybe one or two screen program that is usually a throw-away hack to just get a quick job done. You can't write "scripts" in C, but you can write "code" in Python :)

Submitted by Grover on Sun, 06/08/06 - 1:35 PM Permalink

Welp, if you have 500,000 lines of python you prolly should have a look at them, and also read what scope is - file scope and local scope are probably what you should read about. Local scope is not just for classes.

[code]
# ----------------------------------------------
def AddSwappedLines(self, lines):
for l in lines:
newline = Line(l[2], l[3], l[0], l[1])
self.linecount += 1
self.vectors.append(newline)
[/code]

There are three scopes of process here, but only two real scope types - one is file scope, the other is local scope. A local scope exists within the function, and another within the for loop (or nested local scopes) - 'if' statements and such also provide local scoping - ie you can have variables and execution local to the scope of the statement.

Remove a single tab from the last line and you change the scope that line is being used in - I fail to see why this is hard to comprehend? It is suddenly outside the 'for' scope, but it is _valid_ script. Now I dont know whether you are using some new magic Python - but this is _bad_ in anyones book. And if you are using python for large projects you are in for alot of heartache.

If you are happy with whitespace controlling scope - thats cool. But please dont try to brush it off as a minor problem. This is a pretty serious issue with Python. Even with the minor amount of work and home scripting I have done with Python, I have run into this issue various times. Im utterly surprised with 500,000 lines you have never seen this issue? Maybe you havent found all the missing tabs.. I guess.

Btw I used example code before, simply for clarity. With obviously alot of Python scripting under your belt, Im surprised a bit of pseudo code wasnt easily understood. Btw the scope of execution for an 'if' or 'for' statement is _ALWAYS_ determined by whitespace. Im really puzzled why you think this is not true? Id love to hear how you are supposed to get around this problem.. Id probably recommend it, if I could make it magically disappear.

Submitted by richard on Sun, 06/08/06 - 9:57 PM Permalink

quote:There are three scopes of process here
You're referring to what is generally understood as "blocks" of code as "scopes of process" or "scopes of execution". A "scope" in a programming language is generally understood to be a namespace for variables. As you indicated, Python has a file scope, and a local scope. There's also a third builtin scope.

Python uses whitespace to define blocks where other languages may use delimiters to define blocks. It does not use whitespace to delimit scopes, except of course where a block has local scope.

Now I think I understand your position I'll stop participating in the discussion, as it's off-topic and there's no point :) You're clearly wired to need block delimiters. I, and other Python programmers, find that whitespace is enough of a block delimiter (and will react the same way to your postulation as I did - your examples of "common mistakes" are obvious mistakes to us).

quote:I used example code before, simply for clarity. With obviously alot of Python scripting under your belt, Im surprised a bit of pseudo code wasnt easily understood.
I said I didn't recognise it, not that I didn't understand it. Combined with the confusion of scope vs. block I can see why we're getting confused though :)

Submitted by Grover on Thu, 17/08/06 - 11:29 PM Permalink

You might want to look up the definition of programming scopes - seems you have a poor understanding of local scopes.
A code block is an execution scope - whether you think it is or not. Heres a nice scope article to help you out with your learning impediments:
http://en.wikipedia.org/wiki/Scope_(programming)
http://en.wikipedia.org/wiki/Local_variable

A code block IS local scope. Python uses whitespace to close and _end_ code blocks - ooh.. close and end, local SCOPE.
Oh.. that must mean that whitespace controls scoping? But if I may quote "Whitespace != scope in Python". Bzzt. Very wrong. And misleading people reading these posts.

And what is plainly bizarre, is that you consider something that visually 'looks fine syntactically' in Python, but can actually be a serious bug - missing a whitespace, can easily contribute to scoping problems that simply cant be easily vetted. Adding a simple begin/end to the code blocks would be a simple way to solve the issue, as many programming languages do, but by using whitespace, Python inherently has a syntactical flaw - regardless of whether you _think_ it has a problem, this isnt opinion related, it is a flaw.

You cant debug the problem, a compiler cannot pick the syntax error, and a script writer cant necessarily determine a fault with the script unless he/she is the author and _knows_ how the code block should operate. Hence a very critical problem with the language syntax itself.

Submitted by richard on Fri, 18/08/06 - 1:47 AM Permalink

Sorry, I know I said I wouldn't continue this discussion but I really must object. I don't believe I've stated anything misleading in my posts and I'd like for you to withdraw that accusation.

On the other hand this statement is clearly incorrect to anyone who knows Python:

quote:'if' statements and such also provide local scoping - ie you can have variables and execution local to the scope of the statement.

Python's "if" (and "else", "for", "while", "try", "except", "finally") statements do not create a new local variable scope. As I've already stated, new local scopes are only created by "def" and "class" statements.

Submitted by voxel on Sun, 08/10/06 - 2:25 PM Permalink

I pretty anti-Python for a while until I tried to create a game framework in Python for a local game jam. It's really, really easy to learn and pretty powerful. Certain language quirks like barfing on cyclical imports causes programmers to think about package + class design more carefully.

Performance is huge issue for Python - so I would only use it as a glue / game-logic language. The function-calling overhead is quite high which causes you to create funky designs trying to reduce the performance hit.

The whole "not having to declare your variables before usage" is dangerous too, but at least there is no C++ like build times (it's interpretated and very dynamic).

Coming Soon: Mini Programmer Chanllenge #1!

Forum

Check it out [url="http://www.sumea.com.au/forum/topic.asp?TOPIC_ID=3991"]here[/url]. I have a challenge in mind, I might try and knock up a reference implementation to see how easy it is. More details soon!

Submitted by Talvash on Tue, 01/08/06 - 4:27 AM Permalink

Today is the 31st ( unless your in the States ) just wondering whats going on with the challange?

Submitted by Mario (not verified) on Tue, 01/08/06 - 6:57 AM Permalink

Yeah, anyone have any news about whether this is still going ahead, and any more details?

Submitted by Carlin on Tue, 01/08/06 - 8:35 AM Permalink

I was also looking forward to this, anyone got any news?

Submitted by redwyre on Wed, 02/08/06 - 1:22 AM Permalink

Well, that's quite encouraging :) Details are updated!

Submitted by Brett on Sun, 06/08/06 - 11:33 PM Permalink

I was going to work on this in 6502 assembler on my apple //c but it would be hard to run :)
I won't have the development environment set up for it by next week anyway so i'll have to wait for the next one :)

Submitted by souri on Tue, 15/08/06 - 1:52 AM Permalink

So, uh.. only two people had a go? o_O

Submitted by Soul on Thu, 17/08/06 - 6:07 AM Permalink

Pity about the number of entries... would've been good to see a few more different algorithms and implementations.

At least my other half is happy - she's Sudoku mad, so now she has something to solve the ones that get her stumped (which is a scarily rare occurance).

Submitted by redwyre on Sat, 19/08/06 - 12:06 AM Permalink

Next time will be better, I promise! I've been too busy to keep any eye on this one. I know a few people that started but didn't finish (including myself), maybe it wasn't a simple chanllenge after all? Any comments on the challenge would be greatly appreciated (either here or PM me through the forum).

Renderman skin shader Released.

Forum

The Mhteam is proud to announce the release of the first version of the human skin shader for MakeHuman. The shader uses only standard Renderman instructions, therefore it will be compatible not only with ?Pixie?, which has been used for the test phase, but also with other compilers. The code has been carefully optimized as much as possible, and has been tested extensively with various significant conditions of illumination.

The shader has many parameters, to control every aspect of human skin, ranging from the basic (color, rough, spec, alpha) to the specific (hi-res details, hi-res alpha, veins, pores, sweat, ambient light, melanin, and the Pixie specific PixieAO), providing a highly customizable result.

The main features are:

* The light is reflected in an anisotropic way: it is greater in proximity of the areas tangent to the observer's eye, and gives rise to an increase in brightness.
* The skin loses saturation as the brightness is approaching the point of maximum reflection.
* The illumination is spreading away from the tangent line to the rays of light. It's an old idea already experimented originally in a python script for Blender and later, a year ago, in a first experiment of Renderman shader
* The light changes colour with the varying of the observer's angle of observation.

Certainly the shader can be improved and optimized, and a porting for Aqsis is already planned , but for the next release of MakeHuman we decided to stop at this level for now. The results are sufficient for the purpose of our software.

A complete description of the shader can be found [url="http://makewiki.aleppax.it/pmwiki/pmwiki.php/User/MHskinShader"]HERE[/url] pdf version [url="http://www.dedalo-3d.com/public/dev/articles/06_07_14_MHskin_shader_for…"]HERE[/url]

The download page at Sourceforge is [url="http://sourceforge.net/project/showfiles.php?group_id=150931&package_id…"]HERE[/url].

my sourceforge project

Forum

Quite some time ago I posted a memory allocator on sumea. It became the core of a much larger library I've been working on. Sumeans may well find it usefull, and you can use it in commercial projects without having to pay me anything [;)]

It's only in subversion as yet, and the build instructions are outdated (but just use the msvc project file). I'm working on it...

http://sourceforge.net/projects/ldk
the code can be viewed at http://svn.sourceforge.net/viewcvs.cgi/ldk/trunk/
and checked out anonymously with the command
svn co https://svn.sourceforge.net/svnroot/ldk/trunk ldk

Here's a description and (incomplete) feature list

A 64-bit clean (hopefully!), portable, object oriented library of tightly integrated low-level classes, templates and functions targetting realtime multithreaded applications such as midi sequencers and audio synthesisers. Likely to be useful for next-gen game and simulation engines. It has been designed to be the base of a real-time audio synthesis scripting language.

Features include

  • Thread local storage.
  • Global and thread-local generic Singleton classes.
  • A very fast, flexible, low latency (soft-RTOS) and quite reasonably resource conservative thread local memory pool based generic allocatotion system which takes advantage of the compilers' innate knowledge of the size of types to shift some of the allocation load to compile time.
  • Custom STL memory allocator templates that take partial (run-time only) advantage of the allocation system.
  • Debug build memory leak tracking that reports filename and line number of each leaked allocation.
  • Several reference counted smart pointers (intrusive and non-intrusive).
  • Multiple accurate, reapeatable and pausable timers with variable tick times.
  • Thread local scheduling and co-operative multitasking.
  • Thread, Mutex and Lock classes.
  • A basic lockless queue template for low latency inter-thread communication.
  • Object oriented filesystem virtualisation able to read from zip files and numerous game formats (via an enhanced wrapping of physfs). Also supports transparent on-read translation of windows text files on unix systems ans vice/vera. Provides per-thread re-directable stdio.
  • A templated Hash table (with a partial specialisation for const char pointers).
  • XML reading, parsing and writing (via a hacked TinyXml).
  • Template based XML object serialisation (via a hacked TinyBind).
  • Exception based error reporting.
  • Liberal use of the assert macro throughout.
  • Uses an advanced, easily extendible build system (scons, build scripts are in python) with short, clearly separated build scripts for each platform.
  • The beginnings of a regression test suite. The included tests indicate the core of the library is highly functional.
  • Extremely friendly license (zlib)
  • Doxygen documentation

Planned future features include UTF-8 (unicode) and plugin support.

LDK has been known to compile and work with:

  • GNU G++ 3.x on x86-64 GNU-Linux.
  • GNU G++ 4.x on x86 GNU-Linux.
  • GNU G++ 3.x on x86 GNU-Linux.
  • Intel C++ 8.0 on x86 GNU-Linux.
  • MinGW G++ 3.x
  • MSVC.net 2003
  • [*]MSVC.net 2005
    [*]Intel C++ 8.0 on win32.

Submitted by lorien on Mon, 03/07/06 - 3:29 AM Permalink

I've updated the build and install instructions somewhat, and the API documentation (which is a work in progress nearing completion) is uploading right now to http://ldk.sourceforge.net (sourceforge gave me a subdomain last night)

Submitted by kalin on Sat, 05/08/06 - 7:41 PM Permalink

I was browsing through the source, and was curious of a few things...

For your containers, why not use std style syntax (lower_case) so that you can use them with algorithms? Seems an awful lot to miss out on if you are going to write a good hash container to not be able to use it with all standard code or templates expecting models of standard Concepts.

Nice to see the Types.h, I wish the C++ 2003 standard had the numbered typedefs from C99 (int32_t, etc), sucks having to redefine it constantly. (The _t in the standard ones seems rather akward and redundant too)

You mention that it intended for use in realtime multithreaded applications, you might find that boost's shared_ptr is useful, or has useful techniques you might want to look at, it is now thread-safe and lock-free (on most CPUs), so you can get quite some performance gain if you are running some thread-heavy stuff.

Submitted by lorien on Sun, 06/08/06 - 7:55 AM Permalink

Thanks for the comments, you seem to have some knowledge of lockless multithreaded programming, is it from audio/midi programming, RTOS programming, or something you've come across eg through boost? It seems to have become almost unknown since Motorola 68000 series days.

I guess you mean boost::shared_ptr is using compare and swap instructions via inline asm to make it threadsafe and lockless. I'll look into it, thanks. Threadsaftey is only an issue for one of my smart pointers- NewSmartPtr, the others rely on LDK::create<> and LDK::destroy<> instead of new and delete, and so cannot be shared between threads. The allocator uses thread-local storage to avoid locks entirely, it is an attempt to make heap allocation as cheap as stack allocation, however I have yet to look into locality of reference issues.

I'm avoiding things like boost, it in particular has grown too huge with too many interdependencies. No problem with pinching the odd idea though. A possible change to my smart pointers is deferred deletetion: when the reference count hits 0 the object gets placed in a queue to be deleted during idle time.

The philosophy of LDK threading is large partions of program communicating via lockless queues with clear separation between realtime and non realtime parts. It's a pattern I came across in high end audio software, it's possible with lots of tweaking to get around 1 millisecond latency between audio input, processing and output on linux with these and other techniques combined with SCHED_FIFO priority. Those sorts of latencies are useful for all sorts of things otherwise impossible without an RTOS, and it's particularly interesting in combination with embedded linux.

My lockess queue template requires memory barriers for smp architectures I've discovered. The design is threadsafe on uniprocessors without them. I'm planning on a more elaborate queue using compare and swap techniques, and have a whole bunch of research papers on lockless data structures. Another plan is to add ">>" and "<<" operators for a bunch of types to VFile, sort out the UTF8 problems, add cross platform plugin loading, also custom String (std::string is crap) and FastArray classes optimised for my allocator and a few other bits and pieces.

Right now I'm taking a break from things though, this stuff and a ton of unreleased code has become a "for fun" project and I'm feeling burnt out. Also I don't really care about maintaining MSVC compatability- it's been far more trouble than it's worth.

The hashtable names and : Partly I just don't like names with underscores, partly I wanted to keep my formatting consistant across LDK and more containers are planned, partly I don't think it matters much with a hashtable- certainly not for the use I had in mind- the symbol tables and hash tables of a scripting langauge. Feel free to hack it if you don't like it, though my preference would be adding short, standard names that call my methods. I've typedefed Hash::Iterator and Hash::ConstIterator to Hash::iterator and Hash::const_iterator for example.

I'm happy to provide sourceforge developer access for competent and ethical C++ programmers after having received and examined some patches. Please post questions via sourceforge however, as that's LDK's home and I've moved away from game related development and sumea.

Finding adjacent points (verts) in DirectX

Forum

Hi all,

I'm playing with mass-spring stuff and need to know which verts are adjacent to any given vert.

At the moment I've no problem getting the indices of adjacent tris but cannot figure out how to get the point indices from the triangle indices (since I can't assume that the vert buffer is tri-list, tri-soup, or tri-fan).

I've had a look at
[code]pMesh->ConvertAdjacencyToPointReps(&adjacencyBuffer, &pointAdjacency)[/code]but I don't understand what the returned pointAdjacency represents (and how to use it to lookup the coords of any vert's neighbouring verts):

For a cube I get the following:
TriAdjacency[36] = (6,9,1,2,10,0,1,9,3,4,10,2,3,8,5,7,11,
4,0,11,7,5,8,6,7,4,9,2,0,8,1,3,11,5,6,10)
PointAdj[36] = (0,1,2,3,3,2,6,7,7,6,10,11,1,0,11,10,1,10,
6,2,0,3,7,11,0,0,0,0,0,0,0,0,0,0,0,0);

But this doesn't make sense: How can the first point 0 have adjacent points 0,1,2?
Or, taken another way, how can tri 6 have points 0,1,2?

TriAdjacency has 36 elements. This is because there are 2 tris for each of the 6 faces and each tri has 3 neighbours (2 * 6 * 3 = 36).

I'm looking for the meaning of the "point representatives" (quote from the SDK) labelled as PointAdj above.

The first 24 numbers are the useful data. 24 makes sense because there are 8 corners (verts) on a cube and each has 3 adjacent verts (forming 3 edges that converge at that point). 8 points * 3 neighbours for each point = 24 indices.

But if you try to interpret the sequence in the same way as the triAdj sequence by taking it in sets of 3, there are many sets which appear invalid. No number should be repeated in any set of 3.. but there is 3,3,2 and 6,7,7. Note also that the following numbers do not appear at all: 4,5,8,9,12,13,14,15,16,17,18,19,20,21,22,23. (the cube is made up of 24 points).

Can anyone shed some light on how to interpret the pointAdj sequence in order to get my adjacent points?

Thanks in adv. Greg

Sumea Fist Challenge

Forum

I'm just putting out a feeler to see if any programmers would be interested in doing something with the challenge results (with those that agree with handing their models in). A sort of Exploding Fist tribute using the same game mechanics, with the challenge models, and utilising some rendering engine like Ogre (or whatever to easen the burden for programmers).

Would anyone be up for it?

Submitted by Kezza on Thu, 22/06/06 - 9:11 PM Permalink

Sounds interesting...
Maybe if we made it a 2 day challenge with artist/programmer teams, as we'd need more than just the modeller challenge results for assets.
A big problem is we'd need animations and stuff for those models (as coders in stereotype are either slow or not very good at animating).

LiveCoda (call for participation).

Forum

LiveCoda: Wednesday the 24th of May @ Loop Bar, 23 Meyers Place Melbourne.

Presenting real-time programming madness as teams from across Melbourne battle for $600 worth of prizes, with live visual feedback on Loop's 23 foot screen. Also featuring live music, with Simulus improvising over a diverse range of electro-acoustic software, and the VS Chorus Crew bringing freestyles, accapella beatbox breakdowns and instrumental grooves. Live coding from 5pm. Music from 8pm.

Information and registration at www.esci.org.

Submitted by lorien on Wed, 17/05/06 - 12:48 AM Permalink

When I first saw this I thought it meant real-time interactive music system programming and I was wondering where on earth people were hoping to find teams of musician/programmers... Not the case- pity though, I've seen it in a couple of concerts, using Forth based languages. One was in a geodesic dome with 16 channel surround sound system http://www.avatar.com.au/worrall/domes/dome1.html

I think this is different kind of real-time though: what I saw was people adding code to systems while they were running and algorithmically generating music- the performers "piloted" the real-time music generation by adding code on the fly.

Musicians have found that performance with qwerty keyboard and mouse really doesn't hold people's attention, which is part of the reasoning behind things like the hyperinstruments project http://www.media.mit.edu/hyperins

Submitted by ticti on Thu, 18/05/06 - 12:20 AM Permalink

Real-time interactive music system programming is exactly where I'm coming from and I agree that it would be difficult to find enough people to do music programming live. It is for that reason I'm working with programming standard languages. But the evening definitely has a computer music focus - if you have not heard simulus and are in melbourne then you should definitely come and see them.

I think that keyboard and mouse performance can hold peoples attention if they understand what is going on and if you can "move" (perform) fast enough: mouse and keyboard is pretty awkward/slow to work with. I suppose LiveCoda, using collaborative coding algorithms, is looking at how fast multiple people can code a solution.

Best regards,

Rob

Submitted by lorien on Thu, 18/05/06 - 3:36 AM Permalink

Aha: Ross Benecia and Tim Kreiger. Ross studied music tech at La Trobe just before I did, and afaik we had the same supervisor (Jim Sosnin). Tim was one of my teachers long ago when I was at the ANU, that dome I linked to above was mostly made by a teacher we have in common (David Worrall).

Tim and I don't get on too well, but this has got me interested enough to come along anyway.

Submitted by ticti on Thu, 18/05/06 - 3:58 AM Permalink

Awsome! Oh and we are still looking for programming teams if people reading this thread are interested.