parameters: (sphereD, id='cgo', extend=1)
return_statement: return 1
docstring: create a sphere
   
      Arguments:
        sphereD: a series of (pos,rad,color,transparent,transparency) tuples
        id: (OPTIONAL) the name of the object to be created
        extend: (OPTIONAL) if this is nonzero, the object will be cleared
          before adding the new sphere.  Otherwise the sphere is appended
          to the ojbect
docstring_summary: create a sphere
   
      Arguments:
        sphereD: a series of (pos,rad,color,transparent,transparency) tuples
        id: (OPTIONAL) the name of the object to be created
        extend: (OPTIONAL) if this is nonzero, the object will be cleared
          before adding the new sphere.  Otherwise the sphere is appended
          to the ojbect
docstring_tokens: create a sphere Arguments : sphereD : a series of ( pos rad color transparent transparency ) tuples id : ( OPTIONAL ) the name of the object to be created extend : ( OPTIONAL ) if this is nonzero the object will be cleared before adding the new sphere . Otherwise the sphere is appended to the ojbect
function: def rpcSpheres(sphereD, id='cgo', extend=1):
    """ create a sphere
   
      Arguments:
        sphereD: a series of (pos,rad,color,transparent,transparency) tuples
        id: (OPTIONAL) the name of the object to be created
        extend: (OPTIONAL) if this is nonzero, the object will be cleared
          before adding the new sphere.  Otherwise the sphere is appended
          to the ojbect
    """
    if extend:
      obj = cgoDict.get(id, [])
    else:
      obj = []
    for pos, rad, color, transparent, transparency in sphereD:
      r, g, b = color
      x, y, z = pos
      if not transparent:
        o = []
      else:
        o = [cgo.ALPHA, 1 - transparency]
      o.extend([cgo.COLOR, r, g, b, cgo.SPHERE, x, y, z, rad])
      obj.extend(o)
    cgoDict[id] = obj
    cmd.load_cgo(obj, id, 1)
    return 1
function_tokens: def rpcSpheres ( sphereD , id = 'cgo' , extend = 1 ) : if extend : obj = cgoDict . get ( id , [ ] ) else : obj = [ ] for pos , rad , color , transparent , transparency in sphereD : r , g , b = color x , y , z = pos if not transparent : o = [ ] else : o = [ cgo . ALPHA , 1 - transparency ] o . extend ( [ cgo . COLOR , r , g , b , cgo . SPHERE , x , y , z , rad ] ) obj . extend ( o ) cgoDict [ id ] = obj cmd . load_cgo ( obj , id , 1 ) return 1