|
First of all - you don`t need directX to playback midi.
to play a midi note from an app you have to do the following things:
a) get a handle to midi-device ( start with MIDI-MAPPER - easier@beginning )
use: midiOutopen(...)
b) send a midi-note-on string by
use: midiOutShortMsg(...)
a note-on-command consists of 3 bytes
channel/note-on -> coded in 1. byte
note-number -> coded in 2. byte
note-velocity -> coded in 3. byte
c) send a midi-note-off-string
see b)
d) close midi-devices
use: midiOutClose(..)
For information see MSDN or http://www.harmony-central.com/MIDI/
Hope I forgot nothing important because i have written a midi-dll once and it works fine for years
Greating Mario
--------------------
www.klangwerker.de
rocknix@lycos.de
--------------------
|
|
|
|
|
Hi every body,
I have a project using MFC in a static library. If i compile it my exe size is 2500 ko in release mode. I heared it is possible to compile without symbols in order to decrease this size.
Can anybody say me how to do this ?
Best regards,
Cheickna
|
|
|
|
|
What you heard probably (though not necessarily) refers to compiling debug information into your release executable. This is normally turned off by default. Project->Settings->C/C++ ->Debug Info, select none.
What's giving you the large size is using the MFC static library. That is a big honking library. If you desperately need smaller size, use MFC as a DLL.
Hope this was on track.
|
|
|
|
|
Hi , if I have a VC++ project which applies to Windows SDK and so how am I going to make it work in Windows SDK to generate a .exe?
|
|
|
|
|
I'm sorry, but this question makes no sense. If your program compiles and runs, you HAVE an exe in whatever location VC has been told to put it, most likely under /Debug or /Release.
Christian
The content of this post is not necessarily the opinion of my yadda yadda yadda.
To understand recursion, we must first understand recursion.
|
|
|
|
|
I'm sorry, but this question makes no sense. If your program compiles and runs, you HAVE an exe in whatever location VC has been told to put it, most likely under /Debug or /Release.
If it doesn't compile, you didn't install the SDK properly, it actually sets up the include directories for you. Go to tool/options and make sure your SDK lib and include directories are set up properly.
Christian
The content of this post is not necessarily the opinion of my yadda yadda yadda.
To understand recursion, we must first understand recursion.
|
|
|
|
|
Hi, All!
Can you recommend me somthing like Month Calendar Control?
requirements:
1. day color selection ( like holidays )
2. more than one month displaying if needed
3. adding notes for currently selected day
Microsoft MonthView Control ver. 6.0 and Calendar Control ver. 8.0 can display such a days in bold only. And they can't add comments.
Is there any appropriate freeware ActiveX control? (having source codes will be great, too)
|
|
|
|
|
Serge
Your in luck my friend, I've submitted a Cool Calendar control to Chris about five days ago. He hasn't posted it yet 'cos he's been in the states.
I will bug him to day to post it.
|
|
|
|
|
Or check out:
http://download.cnet.com/downloads/1,10150,0-10009-103-0-1-7,00.html?tag=st%2Ecn%2E10081%2Dron%2Esbsr&qt=calendar&cn=Development+Tools&ca=10009
(www.activex.com)
most will have registration/licencing costs, however.
|
|
|
|
|
If I want to monitor a wm_paint message of any application , do I just need to go and add a windows message handler to my .c file in Visual C++ 6 ?
|
|
|
|
|
Hi !!!
I think you must use hooks functions from Win32API for this task.
Its overview in MSDN help.
Best regards.
|
|
|
|
|
Does C compiler support 32-bit window API? I mean if I create a window program using C compiler , can it be applied to win98
|
|
|
|
|
Yes, almost all comertial programs are programmed in C/C++.
Both programs designed for Win16 (16 bits) and Win32 (32 bits) can be run under Win98. However there are uncountable reasons to use Win32 programming rather than Win16.
I don't know what compiler are you using. Weather your compiler suports Win32 or not should be ask to the compiler manufacturer. For example:
Visual C Version 1.x is designed for 16 bit programming.
Visual C 4.0 and above suports only 32 bit programming.
Borland C 4.5 suports both 16 and 32 bit programming, but it does not have debugger for 32 bit programs.
Borland C 5.0 and above supports Win32.
There are many other windows compilers.
|
|
|
|
|
Yes, almost all comertial programs are programmed in C/C++.
Both programs designed for Win16 (16 bits) and Win32 (32 bits) can be run under Win98. However there are uncountable reasons to use Win32 programming rather than Win16.
I don't know what compiler are you using. Weather your compiler suports Win32 or not should be ask to the compiler manufacturer. For example:
Visual C Version 1.x is designed for 16 bit programming.
Visual C 4.0 and above suports only 32 bit programming.
Borland C 4.5 suports both 16 and 32 bit programming, but it does not have debugger for 32 bit programs.
Borland C 5.0 and above are designed for 32 bit programming. I'm not sure if it also supports 16 bit programming also.
There are many other windows compilers.
|
|
|
|
|
Does C compiler support 32-bit window API?
|
|
|
|
|
Yes, almost all comertial programs are programmed in C/C++.
Both programs designed for Win16 (16 bits) and Win32 (32 bits) can be run under Win98. However there are uncountable reasons to use Win32 programming rather than Win16.
I don't know what compiler are you using. Weather your compiler suports Win32 or not should be ask to the compiler manufacturer. For example:
Visual C Version 1.x is designed for 16 bit programming.
Visual C 4.0 and above suports only 32 bit programming.
Borland C 4.5 suports both 16 and 32 bit programming, but it does not have debugger for 32 bit programs.
Borland C 5.0 and above are designed for 32 bit programming. I'm not sure if it also supports 16 bit programming also.
There are many other windows compilers.
|
|
|
|
|
How to execute outproc COM server from IIS extention with IIS 3
|
|
|
|
|
Hello,
I made this MFC prog (SDI) that changes the default formview to another
formview, but strangly all the controls (derived from CWnd) on this new
formview are missing their CWnd handle (m_hWnd = 0x0000000). what could be
causing this ??
thx,
Pedro Fortuna
|
|
|
|
|
Sounds like the form or its controls haven't been Create()ed yet.
Are you modifiying the CSingleDocTemplate in InitInstance with the name of your new view? If so, the framework should handle creation for you. Have you used the class wiazrd to associate the dialog resouce with that view?
|
|
|
|
|
I found that the error was on the way i switched between views... im using the example on this page http://codeguru.earthweb.com/doc_view/switching_views.shtml
|
|
|
|
|
I created a button dynamically using Cbutton::Create. How do I modify the button after it's been created or even during creation to modify the window style, for example to give the button a static edge.
Here's my code. I tried using CreateEX, with no luck. Anyone have any ideas?
CRect stButton1;
stButton1.SetRect (1080, 170, 1155, 245);
if ( !m_createSpaceTrack.Create
("BREAK
TRACK",WS_PUSHBUTTON|WS_VISIBLE|WS_CHILD|WS_TABSTOP,stButton1,this,1200) )
{
// Failed to create a control.
AfxMessageBox((LPCTSTR)"Failed to Create SPACETRACK Button1",MB_OK,0); }
|
|
|
|
|
This is probably more than you want, but hey...
void TestDialog::OnOK()
{
static int n = 0;
if(!m_cbSpaceTrack.m_hWnd) {
CRect stButton1;
stButton1.SetRect (20, 20, 140, 60);
if ( !m_cbSpaceTrack.Create("BREAKTRACK",BS_PUSHBUTTON |WS_TABSTOP|WS_VISIBLE|WS_CHILD|WS_BORDER,stButton1,this,5000) )
{
AfxMessageBox((LPCTSTR)"Failed to Create SPACETRACK Button1",MB_OK,0);
}
}
else {
m_cbSpaceTrack.ShowWindow(SW_HIDE);
switch (n) {
case 0 :
m_cbSpaceTrack.SetButtonStyle(BS_CHECKBOX, TRUE);
++n;
break;
case 1 :
m_cbSpaceTrack.SetButtonStyle(BS_GROUPBOX, TRUE);
m_cbSpaceTrack.ModifyStyle(0, WS_BORDER);
++n;
break;
case 2 :
m_cbSpaceTrack.SetButtonStyle(BS_RADIOBUTTON, TRUE);
m_cbSpaceTrack.ModifyStyle(WS_BORDER,0);
n=0;
break;
case 3 :
m_cbSpaceTrack.SetButtonStyle(BS_PUSHBUTTON, TRUE);
m_cbSpaceTrack.ModifyStyle(0, WS_BORDER);
n=0;
break;
default:
break;
}
m_cbSpaceTrack.ShowWindow(SW_SHOW);
}
}
Beyond this type of stuff, you might need to use the BS_OWNERDRAW style and override DrawItem.
|
|
|
|
|
I have written an MFC program (dialog based) to load a bitmap file, and display it on a frame control. This all works fine, except when you put another window on top of it! How do you get the bitmap to stay on the DC?
Any help would be greatly appreciated...
James Bird - birdjames@bigfoot.com
|
|
|
|
|
You need to do your drawing in OnPaint. which is called when a window is invalidated by another.
Christian
The content of this post is not necessarily the opinion of my yadda yadda yadda.
To understand recursion, we must first understand recursion.
|
|
|
|
|
Can anyone tell me how document , view and main frame come into the whole picture of VC++?
|
|
|
|