glo-sphere

Name

glo-sphere -- 

Synopsis


#include <ogltk/glo_sphere.h>


#define     GLO_SPHERE_H
struct      glo_sphere;
struct      glo_sphere_class;
GLobject*   glo_sphere_new                  (gdouble radius,
                                             gint slices,
                                             gint stacks);
gboolean    glo_sphere_set_radius           (glo_sphere *sphere,
                                             gdouble radius);
gboolean    glo_sphere_set_slices           (glo_sphere *sphere,
                                             gint slices);
gboolean    glo_sphere_set_stacks           (glo_sphere *sphere,
                                             gint stacks);

Description

Details

GLO_SPHERE_H

#define GLO_SPHERE_H


struct glo_sphere

struct glo_sphere {

    GLobject             parent_instance;
    
    gdouble              radius;
    gint                 slices;
    gint                 stacks;                                           
};


struct glo_sphere_class

struct glo_sphere_class {

  GLobject_class        parent_class;
};


glo_sphere_new ()

GLobject*   glo_sphere_new                  (gdouble radius,
                                             gint slices,
                                             gint stacks);

Create an instance of a 3D sphere object.

radius :

Radius.

slices :

Slices.

stacks :

Stacks.

Returns :

Instance of a 3D sphere as type GLobject.


glo_sphere_set_radius ()

gboolean    glo_sphere_set_radius           (glo_sphere *sphere,
                                             gdouble radius);

Set the radius of the sphere

sphere :

Ogltk Sphere object

radius :

Radius.

Returns :

TRUE if successful


glo_sphere_set_slices ()

gboolean    glo_sphere_set_slices           (glo_sphere *sphere,
                                             gint slices);

Set the number of slices of the sphere on the Z-Axis

sphere :

Ogltk Sphere object

slices :

Slices in Sphere.

Returns :

TRUE if successful


glo_sphere_set_stacks ()

gboolean    glo_sphere_set_stacks           (glo_sphere *sphere,
                                             gint stacks);

Set the number of stacks of the sphere on the Z-Axis

sphere :

Ogltk Sphere object

stacks :

Stacks in Sphere.

Returns :

TRUE if successful