Archive for the ‘XNA’ Category

Shader Based 2D Shadowing

Sunday, August 15th, 2010

Those who know me know I used to do quite abit of development in c# using Microsoft’s XNA platform.

Well I like to check back in every now and then with some of the big players in the community to see what’s going on.

One of those players is Catalin Zima, who is famous for producing many great shader and effect samples.

One of Catalin’s reccent project particularly caught my eye however as I had tried to tackle the same problem several years ago when I was in my final year of university. That is, Dynamic 2D Shadows Calculated on the GPU (http://mikecann.co.uk/university-projects/shadowshader-in-rendermonkey/)

Catalin’s approach to the problem is far more elegant that my brute force iterative approach. He uses a clever technique of distorting the desired casting image about the light in such a way as not to require iterative pixel lookups.

If you are interested in the more details in the technique I encourage you to check it out over on Catalin’s blog: http://www.catalinzima.com/2010/07/my-technique-for-the-shader-based-dynamic-2d-shadows/

Tags: , , , , , , ,

XNA Archive

Wednesday, March 11th, 2009

I just realised some of my old XNAGPUParticles project videos have gone walkies. So I have reposted them on youtube. These are my old projects from my final year of uni, binary and source code can be found in the relevant post for each video.

http://www.mikecann.co.uk/?p=163
httpvh://www.youtube.com/watch?v=vxrg1YavBIg

http://www.mikecann.co.uk/?p=169

httpvh://www.youtube.com/watch?v=3wdIiCCAb9U

I have another reason for these old re-posts, something a little more flash orientated.. Stay tuned for more info ;)

PlaceEd 3

Sunday, February 3rd, 2008

Recently I have been working on some small tools for the lads at work to aid them in designing mobile phone games.

One project I have been working on for a while (in my spare time at work and in the evenings at home) is a new version of PlaceEd. PlaceEd is a small app used by people at work who need to design levels with objects and paths in them.

The reason for making this new version was because the original was starting to show its age and after several modifications to customise it to certain projects it has become unreliable. A second version (PlaceEd2) was half coded by one of the other employees at rockpool though they ran out of time and didn’t complete it.

So that’s where I come in, and I wrote from scratch a new app and called it PlaceEd 3 (even though there wasn’t really a fully released version of PlaceEd 2).
(more…)

XNALiquids 03

Wednesday, January 30th, 2008

Well i was just thinking in work today that it may be possible to detect the bounds of the the particle "clusters" and then line drawing the boundry and then you wouldnt notice the compression that the particles tend to suffer from.

When i got home i tested out my theroy and the results can be seen below. Its pretty obvious that its not perfect but as i say it was just me messing.

Oh BTW grant kot has been working on his polluted planet some more, and its starting to look quite impressive now its over in XNA: link1, link2

XNALiquids02

Thursday, January 17th, 2008

Okay well i have been playing around with my particles AGAIN :P

I started this time from some work done by the CUDA team over at NVidia. As im running windows Vista i couldnt get CUDA to work so i read through the source and adapted it to my needs.

As you can see from the video below its better than my last attempt but still not perfect, it also still runs on  the CPU on a single core and has had no optomisations applied to it.

Hopefully tho i can build on this to make it better.

XNALiquids 01

Saturday, January 5th, 2008

Well after seeing what Polluted Planet did with large numbers of interactive particles in java, it got me interested.

So i have decided to have a go at implementing it myself in XNA.

So here it is, my first attempt at it. Currently the algorithm is very rough as you can see from the video there are still some problems that cause the particle to behave a little… umm.. erratic ;)

Hopefully with abit more time and effort ill get it sorted. At the moment there are 5000 interacting particle on one CPU, hopefully i will beable to push that figue up soon and take advantage of my quad-core system :)

XNA 2.0 && Silicon Minds

Tuesday, December 18th, 2007

Well its that time again. XNA 2.0 has been released and with it a new Dream Build Play competition.

As a warm up to the competition Microsoft have launched a smaller contest named Silicon Minds. The central idea behind this contest is to encourage A.I. in games and as such 60% of the marks will be given to the quality of the AI in the game a further 20% given to how fun the game is and a final 20% given to the polish of the game.

I have been wracking my brain trying to think of a good project to do for this contest, some of the ideas i came up with were:

  • Bee Swarm Game
  • Dynamic FPS Difficulty
  • Particle Flocking
  • Learning Geometry Wars
  • Predictive Multiplayer
  • Adaptive Level Design
  • DNA Designer
  • Design a Positronic Brain

In the end i decided that due to how short the competition is (ends jan 27th) and my lack of any A.I. experience I would stick with what I have learnt in the past and develop on that. So using the work i have done on LieroXNA so far im planning on writing an A.I. for a deformable 2d landscape.

Sorry i cant say any more at this stage but stay tuned and ill update in the near future.

Project Technology (Deformable Terrains)

Wednesday, December 5th, 2007

Well i got asked a question in a comment on how the terrains work in the LieroXNA project so I thought i would do a quick post on this rather than reply in the comments.

The way the terrains work has changed a few times over the course of development of the project for various reasons mostly related to the incompatabilities of the 360 and my previous methods. I wont go into those previous methods here but if anyone reading this has any questions dont hesitate to ask in a comment or email me. I would also like to say this may not be the most efficient method as I was only getting the terrains up as a proof of concept first then was planning on refining later.

(more…)

Project Update

Sunday, November 11th, 2007

Well its been a while since i have posted an update regarding the LieroXNA project. I havent been slacking. 

I have been spending the majority of my time getting it to run on the 360. I ran into many problems, the majority of which were due to the different ways render targets work on the 360 and the fact that you cant use 128bit floating point textures (Vector4 textures).

Ill be going into more depth on the problems i faced on the 360 in a different post. But what i can say is that it works almost perfectly on the 360 now and im very happy with it.

For now you can see a new video of the engine with some fancy bloom effects added :)

LieroXNA – Improvements and Additions

Sunday, September 30th, 2007

Been a while since I have posted about LieroXNA but I havent been doing nothing. Changes and things:

+ Added a destroyed layer to the game which is just the initial map but darker.
+ Added a shadow to the foreground to give it a more 3D appearence.
+ Added an indestructable layer, so that maps can have abit of structure even after a long battle.
+ Added the ability to zoom in and out. This was a big one and took most of last weekend to sort out.
+ Added player spawning.
+ Added the ability to control the player with the 360 controller.
+ Started to add other gameplay features such as player jumps, crosshair, weapon switching things and others.

Anyways you can see all these new features in action in the video below. Again, you can download a higher quality one if you wish: [download#1]

<