Esempio n. 1
0
        public static QImage ConvolveInteger(QImage img, int matrix_size, ref int matrix)
        {
            StackItem[] stack = new StackItem[4];
#if DEBUG
            stack[1].s_class = (IntPtr)DebugGCHandle.Alloc(img);
#else
            stack[1].s_class = (IntPtr)GCHandle.Alloc(img);
#endif
            stack[2].s_int = matrix_size;
            stack[3].s_int = matrix;
            staticInterceptor.Invoke("convolveInteger#$$", "convolveInteger(QImage&, int, int*)", stack);
#if DEBUG
            DebugGCHandle.Free((GCHandle)stack[1].s_class);
#else
            ((GCHandle)stack[1].s_class).SynchronizedFree();
#endif
            matrix = stack[3].s_int;
            object returnValue = ((GCHandle)stack[0].s_class).Target;
#if DEBUG
            DebugGCHandle.Free((GCHandle)stack[0].s_class);
#else
            ((GCHandle)stack[0].s_class).SynchronizedFree();
#endif
            return((QImage)returnValue);
        }
Esempio n. 2
0
        public string CallTips(List <string> context, QsciScintilla.CallTipsStyle style, int maxnr, int commas, ref int ctshift)
        {
            StackItem[] stack = new StackItem[6];
#if DEBUG
            stack[1].s_class = (IntPtr)DebugGCHandle.Alloc(context);
#else
            stack[1].s_class = (IntPtr)GCHandle.Alloc(context);
#endif
            stack[2].s_int = (int)style;
            stack[3].s_int = maxnr;
            stack[4].s_int = commas;
            stack[5].s_int = ctshift;
            interceptor.Invoke("callTips?$$$$", "callTips(const QStringList&, QsciScintilla::CallTipsStyle, int, int, int&)", stack);
#if DEBUG
            DebugGCHandle.Free((GCHandle)stack[1].s_class);
#else
            ((GCHandle)stack[1].s_class).SynchronizedFree();
#endif
            ctshift = stack[5].s_int;
            object returnValue = ((GCHandle)stack[0].s_class).Target;
#if DEBUG
            DebugGCHandle.Free((GCHandle)stack[0].s_class);
#else
            ((GCHandle)stack[0].s_class).SynchronizedFree();
#endif
            return((string)returnValue);
        }