- Viewing Profile: Reputation: Endurion
Community Stats
- Group Members
- Active Posts 3,348
- Profile Views 9,992
- Member Title Member
- Age Age Unknown
- Birthday Birthday Unknown
-
Gender
Not Telling
#4912210 sprintf and sprintf_s
Posted by Endurion
on 12 February 2012 - 01:04 AM
You can directly send binary data as well.
Besides sending that thing over the net, the even worse performance problem will be formatting the floats to a string and back on the server. And now that string streams are introduced it's even got worse.
Since your floats are in a continuous buffer anyway, just send bufferData.
#4903141 Win32 CHange Window Position and Resizing Window?
Posted by Endurion
on 16 January 2012 - 12:03 AM
#4882457 Windows Dialog Box Problem
Posted by Endurion
on 10 November 2011 - 01:16 AM
#4882010 Windows Dialog Box Problem
Posted by Endurion
on 09 November 2011 - 12:37 AM
If you return true, Windows thinks the message is fully handled and doesn't do any default behaviour.
#4878212 In german, what do wären, hätten and würden mean?
Posted by Endurion
on 29 October 2011 - 05:38 AM
hätten = (they) would have had
würden = (they) would (do)
All "would"s as if they could if they wanted.
Samples:
Sie wären gerne einkaufen gegangen = They would have liked to go shopping. (possible in the past)
Sie hätten gerne eingekauft = They would have liked to shop (possible in the past)
Sie würden gerne einkaufen = They would like to shop (possible in the future)
My translations to English are maybe not exact.
#4868496 D3DXCreateTextureFromFile == D3D_OK but crashing.
Posted by Endurion
on 02 October 2011 - 11:49 PM
IDirect3DDevice9* device = *(IDirect3DDevice9**)0xC97C28; // DirectX Device
will of course crash once you access the device; unless you're very very lucky to get the same pointer.
I assume you create the device in your main app and want to access it in your DLL? If so, you need to pass the app's device into the DLL, not rely on some random pointer value you once received.
#4867888 Something you never knew about Steve Jobs
Posted by Endurion
on 01 October 2011 - 12:29 AM
#4853086 How to compile my game project?
Posted by Endurion
on 23 August 2011 - 11:24 PM
Depending on your dependencies you can get away with providing the binary and data files in a simple archive. You do have to make sure that you put the required dependencies in there too (in your case, the Tao framework resides in a assembly .dll).
If you're using Visual Studio there should be a option "Publish Project". This will create an installer project and usually automatically includes the dependencies as well.
#4852658 SEGFAULT Occuring Outside GDB, but not inside.
Posted by Endurion
on 23 August 2011 - 12:02 AM
#4848863 Is DirectSound deprecated?
Posted by Endurion
on 13 August 2011 - 11:23 PM
#4835412 The GDNet Birthday thread
Posted by Endurion
on 14 July 2011 - 02:02 PM
After all that time Flash still puts quite a big spike in the cpu meter ;)
And free rope for everyone!
#4831661 Newbie Bitmap Woes
Posted by Endurion
on 06 July 2011 - 12:51 AM
For CreateCompatibleDC it's DeleteDC. For GetDC it's ReleaseDC.
Also, you do not have to create a new DC for every bitmap you want to blit. Think of a HDC as a device context (holds a bitmap, a brush, a pen, etc.). You can select a new bitmap in. Just make sure to finally select the first bitmap back in:
HDC backHDC = CreateCompatibleDC(hdc); HBITMAP backbuff = CreateCompatibleBitmap(hdc, nclientWidth, nclientHeight); HBITMAP hbmpOld = (HBITMAP)SelectObject(backHDC, backbuff); // Draw the background HDC hDisplayDC = CreateCompatibleDC(hdc); HBITMAP hbmpItemOld = (HBITMAP)SelectObject( hDisplayDC , hbmpWorld ); if(!BitBlt(backHDC, 0, 0, nclientWidth, nclientHeight, hDisplayDC , 0, 0, SRCCOPY)) lastError = GetLastError(); // Draw the ball mask SelectObject( hDisplayDC , redBall.GetCharacterMask() ); if(!BitBlt(backHDC, (int)redBall.Position.X, (int)redBall.Position.Y, redBall.GetCharacterInfo().bmWidth, redBall.GetCharacterInfo().bmHeight, hDisplayDC, 0, 0, SRCAND)) lastError = GetLastError(); // Draw the ball SelectObject( hDisplayDC , redBall.GetCharacter() ); if(!BitBlt(backHDC, (int)redBall.Position.X, (int)redBall.Position.Y, redBall.GetCharacterInfo().bmWidth, redBall.GetCharacterInfo().bmHeight, hDisplayDC , 0, 0, SRCPAINT)) lastError = GetLastError(); SelectObject( hDisplayDC , hbmpItemOld ); DeleteDC( hDisplayDC );
I've never used masks with GDI. You could try using TransparentBlt, which lets you use a color key.
#4823944 Getting the key name for a VK constant
Posted by Endurion
on 15 June 2011 - 11:26 PM
However I find your statement that virtual keys shift around with keyboard layouts weird. That's the whole point of the virtual keys, they are defined constants and do NOT move around. The layout adjustment is done on a lower level, so a fixed string array should work fine.
#4823097 jokes
Posted by Endurion
on 14 June 2011 - 01:58 AM
#4822622 Mini-Contest: ASCII Fishtank
Posted by Endurion
on 12 June 2011 - 11:08 PM
- Home
- » Viewing Profile: Reputation: Endurion

Find content