|
|
Archive for 'uncategorized'
You know something became a cultural phenomenon when hardware review sites start putting up images like this…
From AnandTech’s Radeon HD 4850 & 4870 review: I can has vertex data?
Edit: gee, nowadays the reviews have funny performance measures. Like, FPS per square centimeter (of GPU die size)! It does actually make (some) sense, but it’s still funny. Frames per second per square centimeter… mmm… delicious.
Posted on 2008-06-26 7:54 in gpu, random, uncategorized | No Comments »
Hey, it looks like the quest for encoding floats to RGBA textures (part 1, part 2) did not end yet.
Here’s the “best available” code that I have now:
inline float4 EncodeFloatRGBA( float v ) {
return frac( float4(1.0, 255.0, 65025.0, 160581375.0) * v ) + bias;
}
inline float DecodeFloatRGBA( float4 rgba ) {
return dot( rgba, float4(1.0, 1/255.0, 1/65025.0, 1/160581375.0) );
}
Before I thought that bias should be +0.5/255.0 normally, except it had to be around -0.55/255.0 on Radeon cards (older than Radeon HD series). Well, turns out I was wrong, the bias mostly has to be around -0.5/255.0.
Here’s the list (same bias on Windows/D3D9 and OS X/OpenGL, so it seems to be hardware dependent, and not something in API/drivers):
- Radeon 9500 to X850: -0.61/255
- Radeon X1300 to X1900: -0.66/255
- Radeon HD 2xxx/3xxx: -0.49/255
- GeForce FX, 6, 7, 8: -0.48/255
- Intel 915, 945, 965: -0.5/255
Those are the best bias values I could find. Still, every once in a while (rarely) encoding the value to RGBA texture and reading it back would produce something where one channel is half a bit off. Not a problem if you were encoding numbers were originally 0..1 range, but for example if you were encoding something that spans over whole range of the camera, then 0..1 range gets expanded into 0..FarPlane…
And all of a sudden there are huge precision errors, up to the point of being unusable. I just tried doing a quick’n'dirty depth of field and soft particles implementation using depth encoded this way… not good.
Oh well. Has anyone successfully used encoding of high precision number into RGBA channels before?
Posted on 2008-06-20 17:55 in gpu, uncategorized | 4 Comments »
We repainted our living room and did one wall in wallpaper (real actual ones, not for the desktop). This is fun but takes a couple of days to get done, half of that time spent moving stuff outside the room and moving it back afterwards.
One thing I learned is that painting with semi-glossy paint is very different from painting with matte one. Semi-glossy is very sensitive to paint strokes, pressure and a lot of other things, and if you’re not extremely careful you’ll get a wall that looks like with a varying gloss or specular power. Of course, varying specular exponent would be cool in a shader demo of 2001, but it’s not a cool thing to have on your room wall. And it’s not 2001 anymore either!
After that we just went for a week to Crete. Here’s an assortment of small random pictures. Now back to work!
    
Posted on 2006-07-27 16:08 in uncategorized | No Comments »
A post on GrammerJack blog made me post similar impressions about Mac vs Windows etc. So:
I was the evil guy to install Windows on my MacBookPro (via BootCamp) as well. That was like a month ago. The thing is, I think I haven’t booted into windows for like 20 days on this machine. At first I though gee, I’ll use VisualStudio on this machine, will watch demos and have a proper Subversion client! But I use VisualStudio, watch demos and have a proper Subversion client on my work PC, so there are not that many reasons to boot windows on the laptop…
Plus BootCamp has small annoyances that GrammerJack mentions: no two finger scrolling (it’s the best thing in laptops I’ve ever seen), no backspace key, function key not supported, the machine never seems to come to proper sleep (i.e. it’s always hot to touch), trackpad sensitivity and precision much worse than on OSX etc.
And in general, I must admit that I kinda like OSX. “It feels nice” would be my best attempt at explanation, for I can’t think of any serious reasons why I like it. Well, yeah, the UI is nice etc. Mind you, I like Windows as well, but at least on this laptop, OSX “feels much nicer”.
Now if only Apple could throw the bunch of crap called XCode away and make something like VisualStudio+VisualAssist; and if only OpenGL would be so sweet to use as D3D! I’d jump on OSX bandwagon immediately and be a happy man. Alas, XCode is just lighyears behind (*).
(*) Though Apple has some really cool development tools as well (Shark etc.)
Posted on 2006-06-01 21:47 in uncategorized | 2 Comments »
There is something magic in programming shaders. Like, when you edit one of our standard shaders and save, say, nine instructions in it - the feeling is really good. Maybe because, well, it’s a standard shader - so that means everyone’s graphics will actually render faster. Nice!
Maybe it’s because shaders are such a short piece of code, without too complex dependencies… I’m sure anyone who knows graphics hardware will corect me here, but let’s oversimplify and pretend that shaders actually execute in a simple way… So when you make a shader shorter, you pretty much know it’s going to be faster. When you make it “look better”, it almost certainly will look better. Try doing that in your regular big codebase - by optimizing something you may break something else; and in general you have no clue what to optimize unless you do your profiling homework. So, my take is that shaders are much simpler, so the joys of looking at assembly output actually make sense.
So, yeah, I’m back to some shader programming.
Posted on 2006-05-24 20:14 in uncategorized | 5 Comments »
Found this quote from Raymond Chen today ( here):
The answer to “Why doesn’t this feature exist?” is usually “By default features don’t exist. Somebody has to implement them.”
It’s not like every feature you can think of comes out of your brain fully tested and implemented, and then some PM somewhere files a bug to have your feature removed. Features start out nonexistent and somebody has to make them happen.
So brilliant.
Posted on 2006-02-27 18:08 in uncategorized | No Comments »
It just occurred to me: it seems that noone has ever made a shadowing system that does shadows from anything onto anything, with zero artifacts, with no corner cases, always looking good, running fast and on any sensible hardware.
Hm… sounds like a challenge! ;)
Back to reading.
Posted on 2006-02-18 22:45 in uncategorized | 6 Comments »
Lost Garden is good - about game design and related things from (ex) Anark guy (hi Chris!). E.g. this one ( a practical definition of innovation in game design):
And if you ever hear an indie game developer talking about level design, either shoot them in the head now to help them avoid their future misery, or direct them towards this essay.
Posted on 2005-11-08 9:21 in uncategorized | No Comments »
Headphones on, winamp alternatively playing The Jupiter Sound and Four Themes and a Masterplan by Little Bitchard. Just the right kind of music for asp.net coding. At least the music is good :)
Posted on 2005-10-06 11:36 in uncategorized | 4 Comments »
Work has really started on the next version of Project Hoshimi for Microsoft. We’ve got to:
- Add eye candy, whatever that may be. They say we can ditch some old harware (DX6 level), but methinks we can’t go really wild (”minimum ps2.0″ would be cool, but not in this real world). We’ve got to add some particles, transparent blood cells, lighting fx etc. Anyone has some ideas what could be easy to implement and look extremely cool? :)
- I can’t say much, but it’s about network, client-server etc. Time to learn some network programming for me!
- The guys behind whole this thing have some really insane plans that would rock the christ child if they would really happen. Not a high probability of them happening though…
Ok, back to thinking about possible eye candy and the network protocol.
Posted on 2005-09-01 20:54 in uncategorized | 3 Comments »
|