d2jsp
Log InRegister
d2jsp Forums > Off-Topic > Computers & IT > Programming & Development > Win32 Api And Windows Gdi > I Doubt This Exists
Prev1567
Add Reply New Topic New Poll
Member
Posts: 5,219
Joined: Oct 29 2009
Gold: 0.00
Warn: 20%
Dec 3 2009 12:18am
Quote (Muted @ Dec 2 2009 11:08pm)
Here's why not:
ReadProcessMemory is capable of getting X number of bytes.
What you're saying is: Why not just loop through 200 bytes, one at a time, calling the same function over and over?
That's ludacris, and I'll just assume you don't know, because if you did, you'd have said it by now, which also explains why you dance around the bush on it.


Member
Posts: 6,953
Joined: Sep 27 2003
Gold: 518.50
Dec 3 2009 02:28am
Quote (Muted @ Dec 3 2009 01:08am)
Here's why not:
ReadProcessMemory is capable of getting X number of bytes.
What you're saying is: Why not just loop through 200 bytes, one at a time, calling the same function over and over?
That's ludacris, and I'll just assume you don't know, because if you did, you'd have said it by now, which also explains why you dance around the bush on it.

200 OPERATIONS IS SOOOOO MUCH FOR A MODERN COMPUTER TO HANDLE. FUNCTION CALLS ARE SO EXPENSIVE. DISREGARD THE FACT THAT THERE IS A WORKING SOLUTION RIGHT IN FRONT OF ME AND OPTIMIZATION SHOULD ALWAYS COME AFTER A WORKING ALGORITHM. I DON'T WANT ANY VERIFICATION OR CHECKING ON MY INPUTS, BECAUSE I KNOW THAT THEY ARE RIGHT. ALL TO SAVE A FEW CYCLES WHICH DIDN'T NEED TO BE SAVED ANYWAY. I ALSO AM GOING TO STOP READING AT THE FIRST SIGN OF NOT AGREEING WITH ME, EVEN THOUGH THE POST MAKES A SUGGESTION ON HOW TO DO IT IN THE WAY THAT I WANTED. I EITHER DON'T UNDERSTAND THE LINKS, SO I'M GOING TO BLAME AND INSULT THE POSTER OR I DO UNDERSTAND THE LINKS BUT THEY'RE NOT EXACTLY WHAT I WANT AND I WANT TO SEEM SUPERIOR SO I'M GOING TO BLAME AND INSULT THE POSTER OR I REALLY AM TOO STUBBORN TO READ PAST A QUESTION AND UNDERSTAND OBJECTIONS TO MY WAY OF THINKING SO I'M GOING TO BLAME AND INSULT THE POSTER. GEEZ I'M SUCH A GREAT PROGRAMMER ALL OF YOU ARE IDIOTS.
Member
Posts: 31,680
Joined: Nov 10 2007
Gold: 1.00
Dec 3 2009 02:45am
... And then Microsoft was born...
Member
Posts: 11,637
Joined: Feb 2 2004
Gold: 434.84
Dec 3 2009 10:18am
Quote (infinitesimal @ Dec 3 2009 02:18am)
http://www.twolia.com/blogs/missinyourbusiness/files/2009/10/ludacris.jpg


This made me laugh at my desk today, thanks.
Member
Posts: 31,680
Joined: Nov 10 2007
Gold: 1.00
Dec 19 2009 02:07am
Quote (ASBands @ 3 Dec 2009 03:28)
200 OPERATIONS IS SOOOOO MUCH FOR A MODERN COMPUTER TO HANDLE.  FUNCTION CALLS ARE SO EXPENSIVE.  DISREGARD THE FACT THAT THERE IS A WORKING SOLUTION RIGHT IN FRONT OF ME AND OPTIMIZATION SHOULD ALWAYS COME AFTER A WORKING ALGORITHM.  I DON'T WANT ANY VERIFICATION OR CHECKING ON MY INPUTS, BECAUSE I KNOW THAT THEY ARE RIGHT.  ALL TO SAVE A FEW CYCLES WHICH DIDN'T NEED TO BE SAVED ANYWAY.  I ALSO AM GOING TO STOP READING AT THE FIRST SIGN OF NOT AGREEING WITH ME, EVEN THOUGH THE POST MAKES A SUGGESTION ON HOW TO DO IT IN THE WAY THAT I WANTED.  I EITHER DON'T UNDERSTAND THE LINKS, SO I'M GOING TO BLAME AND INSULT THE POSTER OR I DO UNDERSTAND THE LINKS BUT THEY'RE NOT EXACTLY WHAT I WANT AND I WANT TO SEEM SUPERIOR SO I'M GOING TO BLAME AND INSULT THE POSTER OR I REALLY AM TOO STUBBORN TO READ PAST A QUESTION AND UNDERSTAND OBJECTIONS TO MY WAY OF THINKING SO I'M GOING TO BLAME AND INSULT THE POSTER.  GEEZ I'M SUCH A GREAT PROGRAMMER ALL OF YOU ARE IDIOTS.


I get you all mixed up, but anyways, your post was extremely childish.
Aren't you the one who cares so much about optimization, that's why you use OOP over structural?

There's more than one way to do what I want, and what I want, isn't hard to do.
I just haven't learned enough to be able to wing it on my own, like I usually do.

If that's hard for you to accept, sorry. But anyways, if I really wanted to, I would do it the way you're saying.
I was just trying to be more 'efficient,' for a change.
Member
Posts: 1,995
Joined: Jun 28 2006
Gold: 7.41
Dec 19 2009 05:55am
Quote (Muted @ Dec 19 2009 03:07am)

I was just trying to be more 'efficient,' for a change.


He offered an algorithm that ran in linear time. It is pretty efficient.
Member
Posts: 6,953
Joined: Sep 27 2003
Gold: 518.50
Dec 19 2009 10:00pm
Quote (Muted @ Dec 19 2009 03:07am)
I get you all mixed up, but anyways, your post was extremely childish.

Because that's pretty much how you talk?

Quote (Muted @ Dec 19 2009 03:07am)
Aren't you the one who cares so much about optimization, that's why you use OOP over structural?

OOP and structural paradigms make no implication for efficiency. Protip: A working, inefficient algorithm is better than a non-existent one.

Quote (Muted @ Dec 19 2009 03:07am)
There's more than one way to do what I want, and what I want, isn't hard to do.
I just haven't learned enough to be able to wing it on my own, like I usually do.

That's why I offered a solution for you. However, you just decided to take the usual "I DON'T UNDERSTAND SO YOU'RE AN IDIOT" route that you take in every single topic.

Quote (Muted @ Dec 19 2009 03:07am)
If that's hard for you to accept, sorry. But anyways, if I really wanted to, I would do it the way you're saying.
I was just trying to be more 'efficient,' for a change.

Like Minkomonster said -- my solution is linear with the size of the image. I highly doubt you can beat that. In non-Big-O terms, you might be able to shave off a few cycles by avoiding the checks for function calls (and only a few cycles -- all the values will be in the L1 cache), but it is going to be safer to let the Windows API do the checking for you. It will also be more extensible, if you wanted to do comparison at beyond the bit-level, although you would probably be better off with OpenCV (as I've suggested before). Since you've been completely unclear as to what you actually want, I really can't help you.
Member
Posts: 5,219
Joined: Oct 29 2009
Gold: 0.00
Warn: 20%
Dec 21 2009 09:56pm
Quote (Minkomonster @ Dec 19 2009 04:55am)
He offered an algorithm that ran in linear time. It is pretty efficient.


Exponential time would be pretty interesting.
Member
Posts: 31,680
Joined: Nov 10 2007
Gold: 1.00
Dec 22 2009 05:09am
Quote (infinitesimal @ 21 Dec 2009 22:56)
Exponential time would be pretty interesting.


That has absolutely nothing to do with the topic... or question for that matter.
Go Back To Programming & Development Topic List
Prev1567
Add Reply New Topic New Poll