Answer the question
In order to leave comments, you need to log in
How to marshal such structure?
Good afternoon.
There is such a structure
typedef struct DOUBLEPOINT
{
union { double X; double x; };
union { double Y; double y; };
void operator = (double value) { x = value; y = value; }
int operator != (double value) { return (x != value || y != value); }
int operator == (double value) { return (x == value && y == value); }
}
DOUBLEPOINT;
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi)]
public struct DOUBLEPOINT
{
public double x;
public double y;
...
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question