Making it happen
Archive for September, 2005
State changing
Sep 27th
There’s a tremendous improvement in the OpenGL pipeline if you minimize the state changes i.e. calls to glMaterialfv, glColor3f and so on. Could it be due to latencies on the AGP bus ? Although it’s hard to imagine that the driver doesn’t use a buffer for sending data to the video card. Maybe such commands trigger precomputing some internal structures ? Again, hard to believe that.
OpenGL weird stuff
Sep 27th
I had a crash today when using VBOs, immediately after a glBufferDataARB. The crash was in ati2dvag.sys (the ATI display driver) and afterwards either VPU Recover saved my working session or it hanged for good. I traced the problem to the fact that I submitted 0-length buffers for texture coords, even if I had TEXTURE_2D enabled. Strangely indeed, because the driver should have stored the buffer length and forbid access beyond it.
VARIANTs
Sep 26th
Here’s a bug I’ve seen today. We had the following code:
HRESULT get_Value( VARIANT* pValue)
{
*pValue = m_vValue; // m_vValue is _variant_t
}
Now, we hoped m_vValue will get copied to *pValue, however it doesn’t. Actually it gets copied, but member-copy only, so if you have the variant as VT_BSTR the string won’t have its contents copied but only a pointer to it. Now, the correct code is:
VariantCopy( pValue, &m_vValue);
Turn Around!
Sep 24th
In my opinion it’s the still best guide for running your IT company, even if it’s written in 2001. You can download the book in PDF from here.
….
Every company is different. Every company needs its own strategic and operating plan,
that the management team has developed together, but deviating from the precepts in this
document has often proven costly to companies that I have observed.
About .Text
Sep 20th
I managed to fix the blog’s rendering in Firefox, if anyone needs the patched style.css for this .Text skin feel free to get it from your browser’s cache or by saving this page. Didn’t improve my knowledge of CSS, I’ve just replaced a height with a padding. More on Firefox quirks while displaying this blog here.
My next hack into this blog software is to implement a mini-rss reader so displaying “NEW” if there’s anything unread in the linked blogs (bottom-left) (well not quite RSS reader but I really want it to announce me when someone has posted).
AJAX
Sep 20th
While not quite revolutionary stuff, because it’s based on Javascript and XML that have been around for ages, it’s still not popularized as it should be. My opinion is that it should be tied to (pluged-in?) Visual Studio .Net for example, that including some changes in the HTML editor (so double-click on a button open the client handler), and a transparent framework for using client-side script to access some (all?) variables on the corresponding server page (synchronized with … another xml-generating page let’s say).
Anyone interested in coding these ?
Question of the day
Sep 20th
Why is Microsoft Windows stuck with 8-chars file names ? Is this legacy code from windows 3.1 (they could have at least performed a mapping to the real DLLs like Microsoft.Visual.Basic.Virtual.Machine.6.0.dll), but the .net framework has mscorlib.dll that’s 8 chars also.
VB to Visual C++
Sep 20th
What are the steps for transparently converting a VB component to a Visual C++ one (no, not to .NET for the moment) ?
– Start an ATL project
– Create the corresponding object classes, remove their default interfaces
– For each object, implement its VB interface (using the Class View’s “Implement Interface…”)
– Implement the functionality
– In the end, replace all the classids and progids with the ones from the VB component
Yahoo API
Sep 19th
What about an API to Yahoo Messenger ? Implemented using an injected DLL and exposing a COM interface – it would be pretty neat I say.
Process communication
Sep 19th
I heard some time ago of some software that performed inter-process communication using database access – so I propose a contest to the weirdest idea of communication between a process and another. My suggestion is to use text files for that
.
