|
50 | 50 | #include "XnoteStopwatchFormat.h" |
51 | 51 | #include "Camstudio4XNote.h" |
52 | 52 |
|
| 53 | +#ifdef _DEBUG |
| 54 | +// #include <vld.h> // Visual Leak Detector utility (In debug mode) |
| 55 | +#endif |
| 56 | + |
53 | 57 | #include <windowsx.h> |
54 | 58 | #include <fstream> |
55 | 59 | #include <iostream> |
@@ -1234,10 +1238,10 @@ void CRecorderView::OnRecord() |
1234 | 1238 | // Applicable when Option region is set as 'Fixed Region' |
1235 | 1239 |
|
1236 | 1240 |
|
1237 | | - rc = CRect(cRegionOpts.m_iCaptureTop, |
1238 | | - cRegionOpts.m_iCaptureLeft, |
1239 | | - cRegionOpts.m_iCaptureLeft + cRegionOpts.m_iCaptureWidth - 1 , |
1240 | | - cRegionOpts.m_iCaptureTop + cRegionOpts.m_iCaptureHeight - 1 ); |
| 1241 | + rc = CRect(cRegionOpts.m_iCaptureLeft, // X = Left |
| 1242 | + cRegionOpts.m_iCaptureTop, // Y = Top |
| 1243 | + cRegionOpts.m_iCaptureLeft + cRegionOpts.m_iCaptureWidth - 1 , // X = Width |
| 1244 | + cRegionOpts.m_iCaptureTop + cRegionOpts.m_iCaptureHeight - 1 ); // Y = Height |
1241 | 1245 |
|
1242 | 1246 | // TRACE( _T("## CRecorderView::OnRecord /CAPTURE_FIXED/ before / rc / T=%d, L=%d, B=%d, R=%d \n"), rc.top, rc.left, rc.bottom, rc.right ); |
1243 | 1247 |
|
@@ -1294,6 +1298,8 @@ void CRecorderView::OnRecord() |
1294 | 1298 | case CAPTURE_WINDOW: |
1295 | 1299 | case CAPTURE_FULLSCREEN: |
1296 | 1300 | // Applicable when Option region is set as 'Window' and as 'Full Screen' |
| 1301 | + |
| 1302 | + // TODO, Possible memory leak, where is the delete operation of the new below done? |
1297 | 1303 | m_basicMsg = new CBasicMessage(); |
1298 | 1304 | m_basicMsg->Create(CBasicMessage::IDD); |
1299 | 1305 | m_basicMsg->SetText(_T("Click on window to be captured.")); |
@@ -1338,8 +1344,11 @@ void CRecorderView::OnFileVideooptions() |
1338 | 1344 | LPBITMAPINFOHEADER first_alpbi = captureScreenFrame(rect) ? m_cCamera.Image() : 0; |
1339 | 1345 |
|
1340 | 1346 | num_compressor = 0; |
1341 | | - if (pCompressorInfo) |
| 1347 | + if (pCompressorInfo) { |
1342 | 1348 | delete [] pCompressorInfo; |
| 1349 | + } |
| 1350 | + |
| 1351 | + // TODO, Possible memory leak, where is the delete operation of the new below done? |
1343 | 1352 | pCompressorInfo = new ICINFO[MAXCOMPRESSORS]; |
1344 | 1353 |
|
1345 | 1354 | //for (int i = 0; ICInfo(ICTYPE_VIDEO, i, &pCompressorInfo[num_compressor]); i++) { |
@@ -2846,6 +2855,7 @@ void CRecorderView::OnViewVideoannotations() |
2846 | 2855 |
|
2847 | 2856 | rect.left = x; |
2848 | 2857 | rect.top = y; |
| 2858 | + // TODO, Magic values here again 160,120 |
2849 | 2859 | rect.right = rect.left + 160 - 1; |
2850 | 2860 | rect.bottom = rect.top + 120 - 1; |
2851 | 2861 | m_vanWnd.TextString(m_newShapeText); |
@@ -4693,6 +4703,7 @@ void DataFromSoundIn(CBuffer* buffer) |
4693 | 4703 | int AddInputBufferToQueue() |
4694 | 4704 | { |
4695 | 4705 | // create the header |
| 4706 | + // TODO, Possible memory leak, where is the delete operation of the new below done? |
4696 | 4707 | LPWAVEHDR pHdr = new WAVEHDR; |
4697 | 4708 | if (pHdr == NULL) { |
4698 | 4709 | return NULL; |
@@ -4765,6 +4776,7 @@ BOOL InitAudioRecording() |
4765 | 4776 |
|
4766 | 4777 | //Create temporary wav file for audio recording |
4767 | 4778 | GetTempAudioWavPath(); |
| 4779 | + // TODO, Possible memory leak, where is the delete operation of the new below done? |
4768 | 4780 | pSoundFile = new CSoundFile(strTempAudioWavFilePath, &(cAudioFormat.AudioFormat())); |
4769 | 4781 |
|
4770 | 4782 | if (!(pSoundFile && pSoundFile->IsOK())) |
|
0 commit comments