Author Topic: Demo coding, what is your approach?  (Read 9613 times)

0 Members and 1 Guest are viewing this topic.

Offline Pixel_Outlaw

  • Pentium
  • *****
  • Posts: 1382
  • Karma: 83
    • View Profile
Demo coding, what is your approach?
« on: June 02, 2011 »

I just want to get a feel for the different approaches people take to making demos.

Personally I have a rough idea of what I want to do then the project kind of evolves based on what I'm feeling at the time. I imagine there are people who just start tinkering and build something great that way too. Also I imagine there are people who like to carefully plan from start to finish (which never really has worked for me personally).

How do you usually make your demo?
Challenge Trophies Won:

Offline Kirl

  • Senior Member
  • Pentium
  • ********
  • Posts: 1217
  • Karma: 230
    • View Profile
    • Homepage
Re: Demo coding, what is your approach?
« Reply #1 on: June 02, 2011 »
Months of coding can save minutes of planning!  ;D

That's my aproach as well, I start with a general idea and when that's sort of working, I try various more specific fx. In the end I choose what I want to use and smooth out the rough edges.
www.kirl.nl
Challenge Trophies Won:

Offline Jim

  • Founder Member
  • DBF Aficionado
  • ********
  • Posts: 5301
  • Karma: 402
    • View Profile
Re: Demo coding, what is your approach?
« Reply #2 on: June 02, 2011 »
This time round I watched youtube videos of jellyfish, then worked out a simple parameterised jellyfish - they basically have four bits, a head which doesn't bend, a mantle which does, tentacles, mouth parts.
Then I set about a simple model for each: a very flat cone, a cylinder, a spring, some coils around a spring.
Then the animation - the bottom of the mantle where the tentacles attach goes up and down and left to right in a sin wave, where the down and in parts of the cycle are very fast and the up and out ones are slower.  Add a bit of gravity to make the tentacles drag, otherwise the springs look after themselves.
For fun I made the jellyfish flock a bit, they look for neightbours and try to get close to each other, but if they get too close they run away.
Finally, shove a glowing pixel shader over the top to make it schmick.
You can then shove in different radii, segment count, pulse speeds, colours, tentacle lengths etc to get lots of different ones.

I have the A4 piece of paper where I worked all this out before I started - once the dust has settled here I'll scan it in and post it up.

Jim
Challenge Trophies Won:

Offline Pixel_Outlaw

  • Pentium
  • *****
  • Posts: 1382
  • Karma: 83
    • View Profile
Re: Demo coding, what is your approach?
« Reply #3 on: June 02, 2011 »

Great detail Jim!

It was interesting to hear your process.
Challenge Trophies Won:

Offline benny!

  • Senior Member
  • DBF Aficionado
  • ********
  • Posts: 4384
  • Karma: 228
  • in this place forever!
    • View Profile
    • bennyschuetz.com - mycroBlog
Re: Demo coding, what is your approach?
« Reply #4 on: June 02, 2011 »
Interesting topic.

Currently, the stuff I produce demoscene wise are just small FX. Those FX are the result of some experiments. The
source of most of those experiements is a huge source of inspiration I get from the internet. I bookmarked several
RSS feeds for visual effects (not strictly coding related). When for example a new DBF challenge is held - the creative
thinking takes somehow automatically take place in my brain. Then I start playing around with the effects. Having
a parameterized FX like Jim said is really good. You could have lot of variations/transitions/syncing to music etc with
a parameterized FX.

But that only counts for one-scene-fx. I have also some written notes of ideas I have doing some demos having
a message. Concerning the message they are simple quotes which I rip out of their original context and
try to think about a good way to visualize them. Since the result might be a more complex I write down my thougths.
Bad thing is - that I do not have the time currently to realize them.
[ mycroBLOG - POUET :: whatever keeps us longing - for another breath of air - is getting rare ]

Challenge Trophies Won:

Offline combatking0

  • JavaScript lives!
  • Senior Member
  • DBF Aficionado
  • ********
  • Posts: 4569
  • Karma: 235
  • Retroman!
    • View Profile
    • Combat King's Barcode Battler Home
Re: Demo coding, what is your approach?
« Reply #5 on: June 02, 2011 »
My planning process often involves paper - if a project is to have multiple screens, then I draw arrows between rectangles and write stuff near the arrows to represent the conditions which must be met before the screen will change.

If there is behaviour, for example, a bee flying between flowers, then I write down a list of variables to represent the behaviour (direction, position, mode, etc)

Some of it isn't written down if I have a clear idea of it in my head.

I then put together some simple graphics as placeholders, usually rectangles or elipses, and import them into flash and work on getting the behaviour right. When that is how I like it, I then move on to improving the graphics in Fireworks before re-importing them into Flash.

My wireframe entries were different, as there were no imported graphics at all - the only paper work was for the letter shapes in Twisted to get the coordinates right.
You are our 9001st visitor.
Challenge Trophies Won:

Offline Pixel_Outlaw

  • Pentium
  • *****
  • Posts: 1382
  • Karma: 83
    • View Profile
Re: Demo coding, what is your approach?
« Reply #6 on: June 02, 2011 »

I then put together some simple graphics as placeholders, usually rectangles or elipses, and import them into flash and work on getting the behaviour right. When that is how I like it, I then move on to improving the graphics in Fireworks before re-importing them into Flash.


Interesting. I may be an odd duck but I can't work with placeholder graphics. I prefer to build programs visually first making use of finished graphics. This often causes big headaches when I scrap art to go in a different direction. But I was an artist before programmer so I have to work visually. This discussion is great people all try different approaches!
Challenge Trophies Won:

Offline TinDragon

  • Pentium
  • *****
  • Posts: 644
  • Karma: 24
    • View Profile
    • J2K's blog
Re: Demo coding, what is your approach?
« Reply #7 on: June 02, 2011 »
When it comes to demo coding, I have two approachs, one is were I have had an idea and i sometimes jot down a few ideas how it might work tho generally I just jump in and try to code it. The second approach is more or less based on me taking something that I am working on and changing parameters and basicly fiddling about with it to see what interesting effects come out the other end.

When it come to games or application coding i do tend to take a more structured approach, I create a small design document, nothing super fancy or complex, just a rough description of what the project is ment to do, generally a rough screen mockup and then I work out a rough of how to do whatever its ment to in a flow diagram or english depending on how i am feeling. Any particularly complex ideas I work out the logic on paper either to start with or when i encouter them during development.

Sometimes I use a combination of everything above, simple projects I do tend to dive in more than anything else, but anything larger I like to plan it before tackling it else I am likely to never get anywhere  ;)

Offline ferris

  • Pentium
  • *****
  • Posts: 841
  • Karma: 84
    • View Profile
    • Youth Uprising Home
Re: Demo coding, what is your approach?
« Reply #8 on: June 02, 2011 »
What TinDragon said. To the letter :) .
http://iamferris.com/
http://youth-uprising.com/

Where the fun's at.
Challenge Trophies Won:

Offline Raizor

  • Founder Member
  • Pentium
  • ********
  • Posts: 1154
  • Karma: 175
    • View Profile
Re: Demo coding, what is your approach?
« Reply #9 on: June 02, 2011 »
Same as TinDragon and Ferris really. More often than not, I'll play around until I come up with something interesting and then turn that into something else. I do that more than planning in great detail.  On occasion I'll have an idea in mind of what I want to achieve and code toward that.  A lot of the times the ideas still end up changing as I tweak what I'm working on. 

The block scroller for the wireframe competition was fairly solidly planned from the outset. I ended up playing around with colours and sine stuff after it was done. I can't think of a single occasion where things weren't modified while I worked on them. I'm not sure if that's due to bad planning on my part or learning as I go...
raizor

Challenge Trophies Won:

Offline Rbz

  • Founder Member
  • DBF Aficionado
  • ********
  • Posts: 2757
  • Karma: 493
    • View Profile
    • https://www.rbraz.com/
Re: Demo coding, what is your approach?
« Reply #10 on: June 03, 2011 »
For me, I always try to do things I never did before, like in the last compo I was already working/learning how to do shadow maps using pixel shaders and also a physic engine, so it was just a matter of developing something that can be used with this effect.

For some compos the challenge for myself was to code the entry in asm and things like that, but the basic development process is to code an entry around of something I'm already researching/learning.
Challenge Trophies Won:

Offline Jim

  • Founder Member
  • DBF Aficionado
  • ********
  • Posts: 5301
  • Karma: 402
    • View Profile
Re: Demo coding, what is your approach?
« Reply #11 on: June 03, 2011 »
I'm going to build a sim-planet.  That's my aim.  So all my little sims will come together into one big one, you know, in the next 50 or 60 years or so...:)

Jim
Challenge Trophies Won:

Offline Shockwave

  • good/evil
  • Founder Member
  • DBF Aficionado
  • ********
  • Posts: 17414
  • Karma: 498
  • evil/good
    • View Profile
    • My Homepage
Re: Demo coding, what is your approach?
« Reply #12 on: June 03, 2011 »
Sometimes an idea comes to me, but more often than not I fit into a theme for our comps - these days the only things I have time to code are comp entries and work on this site.   This time I had two ideas for the comp!

The first (and best one) was a wireframe pencil drawn out of glowing lines, writing some greetings on the screen and drawing shapes that would pop out and begin rotating.  Thought about the work involved in it and decided that if I software rendered it I would have more control over everything, in my mind I knew that I was going to treat it the same as a transforming object, draw the lines between the transforming points (move each into place one by one)  and just use the pencil to track them, when it was sketched, I'd pop out the Z axis and get rid of the pencil.

So I considered a couple of options for coding it, I'm using Java in work now so I'm picking that up, then there was Blitz Max, or Freebasic - I discounted Java because I don't know it well enough (my work involves no graphics or even text output at all!), Blitz Max after initially impressing me is something I have decided is not for me and there's the fallback option of Freebasic - Messy but able to use pointers and in-line asm and fast enough to do a software blur at 800 X 600.

Put a benchmark together of an overkill blurry on a screenfull of sine dots and posted it up to get some benchmarks to see if what I wanted to do was possible and would run on everyone's pc before deciding on my effect and beginning to code the real thing.

I knew that was the best case scenario.

But I guessed that I wouldn't have enough time to do that so I had to make something that I could do in about 8 hours as I have had a really busy month.  The soft option was a vector scroll, again I thought about it and decided that the fastest (but not necessarily best) approach would be to define set grids and depending on what letter was being drawn, connect the various points.

I literally designed the font as I went along.

Sadly this is the approach I have to take with most stuff - as the guy who sets the comps it would be bad form for me to expect other people to participate in something that I don't!  And anyway I love the challenges.. The idea is usually as much of a surprise to me as it is to everyone else.. Usually I plan a theme and then ditch it at the last minute and pick another!

Anyone see a pattern emerging here?
Shockwave ^ Codigos
Challenge Trophies Won:

Offline padman

  • Senior Member
  • Pentium
  • ********
  • Posts: 990
  • Karma: 260
    • View Profile
Re: Demo coding, what is your approach?
« Reply #13 on: June 03, 2011 »
Here's how I usually do it:  ;)

  • I got no clue.
  • I go take a dump.
  • I come back with a great idea.
  • I start coding without explicitly declaring variables.
  • The mess in the editor looks like what was in the toilet bowl (cf. 2)
  • I copy/paste/mess up the code some more
  • I get completely lost in the spaghetti code
  • I hit compile, but I don't understand the error message of the compiler
  • I try to find out what caused the error in the helpfile and/or the PB forums
  • I go to the fridge to get some bevvy
  • I try to elminate the errors, forget to save and crash the GUI or the computer
  • I start all over again with an 4 hours old backup
  • I tell my gf, it'll only take some more minutes and I'll be right with her at the dinner table
  • After a half hour and an annoyed gf I grab some food
  • I'm getting there, no more errors!
  • Duh, Debugger wasn't on.  ::)
  • I fix some more issues
  • I hit compile. It's working and looking as supposed!!!  :||
  • I watch it over and over again, tapping myself on the shoulder
  • I finetune at least for a couple of more hours
  • I UPX it, zip it, upload it to DBF
Challenge Trophies Won:

Offline Shockwave

  • good/evil
  • Founder Member
  • DBF Aficionado
  • ********
  • Posts: 17414
  • Karma: 498
  • evil/good
    • View Profile
    • My Homepage
Re: Demo coding, what is your approach?
« Reply #14 on: June 03, 2011 »
So Beer made it possible? :)
Shockwave ^ Codigos
Challenge Trophies Won:

Offline padman

  • Senior Member
  • Pentium
  • ********
  • Posts: 990
  • Karma: 260
    • View Profile
Re: Demo coding, what is your approach?
« Reply #15 on: June 03, 2011 »
Haha! Well, partly, mainly because I'm an exceptionally gifted coder.  ;)
Challenge Trophies Won:

Offline hellfire

  • Sponsor
  • Pentium
  • *******
  • Posts: 1294
  • Karma: 466
    • View Profile
    • my stuff
Re: Demo coding, what is your approach?
« Reply #16 on: June 03, 2011 »
I do it like Padman but I use C and Glenmorangie.
The finns use Salmiakki; it works very well, too!
« Last Edit: June 03, 2011 by hellfire »
Challenge Trophies Won:

Offline benny!

  • Senior Member
  • DBF Aficionado
  • ********
  • Posts: 4384
  • Karma: 228
  • in this place forever!
    • View Profile
    • bennyschuetz.com - mycroBlog
Re: Demo coding, what is your approach?
« Reply #17 on: June 04, 2011 »
Rofl ... Good One padman
[ mycroBLOG - POUET :: whatever keeps us longing - for another breath of air - is getting rare ]

Challenge Trophies Won:

Offline Jim

  • Founder Member
  • DBF Aficionado
  • ********
  • Posts: 5301
  • Karma: 402
    • View Profile
Re: Demo coding, what is your approach?
« Reply #18 on: October 11, 2011 »
Found this in a box after our move.  Just a few doodles I made before I started coding.

Jim
Challenge Trophies Won: