Click here to Skip to main content
15,901,426 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Kill 16-bit Task/process Pin
Rage17-Dec-02 4:07
professionalRage17-Dec-02 4:07 
GeneralRe: Kill 16-bit Task/process Pin
AnTri17-Dec-02 5:11
AnTri17-Dec-02 5:11 
GeneralThe Need for speed Pin
will138317-Dec-02 3:45
will138317-Dec-02 3:45 
GeneralRe: The Need for speed Pin
KaЯl17-Dec-02 4:00
KaЯl17-Dec-02 4:00 
GeneralRe: The Need for speed Pin
will138317-Dec-02 4:15
will138317-Dec-02 4:15 
GeneralRe: The Need for speed Pin
Gary Kirkham17-Dec-02 4:40
Gary Kirkham17-Dec-02 4:40 
GeneralRe: The Need for speed Pin
will138317-Dec-02 4:49
will138317-Dec-02 4:49 
GeneralRe: The Need for speed Pin
Nitron17-Dec-02 5:07
Nitron17-Dec-02 5:07 
groover4life wrote:
So in essence what you are saying is; Instead of using the WM_TIMER message, create a thread that just performs a basic loop, getting the data and updating the display, and the update rate will be what ever the CPU slice is for that particular thread?

wait, wait, wait... Use the loop in the thjread for data mainpulation only, and pump custom messages out of the thread to the UI thread and handle the redraw and stuff in the UI thread as a message handler. I've had very bad experiences when trying to access stuff outside of my own little thread, but the PostMessage thing works very well. NT should get you pretty accurate down to around 10ms or so, so that is about a 100Hz refresh. (You'll need to do a Sleep(10) or whatever to delay the thread.) Make sure you aren't doing very time consuming stuff here either, as that will begin to affect your performance. Remember, NT is not an RT OS, so you are at the mercy of other higher priority things on the PC. There are some articles around here about using multimedia timers for better precision, but I haven't used any of them yet.

- Nitron


"Those that say a task is impossible shouldn't interrupt the ones who are doing it." - Chinese Proverb
GeneralRe: The Need for speed Pin
will138317-Dec-02 5:37
will138317-Dec-02 5:37 
GeneralRe: The Need for speed Pin
KaЯl17-Dec-02 5:20
KaЯl17-Dec-02 5:20 
GeneralRe: The Need for speed Pin
will138317-Dec-02 5:27
will138317-Dec-02 5:27 
GeneralRe: The Need for speed Pin
KaЯl17-Dec-02 7:09
KaЯl17-Dec-02 7:09 
GeneralExtTextOut drawing landscape... Pin
Braulio Dez17-Dec-02 3:27
Braulio Dez17-Dec-02 3:27 
GeneralRe: ExtTextOut drawing landscape... Pin
Nitron17-Dec-02 3:32
Nitron17-Dec-02 3:32 
GeneralResizing CFormView with Status Bar and Toolbar Pin
Jonah Bishop17-Dec-02 3:28
Jonah Bishop17-Dec-02 3:28 
GeneralRe: Resizing CFormView with Status Bar and Toolbar Pin
Nitron17-Dec-02 3:36
Nitron17-Dec-02 3:36 
GeneralRe: Resizing CFormView with Status Bar and Toolbar Pin
Jonah Bishop17-Dec-02 3:58
Jonah Bishop17-Dec-02 3:58 
GeneralRe: Resizing CFormView with Status Bar and Toolbar Pin
Nitron17-Dec-02 4:01
Nitron17-Dec-02 4:01 
GeneralRe: Resizing CFormView with Status Bar and Toolbar Pin
Jonah Bishop17-Dec-02 4:23
Jonah Bishop17-Dec-02 4:23 
General_stdcall question Pin
ns17-Dec-02 3:03
ns17-Dec-02 3:03 
GeneralRe: _stdcall question Pin
Joaquín M López Muñoz17-Dec-02 3:08
Joaquín M López Muñoz17-Dec-02 3:08 
GeneralRe: _stdcall question Pin
ns17-Dec-02 3:15
ns17-Dec-02 3:15 
GeneralRe: _stdcall question Pin
ns17-Dec-02 3:27
ns17-Dec-02 3:27 
GeneralRe: _stdcall question Pin
Joaquín M López Muñoz17-Dec-02 3:33
Joaquín M López Muñoz17-Dec-02 3:33 
GeneralRe: _stdcall question Pin
ns17-Dec-02 3:44
ns17-Dec-02 3:44 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.