示例#1
0
文件: Tools.cs 项目: Yanrishatum/UGif
        public static int loopCount(object data)
        {
            unchecked {
                {
                    global::haxe.ds._List.ListNode <object> _g_head = ((global::haxe.ds.List <object>)(global::haxe.ds.List <object> .__hx_cast <object>(((global::haxe.ds.List)(global::haxe.lang.Runtime.getField(data, "blocks", 669658758, true)))))).h;
                    while ((_g_head != null))
                    {
                        global::format.gif.Block val = ((global::format.gif.Block)(_g_head.item));
                        _g_head = _g_head.next;
                        global::format.gif.Block block = ((global::format.gif.Block)(val));
                        if ((block._hx_index == 1))
                        {
                            if (((block as global::format.gif.Block_BExtension).extension._hx_index == 3))
                            {
                                if ((((block as global::format.gif.Block_BExtension).extension as global::format.gif.Extension_EApplicationExtension).ext._hx_index == 0))
                                {
                                    int loops = (((block as global::format.gif.Block_BExtension).extension as global::format.gif.Extension_EApplicationExtension).ext as global::format.gif.ApplicationExtension_AENetscapeLooping).loops;
                                    return(loops);
                                }
                            }
                        }
                    }
                }

                return(1);
            }
        }
示例#2
0
文件: Tools.cs 项目: Yanrishatum/UGif
        public static object frame(object data, int frameIndex)
        {
            int counter = 0;

            {
                global::haxe.ds._List.ListNode <object> _g_head = ((global::haxe.ds.List <object>)(global::haxe.ds.List <object> .__hx_cast <object>(((global::haxe.ds.List)(global::haxe.lang.Runtime.getField(data, "blocks", 669658758, true)))))).h;
                while ((_g_head != null))
                {
                    global::format.gif.Block val = ((global::format.gif.Block)(_g_head.item));
                    _g_head = _g_head.next;
                    global::format.gif.Block block = ((global::format.gif.Block)(val));
                    if ((block._hx_index == 0))
                    {
                        object frame = (block as global::format.gif.Block_BFrame).frame;
                        {
                            if ((counter == frameIndex))
                            {
                                return(frame);
                            }

                            ++counter;
                        }
                    }
                }
            }

            return(null);
        }
示例#3
0
        public override object __hx_setField(string field, int hash, object @value, bool handleProperties)
        {
            unchecked {
                                #line 295 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                switch (hash)
                {
                case 1158359328:
                {
                                                #line 295 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    this.head = ((global::haxe.ds._List.ListNode)(@value));
                                                #line 295 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    return(@value);
                }


                case 5243965:
                {
                                                #line 295 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    this.idx = ((int)(global::haxe.lang.Runtime.toInt(@value)));
                                                #line 295 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    return(@value);
                }


                default:
                {
                                                #line 295 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    return(base.__hx_setField(field, hash, @value, handleProperties));
                }
                }
            }
                        #line default
        }
示例#4
0
        public override object __hx_setField(string field, int hash, object @value, bool handleProperties)
        {
            unchecked {
                switch (hash)
                {
                case 520590566:
                {
                    this.length = ((int)(global::haxe.lang.Runtime.toInt(@value)));
                    return(@value);
                }


                case 113:
                {
                    this.q = ((global::haxe.ds._List.ListNode <T>)(global::haxe.ds._List.ListNode <object> .__hx_cast <T>(((global::haxe.ds._List.ListNode)(@value)))));
                    return(@value);
                }


                case 104:
                {
                    this.h = ((global::haxe.ds._List.ListNode <T>)(global::haxe.ds._List.ListNode <object> .__hx_cast <T>(((global::haxe.ds._List.ListNode)(@value)))));
                    return(@value);
                }


                default:
                {
                    return(base.__hx_setField(field, hash, @value, handleProperties));
                }
                }
            }
        }
示例#5
0
        public virtual string toString()
        {
                        #line 178 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            global::System.Text.StringBuilder s_b = new global::System.Text.StringBuilder();
            bool first = true;
                        #line 180 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            global::haxe.ds._List.ListNode l = this.h;
            s_b.Append(((string)("{")));
                        #line 182 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            while ((l != null))
            {
                                #line 183 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                if (first)
                {
                                        #line 184 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    first = false;
                }
                else
                {
                                        #line 186 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    s_b.Append(((string)(", ")));
                }

                                #line 187 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                s_b.Append(((string)(global::haxe.root.Std.@string(global::haxe.root.Std.@string(l.item)))));
                l = l.next;
            }

                        #line 190 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            s_b.Append(((string)("}")));
            return(s_b.ToString());
        }
示例#6
0
        public virtual string @join(string sep)
        {
                        #line 199 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            global::System.Text.StringBuilder s_b = new global::System.Text.StringBuilder();
            bool first = true;
                        #line 201 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            global::haxe.ds._List.ListNode l = this.h;
            while ((l != null))
            {
                                #line 203 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                if (first)
                {
                                        #line 204 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    first = false;
                }
                else
                {
                                        #line 206 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    s_b.Append(((string)(global::haxe.root.Std.@string(sep))));
                }

                                #line 207 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                s_b.Append(((string)(global::haxe.root.Std.@string(l.item))));
                l = l.next;
            }

                        #line 210 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            return(s_b.ToString());
        }
示例#7
0
        public override object __hx_setField(string field, int hash, object @value, bool handleProperties)
        {
            unchecked {
                                #line 262 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                switch (hash)
                {
                case 1224901875:
                {
                                                #line 262 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    this.next = ((global::haxe.ds._List.ListNode)(@value));
                                                #line 262 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    return(@value);
                }


                case 1170195731:
                {
                                                #line 262 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    this.item = ((object)(@value));
                                                #line 262 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    return(@value);
                }


                default:
                {
                                                #line 262 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    return(base.__hx_setField(field, hash, @value, handleProperties));
                }
                }
            }
                        #line default
        }
示例#8
0
        public override object __hx_setField(string field, int hash, object @value, bool handleProperties)
        {
            unchecked {
                switch (hash)
                {
                case 1224901875:
                {
                    this.next = ((global::haxe.ds._List.ListNode <T>)(global::haxe.ds._List.ListNode <object> .__hx_cast <T>(((global::haxe.ds._List.ListNode)(@value)))));
                    return(@value);
                }


                case 1170195731:
                {
                    this.item = global::haxe.lang.Runtime.genericCast <T>(@value);
                    return(@value);
                }


                default:
                {
                    return(base.__hx_setField(field, hash, @value, handleProperties));
                }
                }
            }
        }
示例#9
0
 public object next()
 {
                 #line 289 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
     object val = this.head.item;
     this.head = this.head.next;
                 #line 291 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
     return(val);
 }
示例#10
0
 public virtual void clear()
 {
                 #line 124 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
     this.h = null;
     this.q = null;
                 #line 126 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
     this.length = 0;
 }
示例#11
0
文件: Tools.cs 项目: Yanrishatum/UGif
        public static object graphicControl(object data, int frameIndex)
        {
            unchecked {
                int    counter = 0;
                object gce     = null;
                {
                    global::haxe.ds._List.ListNode <object> _g_head = ((global::haxe.ds.List <object>)(global::haxe.ds.List <object> .__hx_cast <object>(((global::haxe.ds.List)(global::haxe.lang.Runtime.getField(data, "blocks", 669658758, true)))))).h;
                    while ((_g_head != null))
                    {
                        global::format.gif.Block val = ((global::format.gif.Block)(_g_head.item));
                        _g_head = _g_head.next;
                        global::format.gif.Block block = ((global::format.gif.Block)(val));
                        switch (block._hx_index)
                        {
                        case 0:
                        {
                            object frame = (block as global::format.gif.Block_BFrame).frame;
                            {
                                if ((counter == frameIndex))
                                {
                                    return(gce);
                                }

                                gce = null;
                                ++counter;
                            }

                            break;
                        }


                        case 1:
                        {
                            if (((block as global::format.gif.Block_BExtension).extension._hx_index == 0))
                            {
                                object g = ((block as global::format.gif.Block_BExtension).extension as global::format.gif.Extension_EGraphicControl).gce;
                                gce = g;
                            }

                            break;
                        }


                        default:
                        {
                            break;
                        }
                        }
                    }
                }

                return(null);
            }
        }
示例#12
0
 public object next()
 {
                 #line 309 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
     object val = this.head.item;
     this.head = this.head.next;
                 #line 311 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
     {
                         #line 311 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
         int __temp_odecl1 = this.idx++;
                         #line 311 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
         return(new global::haxe.lang.DynamicObject(new int[] { 834174833 }, new object[] { val }, new int[] { 5343647 }, new double[] { ((double)(__temp_odecl1)) }));
     }
 }
示例#13
0
        public virtual void push(object item)
        {
                        #line 69 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            global::haxe.ds._List.ListNode x = new global::haxe.ds._List.ListNode(item, this.h);
            this.h = x;
                        #line 71 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            if ((this.q == null))
            {
                                #line 72 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                this.q = x;
            }

                        #line 73 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            this.length++;
        }
示例#14
0
        public virtual void @add(T item)
        {
            global::haxe.ds._List.ListNode <T> x = new global::haxe.ds._List.ListNode <T>(item, null);
            if ((this.h == null))
            {
                this.h = x;
            }
            else
            {
                this.q.next = x;
            }

            this.q = x;
            this.length++;
        }
示例#15
0
        public virtual global::haxe.ds.List map(global::haxe.lang.Function f)
        {
                        #line 234 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            global::haxe.ds.List           b = new global::haxe.ds.List();
            global::haxe.ds._List.ListNode l = this.h;
                        #line 236 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            while ((l != null))
            {
                                #line 237 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                object v = l.item;
                l = l.next;
                                #line 239 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                b.@add(((object)(f.__hx_invoke1_o(default(double), v))));
            }

                        #line 241 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            return(b);
        }
示例#16
0
        public virtual object haxe_ds__List_ListNode_cast <T_c>()
        {
            if (global::haxe.lang.Runtime.eq(typeof(T), typeof(T_c)))
            {
                return(this);
            }

            global::haxe.ds._List.ListNode <T_c> new_me = new global::haxe.ds._List.ListNode <T_c>(global::haxe.lang.EmptyObject.EMPTY);
            global::haxe.root.Array <object>     fields = global::haxe.root.Reflect.fields(this);
            int i = 0;

            while ((i < fields.length))
            {
                string field = global::haxe.lang.Runtime.toString(fields[i++]);
                global::haxe.root.Reflect.setField(new_me, field, global::haxe.root.Reflect.field(this, field));
            }

            return(new_me);
        }
示例#17
0
        public virtual bool @remove(object v)
        {
                        #line 138 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            global::haxe.ds._List.ListNode prev = null;
            global::haxe.ds._List.ListNode l    = this.h;
                        #line 140 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            while ((l != null))
            {
                                #line 141 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                if (global::haxe.lang.Runtime.eq(l.item, v))
                {
                                        #line 142 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    if ((prev == null))
                    {
                                                #line 143 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                        this.h = l.next;
                    }
                    else
                    {
                                                #line 145 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                        prev.next = l.next;
                    }

                                        #line 146 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    if ((this.q == l))
                    {
                                                #line 147 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                        this.q = prev;
                    }

                                        #line 148 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    this.length--;
                    return(true);
                }

                                #line 151 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                prev = l;
                l    = l.next;
            }

                        #line 154 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            return(false);
        }
示例#18
0
文件: Tools.cs 项目: Yanrishatum/UGif
        public static int framesCount(object data)
        {
            int frames = 0;

            {
                global::haxe.ds._List.ListNode <object> _g_head = ((global::haxe.ds.List <object>)(global::haxe.ds.List <object> .__hx_cast <object>(((global::haxe.ds.List)(global::haxe.lang.Runtime.getField(data, "blocks", 669658758, true)))))).h;
                while ((_g_head != null))
                {
                    global::format.gif.Block val = ((global::format.gif.Block)(_g_head.item));
                    _g_head = _g_head.next;
                    global::format.gif.Block block = ((global::format.gif.Block)(val));
                    if ((block._hx_index == 0))
                    {
                        ++frames;
                    }
                }
            }

            return(frames);
        }
示例#19
0
        public virtual void @add(object item)
        {
                        #line 54 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            global::haxe.ds._List.ListNode next = null;
                        #line 54 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            global::haxe.ds._List.ListNode x = new global::haxe.ds._List.ListNode(item, next);
            if ((this.h == null))
            {
                                #line 56 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                this.h = x;
            }
            else
            {
                                #line 58 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                this.q.next = x;
            }

                        #line 59 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            this.q = x;
            this.length++;
        }
示例#20
0
        public virtual global::haxe.ds.List filter(global::haxe.lang.Function f)
        {
                        #line 218 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            global::haxe.ds.List           l2 = new global::haxe.ds.List();
            global::haxe.ds._List.ListNode l  = this.h;
                        #line 220 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            while ((l != null))
            {
                                #line 221 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                object v = l.item;
                l = l.next;
                                #line 223 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                if (global::haxe.lang.Runtime.toBool(f.__hx_invoke1_o(default(double), v)))
                {
                                        #line 224 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                    l2.@add(v);
                }
            }

                        #line 226 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            return(l2);
        }
示例#21
0
        public virtual object pop()
        {
                        #line 100 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            if ((this.h == null))
            {
                                #line 101 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                return(null);
            }

                        #line 102 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            object x = this.h.item;
            this.h = this.h.next;
                        #line 104 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            if ((this.h == null))
            {
                                #line 105 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
                this.q = null;
            }

                        #line 106 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
            this.length--;
            return(x);
        }
示例#22
0
        public virtual void write(global::haxe.ds.List <object> png)
        {
            unchecked {
                {
                    int _g = 0;
                    global::haxe.root.Array <int> _g1 = new global::haxe.root.Array <int>(new int[] { 137, 80, 78, 71, 13, 10, 26, 10 });
                    while ((_g < _g1.length))
                    {
                        int b = _g1[_g];
                        ++_g;
                        this.o.writeByte(b);
                    }
                }

                {
                    global::haxe.ds._List.ListNode <object> _g_head = png.h;
                    while ((_g_head != null))
                    {
                        global::format.png.Chunk val = ((global::format.png.Chunk)(_g_head.item));
                        _g_head = _g_head.next;
                        global::format.png.Chunk c = ((global::format.png.Chunk)(val));
                        switch (c._hx_index)
                        {
                        case 0:
                        {
                            this.writeChunk("IEND", global::haxe.io.Bytes.alloc(0));
                            break;
                        }


                        case 1:
                        {
                            object h = (c as global::format.png.Chunk_CHeader).h;
                            {
                                global::haxe.io.BytesOutput b1 = new global::haxe.io.BytesOutput();
                                b1.set_bigEndian(true);
                                b1.writeInt32(((int)(global::haxe.lang.Runtime.getField_f(h, "width", 1247983110, true))));
                                b1.writeInt32(((int)(global::haxe.lang.Runtime.getField_f(h, "height", 38537191, true))));
                                b1.writeByte(((int)(global::haxe.lang.Runtime.getField_f(h, "colbits", 1724357446, true))));
                                global::format.png.Color _g2 = ((global::format.png.Color)(global::haxe.lang.Runtime.getField(h, "color", 1247572323, true)));
                                int tmp = default(int);
                                switch (_g2._hx_index)
                                {
                                case 0:
                                {
                                    bool alpha = (_g2 as global::format.png.Color_ColGrey).alpha;
                                    tmp = ((alpha) ? (4) : (0));
                                    break;
                                }


                                case 1:
                                {
                                    bool alpha1 = (_g2 as global::format.png.Color_ColTrue).alpha;
                                    tmp = ((alpha1) ? (6) : (2));
                                    break;
                                }


                                case 2:
                                {
                                    tmp = 3;
                                    break;
                                }
                                }

                                b1.writeByte(tmp);
                                b1.writeByte(0);
                                b1.writeByte(0);
                                b1.writeByte(((global::haxe.lang.Runtime.toBool(global::haxe.lang.Runtime.getField(h, "interlaced", 1501088657, true))) ? (1) : (0)));
                                this.writeChunk("IHDR", b1.getBytes());
                            }

                            break;
                        }


                        case 2:
                        {
                            global::haxe.io.Bytes d = (c as global::format.png.Chunk_CData).b;
                            this.writeChunk("IDAT", d);
                            break;
                        }


                        case 3:
                        {
                            global::haxe.io.Bytes b2 = (c as global::format.png.Chunk_CPalette).b;
                            this.writeChunk("PLTE", b2);
                            break;
                        }


                        case 4:
                        {
                            global::haxe.io.Bytes data = (c as global::format.png.Chunk_CUnknown).data;
                            string id = (c as global::format.png.Chunk_CUnknown).id;
                            this.writeChunk(id, data);
                            break;
                        }
                        }
                    }
                }
            }
        }
示例#23
0
 public static object __hx_cast <T_c_c>(global::haxe.ds._List.ListNode me)
 {
     return(((me != null)) ? (me.haxe_ds__List_ListNode_cast <T_c_c>()) : default(object));
 }
示例#24
0
 public ListNode(T item, global::haxe.ds._List.ListNode <T> next)
 {
     global::haxe.ds._List.ListNode <object> .__hx_ctor_haxe_ds__List_ListNode <T>(((global::haxe.ds._List.ListNode <T>)(this)), global::haxe.lang.Runtime.genericCast <T>(item), ((global::haxe.ds._List.ListNode <T>)(next)));
 }
示例#25
0
 protected static void __hx_ctor_haxe_ds__List_ListNode <T_c>(global::haxe.ds._List.ListNode <T_c> __hx_this, T_c item, global::haxe.ds._List.ListNode <T_c> next)
 {
     __hx_this.item = item;
     __hx_this.next = next;
 }
示例#26
0
文件: Tools.cs 项目: Yanrishatum/UGif
        public static global::haxe.io.Bytes extractFullRGBA(object data, int frameIndex)
        {
            unchecked {
                object gce                  = null;
                int    frameCaret           = 0;
                global::haxe.io.Bytes bytes = global::haxe.io.Bytes.alloc(((((int)(global::haxe.lang.Runtime.getField_f(global::haxe.lang.Runtime.getField(data, "logicalScreenDescriptor", 2032764644, true), "width", 1247983110, true))) * ((int)(global::haxe.lang.Runtime.getField_f(global::haxe.lang.Runtime.getField(data, "logicalScreenDescriptor", 2032764644, true), "height", 38537191, true)))) * 4));
                {
                    global::haxe.ds._List.ListNode <object> _g_head = ((global::haxe.ds.List <object>)(global::haxe.ds.List <object> .__hx_cast <object>(((global::haxe.ds.List)(global::haxe.lang.Runtime.getField(data, "blocks", 669658758, true)))))).h;
                    while ((_g_head != null))
                    {
                        global::format.gif.Block val = ((global::format.gif.Block)(_g_head.item));
                        _g_head = _g_head.next;
                        global::format.gif.Block block = ((global::format.gif.Block)(val));
                        switch (block._hx_index)
                        {
                        case 0:
                        {
                            object frame = (block as global::format.gif.Block_BFrame).frame;
                            {
                                global::haxe.io.Bytes ct = ((global::haxe.lang.Runtime.toBool(global::haxe.lang.Runtime.getField(frame, "localColorTable", 706588918, true))) ? (((global::haxe.io.Bytes)(global::haxe.lang.Runtime.getField(frame, "colorTable", 793759659, true)))) : (((global::haxe.io.Bytes)(global::haxe.lang.Runtime.getField(data, "globalColorTable", 146652910, true)))));
                                if ((ct == null))
                                {
                                    throw global::haxe.lang.HaxeException.wrap("Frame does not have a color table!");
                                }

                                int transparentIndex         = (((((bool)((gce != null))) && global::haxe.lang.Runtime.toBool(global::haxe.lang.Runtime.getField(gce, "hasTransparentColor", 755457067, true)))) ? ((((int)(global::haxe.lang.Runtime.getField_f(gce, "transparentIndex", 772773472, true))) * ((int)(3)))) : (-1));
                                global::haxe.io.Bytes pixels = ((global::haxe.io.Bytes)(global::haxe.lang.Runtime.getField(frame, "pixels", 212463405, true)));
                                int x          = 0;
                                int writeCaret = ((((((int)(global::haxe.lang.Runtime.getField_f(frame, "y", 121, true))) * ((int)(global::haxe.lang.Runtime.getField_f(global::haxe.lang.Runtime.getField(data, "logicalScreenDescriptor", 2032764644, true), "width", 1247983110, true)))) + ((int)(global::haxe.lang.Runtime.getField_f(frame, "x", 120, true))))) * 4);
                                int lineSkip   = ((((((int)(global::haxe.lang.Runtime.getField_f(global::haxe.lang.Runtime.getField(data, "logicalScreenDescriptor", 2032764644, true), "width", 1247983110, true))) - ((int)(global::haxe.lang.Runtime.getField_f(frame, "width", 1247983110, true))))) * 4) + 4);
                                global::format.gif.DisposalMethod disposalMethod = ((((frameCaret != frameIndex) && (gce != null))) ? (((global::format.gif.DisposalMethod)(global::haxe.lang.Runtime.getField(gce, "disposalMethod", 701242674, true)))) : (global::format.gif.DisposalMethod.NO_ACTION));
                                switch (disposalMethod._hx_index)
                                {
                                case 2:
                                {
                                    int _g1 = 0;
                                    int _g  = pixels.length;
                                    while ((_g1 < _g))
                                    {
                                        int i = _g1++;
                                        bytes.b[writeCaret]       = ((byte)(0));
                                        bytes.b[(writeCaret + 1)] = ((byte)(0));
                                        bytes.b[(writeCaret + 2)] = ((byte)(0));
                                        bytes.b[(writeCaret + 3)] = ((byte)(0));
                                        if ((++x == ((int)(global::haxe.lang.Runtime.getField_f(frame, "width", 1247983110, true)))))
                                        {
                                            x           = 0;
                                            writeCaret += lineSkip;
                                        }
                                        else
                                        {
                                            writeCaret += 4;
                                        }
                                    }

                                    break;
                                }


                                case 3:
                                {
                                    break;
                                }


                                default:
                                {
                                    int _g11 = 0;
                                    int _g2  = pixels.length;
                                    while ((_g11 < _g2))
                                    {
                                        int i1    = _g11++;
                                        int index = (((int)(pixels.b[i1])) * 3);
                                        if ((transparentIndex != index))
                                        {
                                            bytes.b[writeCaret]       = ((byte)(((int)(ct.b[index]))));
                                            bytes.b[(writeCaret + 1)] = ((byte)(((int)(ct.b[(index + 1)]))));
                                            bytes.b[(writeCaret + 2)] = ((byte)(((int)(ct.b[(index + 2)]))));
                                            bytes.b[(writeCaret + 3)] = ((byte)(255));
                                        }

                                        if ((++x == ((int)(global::haxe.lang.Runtime.getField_f(frame, "width", 1247983110, true)))))
                                        {
                                            x           = 0;
                                            writeCaret += lineSkip;
                                        }
                                        else
                                        {
                                            writeCaret += 4;
                                        }
                                    }

                                    break;
                                }
                                }

                                if ((frameCaret == frameIndex))
                                {
                                    return(bytes);
                                }

                                ++frameCaret;
                                gce = null;
                            }

                            break;
                        }


                        case 1:
                        {
                            global::format.gif.Extension ext = (block as global::format.gif.Block_BExtension).extension;
                            if ((ext._hx_index == 0))
                            {
                                object g = (ext as global::format.gif.Extension_EGraphicControl).gce;
                                gce = g;
                            }

                            break;
                        }


                        default:
                        {
                            break;
                        }
                        }
                    }
                }

                return(bytes);
            }
        }
示例#27
0
 protected static void __hx_ctor_haxe_ds__List_ListIterator(global::haxe.ds._List.ListIterator __hx_this, global::haxe.ds._List.ListNode head)
 {
                 #line 281 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
     __hx_this.head = head;
 }
示例#28
0
 public ListIterator(global::haxe.ds._List.ListNode head)
 {
                 #line 280 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
     global::haxe.ds._List.ListIterator.__hx_ctor_haxe_ds__List_ListIterator(((global::haxe.ds._List.ListIterator)(this)), ((global::haxe.ds._List.ListNode)(head)));
 }
示例#29
0
 public ListNode(object item, global::haxe.ds._List.ListNode next)
 {
                 #line 266 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
     global::haxe.ds._List.ListNode.__hx_ctor_haxe_ds__List_ListNode(((global::haxe.ds._List.ListNode)(this)), ((object)(item)), ((global::haxe.ds._List.ListNode)(next)));
 }
示例#30
0
 protected static void __hx_ctor_haxe_ds__List_ListNode(global::haxe.ds._List.ListNode __hx_this, object item, global::haxe.ds._List.ListNode next)
 {
                 #line 267 "C:\\HaxeToolkit\\haxe\\std\\haxe\\ds\\List.hx"
     __hx_this.item = item;
     __hx_this.next = next;
 }