Python C API and C++ functions

C++
I'm trying to extend the Python interpreter in my C++ program, my problem is as follows. When I'm trying to call a function, explained in the code bel...
4 years ago

How to mix C++ and C correctly

C
I am having some problems with this: I need to write a C wrapper for a C++ library. Say I have 3 files: wrapper.h typedef struct Foo Foo; Foo* crea...
4 years ago

Convert CRC calculation from C# to C

C
I am currently working on a serial monitor, to ensure some data integrity I am trying to implement a CRC8 checksum, below is the calculation i do on a...
4 years ago

opencv namespaces and c,c++ functions

C++
This is a test program with opencv. It isn't supposed to do anything. #include <opencv2/opencv.hpp> int main (){ cv::Mat src; Mat dst;...
4 years ago

Wrap OpenCV C++ for use with C#

C#
I am trying to wrap openCV for use with C#. This the first time I have tried wrapping C++. I found this question and answer: Creating an C++/CLI Ope...
4 years ago

opencv c and c++ interface conversion table

C
i'l learning opencv with c++ and so i'm trying to use new c++ interface. but a lot of code i found on internet is based on old c interface. for examp...
3 years ago

Translation unit in C and C++

C
Is there a difference between what a translation unit is in C++ and C? In other posts, I read that a header and source file makes a translation unit,...
4 years ago

Is C# the same as Objective-C?

C#
Simple question, I'm just looking for a yes or no clarification. A citation would be appreciated but not necessary. Bonus Question - Can Objective-C ...
4 years ago

Ruby prevent default CTRL+C output ^C

Ruby
I am catching signal with rescue Interrupt => e But it always prints: ^CShutting down! Is there a way to prevent the default CTRL+C output: ...
4 years ago

C# null coalescing operator equivalent for c++

C#
Is there a C++ equivalent for C# null coalescing operator? I am doing too many null checks in my code. So was looking for a way to reduce the amount o...
3 years ago

C++ tutorial for experienced C programmer

C++
I have been programming exclusively in C for 25 years but have never used C++. I now need to learn the basics of C++ programming. Can anyone recommend...
3 years ago

How to visualize bytes with C/C++

C
I'm working my way through some C++ training. So far so good, but I need some help reinforcing some of the concepts I am learning. My question is how ...
3 years ago

Use C++ class in a c file

C
I need to use the mbed api but limited to using C. How can I use for example a SPI class in a c file. From looking online to use C++ classes you shoul...
3 years ago

Marshalling SetupGetInfInformation from C++ to C#

C#
I'm trying to marshal the SetupGetInfInformation function from Windows' SetupAPI to C#. I've defined the (marshalled) structures necessary as follows...
3 years ago

C# - Converting JSON to C# Array

C#
i am new to c# and have a little problem. I have a JSON-file that includes some mailadresses. For each mailadress there are 4 fields (name, email[], i...
3 years ago

Assigning c-array to c++ vector

C++
I have a question about lifetime of onstack created arrays and about transforming them to c++ vectors. For ex I have two functions: void getVector() ...
4 years ago

Is C notably faster than C++

C
As far as I understand all scripting languages and core scientific programs are usually written in C; this renders the implementation messy yet in a w...
4 years ago

Repeating Characters (A B C) in C

C
Given numRows and numCols, print a list of all seats in a theater. Rows are numbered, columns lettered, as in 1A or 3E. Print a space after each seat,...
4 years ago

Converting link list from C to C++

C
I have a working linked list implementation in C (from linux) which I want to convert for use in C++ (on windows). I have a player struct, which look...
4 years ago

C/C++: switch for non-integers

C
Often I need to choose what to do according to the value of a non-POD constant element, something like this: switch( str ) { case "foo": ... case...
4 years ago