Click here to Skip to main content
15,884,059 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: VC++ and Empty Base Class Optimization problem/bug Pin
Kosta Cherry15-Mar-13 6:23
Kosta Cherry15-Mar-13 6:23 
GeneralRe: VC++ and Empty Base Class Optimization problem/bug Pin
Matthew Faithfull15-Mar-13 6:36
Matthew Faithfull15-Mar-13 6:36 
GeneralRe: VC++ and Empty Base Class Optimization problem/bug Pin
David Crow15-Mar-13 7:34
David Crow15-Mar-13 7:34 
GeneralRe: VC++ and Empty Base Class Optimization problem/bug Pin
Kosta Cherry15-Mar-13 8:45
Kosta Cherry15-Mar-13 8:45 
AnswerRe: VC++ and Empty Base Class Optimization problem/bug Pin
jschell15-Mar-13 8:56
jschell15-Mar-13 8:56 
QuestionHow Can I set Noise In Image ? Pin
002comp14-Mar-13 19:25
002comp14-Mar-13 19:25 
AnswerRe: How Can I set Noise In Image ? Pin
Marco Bertschi14-Mar-13 22:21
protectorMarco Bertschi14-Mar-13 22:21 
AnswerRe: How Can I set Noise In Image ? Pin
nv316-Mar-13 2:16
nv316-Mar-13 2:16 
Two things: You are not really adding noise, but just setting a pixel to black here and there.

The idea of noise is to modify all color components of all pixels by adding a random value (plus or minus). So, start off by using a random number generator like rand(), scale its return value to the amount of noise you want and add the outcome pixel by pixel. You may think of it as computing a noise image and adding that image to your original image.

If you want to refine that, don't use equally distributed random numbers, but gaussian distribution or others. And you may apply filterind (low-pass, higo-pass, etc) to the noise image before adding to modify the spectral distribution of noise.
QuestiontimeGetTime() is unreliable on my computer too, not monotonic! Pin
Robert Inventor14-Mar-13 18:04
Robert Inventor14-Mar-13 18:04 
AnswerMessage Closed Pin
14-Mar-13 18:15
Robert Inventor14-Mar-13 18:15 
GeneralMessage Closed Pin
14-Mar-13 18:20
Robert Inventor14-Mar-13 18:20 
GeneralMessage Closed Pin
14-Mar-13 18:53
Robert Inventor14-Mar-13 18:53 
GeneralMessage Closed Pin
14-Mar-13 19:19
Robert Inventor14-Mar-13 19:19 
AnswerRe: timeGetTime() is unreliable on my computer too, not monotonic! Pin
Robert Inventor19-Mar-13 7:31
Robert Inventor19-Mar-13 7:31 
QuestionQueryPerformanceCounter inaccurate timing even with use of SetThreadAffinityMask Pin
Robert Inventor14-Mar-13 15:50
Robert Inventor14-Mar-13 15:50 
AnswerRe: QueryPerformanceCounter inaccurate timing even with use of SetThreadAffinityMask Pin
Robert Inventor14-Mar-13 18:07
Robert Inventor14-Mar-13 18:07 
GeneralRe: QueryPerformanceCounter inaccurate timing even with use of SetThreadAffinityMask Pin
dusty_dex15-Mar-13 0:24
dusty_dex15-Mar-13 0:24 
GeneralRe: QueryPerformanceCounter inaccurate timing even with use of SetThreadAffinityMask Pin
Robert Inventor18-Mar-13 14:44
Robert Inventor18-Mar-13 14:44 
GeneralRe: QueryPerformanceCounter inaccurate timing even with use of SetThreadAffinityMask Pin
dusty_dex18-Mar-13 22:08
dusty_dex18-Mar-13 22:08 
AnswerRe: QueryPerformanceCounter inaccurate timing even with use of SetThreadAffinityMask Pin
Robert Inventor19-Mar-13 6:19
Robert Inventor19-Mar-13 6:19 
GeneralRe: QueryPerformanceCounter inaccurate timing even with use of SetThreadAffinityMask Pin
dusty_dex19-Mar-13 8:34
dusty_dex19-Mar-13 8:34 
GeneralRe: QueryPerformanceCounter inaccurate timing even with use of SetThreadAffinityMask Pin
Robert Inventor20-Mar-13 10:10
Robert Inventor20-Mar-13 10:10 
GeneralRe: QueryPerformanceCounter inaccurate timing even with use of SetThreadAffinityMask Pin
Robert Inventor20-Mar-13 11:12
Robert Inventor20-Mar-13 11:12 
GeneralRe: QueryPerformanceCounter inaccurate timing even with use of SetThreadAffinityMask Pin
dusty_dex20-Mar-13 11:18
dusty_dex20-Mar-13 11:18 
GeneralRe: QueryPerformanceCounter inaccurate timing even with use of SetThreadAffinityMask Pin
Robert Inventor20-Mar-13 12:15
Robert Inventor20-Mar-13 12:15 

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.