Main Page - Header
Author: The Inti Development Team

Reference Manual

Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members

# pixbuf-animation.h

Go to the documentation of this file.

    00001 /*  Inti: Integrated Foundation Classes
    00002  *  Copyright (C) 2003 The Inti Development Team.
    00003  *
    00004  *  This program is free software; you can redistribute it and/or modify
    00005  *  it under the terms of the GNU General Public License as published by
    00006  *  the Free Software Foundation; either version 2 of the License, or
    00007  *  (at your option) any later version.
    00008  *
    00009  *  This program is distributed in the hope that it will be useful,
    00010  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
    00011  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    00012  *  GNU Library General Public License for more details.
    00013  *
    00014  *  You should have received a copy of the GNU Library General Public License
    00015  *  along with this program; if not, write to the Free Software
    00016  *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
    00017  */
    00018
    00023
    00024 #ifndef INTI_GDK_PIXBUF_ANIMATION_H
    00025 #define INTI_GDK_PIXBUF_ANIMATION_H
    00026
    00027 #ifndef INTI_G_OBJECT_H
    00028 #include <inti/glib/object.h>
    00029 #endif
    00030
    00031 #ifndef GDK_PIXBUF_H
    00032 #include <gdk-pixbuf/gdk-pixbuf.h>
    00033 #endif
    00034
    00035 namespace Inti {
    00036
    00037 namespace G {
    00038 class Error;
    00039 }
    00040
    00041 namespace Gdk {
    00042
    00043 class Pixbuf;
    00044
    00050
    00051 class PixbufAnimationIter : public G::Object
    00052 {
    00053         friend class G::Object;
    00054
    00055         PixbufAnimationIter(const PixbufAnimationIter&);
    00056         PixbufAnimationIter& operator=(const PixbufAnimationIter&);
    00057
    00058 protected:
    00061
    00062         explicit PixbufAnimationIter(GdkPixbufAnimationIter *iter, bool reference = true);
    00069
    00071
    00072 public:
    00075
    00076         virtual ~PixbufAnimationIter();
    00078
    00082
    00083         GdkPixbufAnimationIter* gdk_pixbuf_animation_iter() const { return (GdkPixbufAnimationIter*)instance; }
    00085
    00086         operator GdkPixbufAnimationIter* () const;
    00088
    00089         int get_delay_time() const;
    00096
    00097         Pixbuf* get_pixbuf() const;
    00107
    00108         bool on_currently_loading_frame() const;
    00116
    00120
    00121         bool advance(const GTimeVal *current_time = 0);
    00139
    00141 };
    00142
    00153
    00154 class PixbufAnimation : public G::Object
    00155 {
    00156         friend class G::Object;
    00157
    00158         PixbufAnimation(const PixbufAnimation&);
    00159         PixbufAnimation& operator=(const PixbufAnimation&);
    00160
    00161 protected:
    00164
    00165         explicit PixbufAnimation(GdkPixbufAnimation *pixbuf_animation, bool reference = true);
    00172
    00174
    00175 public:
    00178
    00179         PixbufAnimation(const String& filename, G::Error *error);
    00191
    00192         virtual ~PixbufAnimation();
    00194
    00198
    00199         GdkPixbufAnimation* gdk_pixbuf_animation() const { return (GdkPixbufAnimation*)instance; }
    00201
    00202         operator GdkPixbufAnimation* () const;
    00204
    00205         int get_width() const;
    00207
    00208         int get_height() const;
    00210
    00211         bool is_static_image() const;
    00217
    00218         Pixbuf* get_static_image() const;
    00227
    00228         Pointer<PixbufAnimationIter> get_iter(const GTimeVal *start_time = 0) const;
    00255
    00257 };
    00258
    00259 } // namespace Gdk
    00260
    00261 } // namespace Inti
    00262
    00263 #endif // INTI_GDK_PIXBUF_ANIMATION_H
    00264

Main Page - Footer