Click here to Skip to main content
15,882,017 members
Home / Discussions / Design and Architecture
   

Design and Architecture

 
AnswerRe: Application framework for small or mid sized apps Pin
drinkwater25-Jul-07 4:26
drinkwater25-Jul-07 4:26 
GeneralRe: Application framework for small or mid sized apps Pin
Dave Herren25-Jul-07 9:55
Dave Herren25-Jul-07 9:55 
GeneralRe: Application framework for small or mid sized apps Pin
..Hubert..25-Jul-07 22:24
..Hubert..25-Jul-07 22:24 
GeneralRe: Application framework for small or mid sized apps Pin
led mike3-Aug-07 5:03
led mike3-Aug-07 5:03 
GeneralRe: Application framework for small or mid sized apps Pin
..Hubert..3-Aug-07 5:38
..Hubert..3-Aug-07 5:38 
GeneralRe: Application framework for small or mid sized apps Pin
led mike3-Aug-07 7:02
led mike3-Aug-07 7:02 
AnswerRe: Application framework for small or mid sized apps Pin
awesomeo21-Aug-07 20:18
awesomeo21-Aug-07 20:18 
QuestionRecording a wave file Pin
Leslie Sanford21-Jul-07 16:35
Leslie Sanford21-Jul-07 16:35 
I've written a synth toolkit in C#. I'm adding the capability to record the output as a wave file. I'm trying to nail down the design for doing this. Here's the approach I currently have implemented:


  • User hits record (a check box with a button appearance).
  • Synth engine begins recording output memory
  • User hits record a second time
  • Synth engine stops recording
  • User is prompted and asked if he/she wants to save the wave data

    • If user says yes, the user is prompted for a file name, and the wave data in memory is saved to disk
    • If user says no, wave data is cleared



The problem with the above is that wave data takes up a lot of memory. If the user wants to record for say an hour or so, he/she could run out of memory. I found this out when I forgot to stop recording and ate dinner. When I came back, the computer was slugish due to low memory.

So I was thinking that a better approach would be to record directly to disk:


  • User hits record (a check box with a button appearance).
  • Synth engine begins recording output to a temporary file
  • User hits record a second time
  • Synth engine stops recording
  • User is prompted and asked if he/she wants to save the wave data

    • If user says yes, the user is prompted for a file name, and the temporary file is renamed to the new name
    • If user says no, the temporary file is deleted



Perhaps I should set a limit on how large a file is acceptable so that it's not possible for the program to use up all available disk space. Hmm, maybe I could use that approach for recording to memory instead?

Any thoughts? Details I may be overlooking?
AnswerRe: Recording a wave file Pin
Luc Pattyn22-Jul-07 1:14
sitebuilderLuc Pattyn22-Jul-07 1:14 
GeneralRe: Recording a wave file Pin
Leslie Sanford22-Jul-07 3:34
Leslie Sanford22-Jul-07 3:34 
GeneralRe: Recording a wave file Pin
Luc Pattyn22-Jul-07 3:45
sitebuilderLuc Pattyn22-Jul-07 3:45 
GeneralRe: Recording a wave file Pin
Chris-Kaiser24-Jul-07 11:08
Chris-Kaiser24-Jul-07 11:08 
Questionhow to implement undo functionn by using both Command and Memento design pattern Pin
largs20-Jul-07 23:23
largs20-Jul-07 23:23 
AnswerRe: how to implement undo functionn by using both Command and Memento design pattern Pin
Pete O'Hanlon22-Jul-07 8:47
mvePete O'Hanlon22-Jul-07 8:47 
QuestionDesign question for a Plugin Framework Pin
ssack20-Jul-07 3:26
ssack20-Jul-07 3:26 
AnswerRe: Design question for a Plugin Framework Pin
led mike20-Jul-07 5:25
led mike20-Jul-07 5:25 
GeneralRe: Design question for a Plugin Framework Pin
ssack20-Jul-07 5:43
ssack20-Jul-07 5:43 
QuestionHow to generate code from Rational Rose Diagrams? Pin
FishiFishi19-Jul-07 21:10
FishiFishi19-Jul-07 21:10 
AnswerRe: How to generate code from Rational Rose Diagrams? Pin
led mike20-Jul-07 4:55
led mike20-Jul-07 4:55 
AnswerRe: How to generate code from Rational Rose Diagrams? Pin
Dan Neely20-Jul-07 5:30
Dan Neely20-Jul-07 5:30 
AnswerHow to generate code from Rational Rose Diagrams? Pin
EngMai25-Jul-07 19:13
EngMai25-Jul-07 19:13 
QuestionPost processing a sql string Pin
Paddy Boyd19-Jul-07 6:03
Paddy Boyd19-Jul-07 6:03 
AnswerRe: Post processing a sql string Pin
Urs Enzler20-Jul-07 1:03
Urs Enzler20-Jul-07 1:03 
GeneralRe: Post processing a sql string Pin
Paddy Boyd20-Jul-07 1:05
Paddy Boyd20-Jul-07 1:05 
Questionbox or line ? Pin
tim_gunning18-Jul-07 23:58
tim_gunning18-Jul-07 23:58 

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.