Type: Posts; User: Codeplug
Search took 0.11 seconds.
>> text = "My text."
Those characters have the same code points in all encodings. What characters are you trying to write that are different in the OEM codepage vs ACP codepage?
November 12th, 2013, 12:53 PM
Where does inputPath & final_inputPath come from and how do you know they are UTF8 encoded?
Here's are some utility functions for doing the conversions:...
November 10th, 2013, 04:08 PM
>>Is that correct ?
That is the best you can do with no support for "u8".
October 18th, 2013, 05:35 PM
Forget about lock-free anything. That would be your absolute last resort, with tons of profile data to back that decision up.
Think in terms of "reduce lock contention". Here is an example that...
October 18th, 2013, 05:27 PM
>> Suppose some template code needed to access a static variable.
Could export the variable. Or provide an accessor function to it.
Instantiated templates can also be exported, but may not be...
October 17th, 2013, 07:41 PM
I was referring to shared-mem implementations only.
But since you mention it - how was the FIFO determined to be the bottle neck?
What is the raw messages-per-second (mps) that the consumer...
October 17th, 2013, 11:32 AM
>> the point is to send the data as fast as possible. Since synchronization takes time, a person who developed the code that I posted, used polling instead of semaphores.
October 15th, 2013, 11:28 AM
>> that code sample is about using shared memory without locking so to reduce latency.
Don't try to solve a latency issue that doesn't exist (premature optimization).
The code in that zip was an...
October 14th, 2013, 12:41 PM
>> ... that I downloaded from somewhere.
That code is garbage. Don't even try to learn something from it.
This looks better for learning: https://github.com/risingape/producer-consumer
October 10th, 2013, 11:20 AM
Does anyone know if a C++03 implementations of std::string where c_str() isn't constant complexity (like it is in C++11)?
This was an interesting read:...
October 9th, 2013, 11:15 AM
>> I think you could even spare the reserve call
const string s = "123abc";
//v.reserve(s.length() + 1);
v.assign(s.c_str(), s.c_str() +...
October 8th, 2013, 12:41 PM
I'm partial to reserve + assign + c_str:
const string s = "123abc";
v.reserve(s.length() + 1);
v.assign(s.c_str(), s.c_str() + s.length() + 1);Assuming that...
October 8th, 2013, 11:51 AM
>> Not an issue in this case, the unicode build is set up to use a std::stringw so it remains a straightforward copy.
I'm confused. So the source of the copy is always "std::string", and the ANSI...
September 2nd, 2013, 09:55 PM
>> ... might be better in the sense that I don't have to mess with privileges.
As apposed to writing some driver/application? If it's just for learning/exposure.
>> My application is for Windows....
August 31st, 2013, 04:08 PM
I believe that when Explorer displays an icon for an EXE, it searches the icon resources in the EXE and uses the one with the lowest Id.
"101" may just be some default value used by IDE's or other...
August 31st, 2013, 02:14 PM
As you can see, there is no "WAV" resource definition statement. So it's treated as a "user-defined" resource:...
August 30th, 2013, 05:13 PM
>> so version is like:
The manual will tell you all about it - http://msdn.microsoft.com/en-us/library/aa381059(v=vs.85).aspx
>> how put description and company?...
August 30th, 2013, 01:30 PM
Here is your main reference for resource scripting: http://msdn.microsoft.com/en-us/library/aa381042(v=vs.85).aspx
"MAINICON" isn't part of the resource scripting language. However, it could be...
August 25th, 2013, 12:26 PM
The resource compiler from MinGW is call WindRes.exe. It can compile resource scripts into .o object files, which can then be linked to your application.
August 14th, 2013, 03:31 PM
It's a macro.
See 7.3.1 - 4 (p170)
August 14th, 2013, 10:43 AM
>> Where "I" is a macro from the library!
"I" is part of C99, which VC2008 does not support.
Perhaps you could create a global complex<double> I.
August 6th, 2013, 08:03 PM
ar is just a pointer - with a size of 4 bytes on your system.
>> the above is for Visual C++. Other compiler will have different macro's.
Indeed. Here is a good reference for several different compilers: http://sourceforge.net/p/predef/wiki/Home/
Just remove the path and let the compiler find it on its own.
June 28th, 2013, 11:36 AM
Google("M4 for Windows")
Click Here to Expand Forum to Full Width