예제 #1
0
                public static void MarshalOut(System.IntPtr ptr, android.graphics.BitmapFactory.Options
                                              arg)
                {
                    Options_Struct obj = (Options_Struct)Marshal.PtrToStructure(ptr, typeof(Options_Struct
                                                                                            ));

                    arg.outWidth  = obj.outWidth;
                    arg.outHeight = obj.outHeight;
                }
예제 #2
0
                public static void FreeManagedPtr_inner(System.IntPtr ptr)
                {
                    Options_Struct obj = (Options_Struct)Marshal.PtrToStructure(ptr, typeof(Options_Struct
                                                                                            ));

                    if (obj._owner != 0x972f3813)
                    {
                        throw new System.InvalidOperationException();
                    }
                }
예제 #3
0
                public static android.graphics.BitmapFactory.Options NativeToManaged(System.IntPtr
                                                                                     ptr)
                {
                    if (ptr == System.IntPtr.Zero)
                    {
                        return(null);
                    }
                    Options_Struct obj = (Options_Struct)Marshal.PtrToStructure(ptr, typeof(Options_Struct
                                                                                            ));

                    android.graphics.BitmapFactory.Options arg = new android.graphics.BitmapFactory.Options
                                                                     ();
                    arg.outWidth  = obj.outWidth;
                    arg.outHeight = obj.outHeight;
                    return(arg);
                }
예제 #4
0
                public static void MarshalIn(System.IntPtr ptr, android.graphics.BitmapFactory.Options
                                             arg)
                {
                    Options_Struct obj = new Options_Struct();

                    obj._owner             = 0x972f3813;
                    obj.inMutable          = arg.inMutable ? 1 : 0;
                    obj.inJustDecodeBounds = arg.inJustDecodeBounds ? 1 : 0;
                    obj.inSampleSize       = arg.inSampleSize;
                    obj.inDither           = arg.inDither ? 1 : 0;
                    obj.inPurgeable        = arg.inPurgeable ? 1 : 0;
                    obj.inPreferredConfig  = (int)arg.inPreferredConfig;
                    obj.inBitmap           = arg.inBitmap != null ? arg.inBitmap.mNativeBitmap.Handle : System.IntPtr.Zero;
                    obj.outWidth           = arg.outWidth;
                    obj.outHeight          = arg.outHeight;
                    Marshal.StructureToPtr(obj, ptr, false);
                }
예제 #5
0
				public static void MarshalIn(System.IntPtr ptr, android.graphics.BitmapFactory.Options
					 arg)
				{
					Options_Struct obj = new Options_Struct();
					obj._owner = 0x972f3813;
					obj.inMutable = arg.inMutable ? 1 : 0;
					obj.inJustDecodeBounds = arg.inJustDecodeBounds ? 1 : 0;
					obj.inSampleSize = arg.inSampleSize;
					obj.inDither = arg.inDither ? 1 : 0;
					obj.inPurgeable = arg.inPurgeable ? 1 : 0;
					obj.inPreferredConfig = (int)arg.inPreferredConfig;
					obj.inBitmap = arg.inBitmap != null ? arg.inBitmap.mNativeBitmap.Handle : System.IntPtr.Zero;
					obj.outWidth = arg.outWidth;
					obj.outHeight = arg.outHeight;
					Marshal.StructureToPtr(obj, ptr, false);
				}