|
Hello Everybody,
In the quest to produce a multi tracked studio and mix wave sounds and finally be saved to a mixed single wave file to disk, which of the following is the best approach and please direct me to technical articles on this issue as well excluding MSDN as I already gone through with no positive result!
1) DirectX (DirectSound, DirectMusic)
2) Low lever waveXXXX Sound API
3) MMIO API
4) MCI API
Each of the above have their own problem that one would face at the end for mixing the sound buffers. The examples with the DirectX SDK are all just for mixing and have no final wave saving functionality. Any help, Link or A General Hint on this issue ( saving the sound buffers into a single wave file ) will be really appreciated.
Thank you.
|
|
|
|
|
From memory, DirectX *does* have a wave saving facility, although at the point the book I have was written ( the Microsoft Direct X book ), it was just a thin wrapper on the GDI wave saving stuff. DX is definitely the way to go, IMHO.
Christian
The content of this post is not necessarily the opinion of my yadda yadda yadda.
To understand recursion, we must first understand recursion.
|
|
|
|
|
how can I obtain handle to a window if I have handle to his process ?
pls help
Ivaylo guberov
|
|
|
|
|
Its tricky to get the main window of a process. One thing you can try is to call ::GetTopWindow(NULL) and ::GetNextWindow(...) until you have all the top level windows, then find the processes associated with them with GetWindowThreadProcessId(...) .
You may find there is more than one top level window for the process. I've seen programs where arrays of comboboxes show as top level wnds! So, you need to do a few more heuistics to pare it down - maybe discarding certain window class texts, or windows with "" for their WindowText, or ferreting some resonable set of children for each, but I don't think there's a GetMainWindowForProcess function.
|
|
|
|
|
Any one know how can I write the code that can moving an image(bmp) across the screen?
Now I am currently working on my project. I must write the simulation program on VC++ about Train Station System but I don't know how to write the code that can display the train(bmp) moving on the rail (background). So, please suggest me which function I must use or other..
Thank you
|
|
|
|
|
you should be looking at the directx stuff
ie, directdraw, etc
---
"every year we invent better idiot proof systems and every year they invent better idiots"
|
|
|
|
|
"every year we invent better idiot proof systems and every year they invent better idiots"
Does this mean we are improving at inventing idiots ?
or does it really mean that the idiots are inventing the "better idiot proof systems",
I Respect your opinion !
Regardz
Colin Davies
Mode robotoid idiot O' boredom
|
|
|
|
|
The bmp you want to move around is actually called a "sprite" in the world of 2D Animations. A sprite is basically a Bitmap with a Mask that would make the unwanted areas of the bitmap in question to not be drawn or in other wotds turn transparent and then are both blitted to the screen over another Bitmap of the background.
You can produce a mask for your Train bmp and then blit it onto the background image usinf BilBlit(..) function.
Load your image using the LoadImage(..) function, or better yet put your image as a resource in your app and then load it.
Search the google.com on "Windows Sprite Programming" and you get a lot of good replies!
Good Luck!
|
|
|
|
|
Any one has any suggestions on how i may execute a few batch files programmatically?? I would like to use C++.
Thanks in adv.
Sean
|
|
|
|
|
|
for real fun parse the BAT files,
and then use system() thus you'll
be able to trap for any errors in your windows APP,
Regardz
Colin Davies
|
|
|
|
|
Different computers have different screen areas. How can I programmatically attain a list of screen areas for a computer and how can I programmatically change the screen area?
Please, any response any one can give me will be greatly appreciated.
Sincerely,
Danielle (an overworked graduate student)
|
|
|
|
|
Checkout EnumDisplaySettings and ChangeDisplaySettings in the MSDN.
|
|
|
|
|
Tim, go out and have some green beer will you . Have one for me too as I'm marooned at home with a sick wife, two sick kids and a sick me .
(how's that for totally overusing a smiley!)
David
|
|
|
|
|
Hi folks,
simple question :
I have 2 threads running where the second threads (not written by me) writes a lot of output to COUT, thou this thread has no console the data is lost. I can redirect this output by hard to a file.
I like to get the data written to COUT for debuggin in a CEdit field or some kind that ?
I never though about such a problem ?
Any Ideas ? Any Clues ?
Thx
oliver
|
|
|
|
|
I have a cformview w/ a control that I'd like to have respond to the enter key. I understand you can use getdlgcode for dialogs, but would I need it for this situation? How would I go about doing this? I searched around but didn't come up with much in my situation. Any leads would be appreciated.
Thanks in advance.
|
|
|
|
|
I don't know if this is good practise or not, but I found the keys being eaten on the way through some PreTranslateMsg code, so did this:
BOOL CSmc3View::PreTranslateMessage(MSG* pMsg)
{
if(pMsg->message != WM_KEYDOWN)
return CFormView::PreTranslateMessage(pMsg);
else
return WindowProc(pMsg->message, pMsg->lParam, pMsg->wParam);
}
Now, OnKeyDown gets hit in the form view class, and enter doesn't seem to be a problem. But I don't know if this is kosher - it bypasses a lot of MFC code... caveat emptor.
later...
er... and oh yeah... then you can call the OnButton code from OnKeyDown... geez, what a hack! oh well... I try...
|
|
|
|
|
Hi
Can you recommend some sockets library
preferably based on C++ templates like STL or ATL
Thanx
|
|
|
|
|
I purchased Dundas's TCP/IP Ent a couple of months ago. And have had very quick success. Download the demo, you'll find their libraries are easy to use.
Give them a look. Tech support has been awesome(I'm a rookie at this stuff). Very quick response.
Scott!
Put the big rocks in the glass jar first!
|
|
|
|
|
Hi Scott
Thank you for advice.
But I need library with open source code (like ATL/WTL) and cross platform (like STL)
Ernst
|
|
|
|
|
Hi there,
Just thought I should jump in and provide some clairification. Our Dundas TCP/IP package is available in a variety of formats, but is most commonly purchased as C++ source code.
Although we don't directly support the package on non-Windows platforms, we estimate that about 10% of our users end up porting the library to Solaris or Linux (we hear it takes about a day or so of work to replace the Windows threading calls to those of the target platform and the Winsock calls to Berkely Sockets).
I would encourage you to check it out, it will likely fit your needs quite nicely.
http://www.dundas.com/index.asp?products/tcpip
HTH,
David
|
|
|
|
|
Try SocketMan. It is'a free and portable C++ library, so it pretty much fits your demands .
|
|
|
|
|
HI ALL
I want to draw circle on the screen(or desktop), I mean out of client window
so I do like below :
HDC hdc = CreateDC (TEXT ("DISPLAY"), NULL, NULL, NULL) ;
it works but..................
then I do like below :
InvalidateRect (NULL, &rc, TRUE) ;
it erase the circle but....
When I use timer to draw circle and erase it quickly
SetTimer (hwnd, ID_TIMER, 200, NULL) ;
now the problem is apear
when I erase the screen very quickly and
repeatedly it makes the screen very shake ...
How I can avoid this shake...
THANK YOU
AHMAD AL-WASHALI
YEMEN
washali@yahoo.com
AHMAD ALWASHALI
|
|
|
|
|
the 'shaking' is the natural flickering caused by erasing the bg and redrawing ... in games and other graphics programming a technique called 'double-buffering' is used
essentially you grab 2 lumps of memory big enough for a copy of the screen each and draw to these ... when you are ready to show a newly updated image you blit that to the screen and avoid the erase step
now if you are doing this for the whole desktop i think you may have a problem as the rest of the image will be changing beyond your control so it will be almost impossible to know what has moved where
hmmmmm.....
maybe you could use a borderless window that is transparent and set to the lowest z order and draw to that ... it would give the same effect but you wouldn't have to worry about other images in your client area and then could use the double buffering technique above
---
"every year we invent better idiot proof systems and every year they invent better idiots"
|
|
|
|
|
Thank you lauren .
but can I erase the area which I draw in ,I mean not whole screen just the area which I draw in ...
AHMAD ALWASHALI
|
|
|
|