Panda3D
Public Member Functions | Public Attributes | Static Public Attributes | List of all members
DistributedCartesianGrid Class Reference
Inheritance diagram for DistributedCartesianGrid:
DistributedNode CartesianGridBase DistributedObject DistributedObjectBase DirectObject

Public Member Functions

def __init__ (self, cr)
 
def addObjectToGrid (self, av)
 
def clearWorldContext (self, event=None)
 
def delete (self)
 
def disable (self)
 
def generate (self)
 
def getCenterPos (self)
 
def handleAvatarZoneChange (self, av, zoneId)
 
def handleChildArrive (self, child, zoneId)
 
def handleChildArriveZone (self, child, zoneId)
 
def handleChildLeave (self, child, zoneId)
 
def initializeGridLines (self)
 Visualization Tools. More...
 
def isGridParent (self)
 
def labelCells (self)
 
def markCells (self)
 
def processVisibility (self, task)
 
def removeObjectFromGrid (self, av)
 
def setCellWidth (self, width)
 
def setParentingRules (self, style, rule)
 
def setWorldContext (self, worldContext)
 
def startProcessVisibility (self, avatar)
 
def stopProcessVisibility (self, clearAll=False, event=None)
 
def turnOff (self)
 
def turnOn (self, av=None)
 
def unmarkCells (self)
 
def updateGrid (self)
 
def visualizeGrid (self)
 
- Public Member Functions inherited from DistributedNode
def __cmp__ (self, other)
 
def b_setParent (self, parentToken)
 setParent ### More...
 
def d_setH (self, h)
 
def d_setHpr (self, h, p, r)
 
def d_setP (self, p)
 
def d_setParent (self, parentToken)
 
def d_setPos (self, x, y, z)
 
def d_setPosHpr (self, x, y, z, h, p, r)
 
def d_setR (self, r)
 
def d_setX (self, x)
 set pos and hpr functions ####### More...
 
def d_setXY (self, x, y)
 
def d_setXYH (self, x, y, h)
 
def d_setXYZH (self, x, y, z, h)
 
def d_setXZ (self, x, z)
 
def d_setY (self, y)
 
def d_setZ (self, z)
 
def do_setParent (self, parentToken)
 
def setLocation (self, parentId, zoneId, teleport=0)
 
def setParent (self, parentToken)
 
def setParentStr (self, parentTokenStr)
 
def setXY (self, x, y)
 
def setXYH (self, x, y, h)
 
def setXYZH (self, x, y, z, h)
 
def setXZ (self, x, z)
 
- Public Member Functions inherited from DistributedObject
def addInterest (self, zoneId, note="", event=None)
 
def announceGenerate (self)
 
def b_setLocation (self, parentId, zoneId)
 
def d_setLocation (self, parentId, zoneId)
 
def deleteOrDelay (self)
 
def disableAndAnnounce (self)
 
def disableAnnounceAndDelete (self)
 
def doCallbackContext (self, context, args)
 
def doneBarrier (self, name=None)
 
def execCommand (self, string, mwMgrId, avId, zoneId)
 
def flushCachedData (self, name)
 
def generateInit (self)
 
def getAutoInterests (self)
 
def getBarrierData (self)
 
def getCacheable (self)
 
def getCachedData (self, name)
 
def getCallback (self, context)
 
def getCallbackArgs (self, context)
 
def getCallbackContext (self, callback, extraArgs=[])
 
def getCurrentContexts (self)
 
def getDelayDeleteCount (self)
 
def getDelayDeleteEvent (self)
 
def getDisableEvent (self)
 
def getDoId (self)
 
def getLocation (self)
 
def getNeverDisable (self)
 
def getParentObj (self)
 
def hasCachedData (self, name)
 
def isDisabled (self)
 
def isGenerated (self)
 
def isLocal (self)
 
def postGenerateMessage (self)
 
def removeInterest (self, handle, event=None)
 
def sendDeleteMsg (self)
 
def sendDisableMsg (self)
 
def sendUpdate (self, fieldName, args=[], sendToId=None)
 
def setBarrierData (self, data)
 
def setCacheable (self, bool)
 
def setCachedData (self, name, data)
 
def setLocation (self, parentId, zoneId)
 
def setNeverDisable (self, bool)
 
def status (self, indent=0)
 
def taskName (self, taskString)
 
def uniqueName (self, idString)
 
def updateAllRequiredFields (self, dclass, di)
 
def updateRequiredFields (self, dclass, di)
 
def updateRequiredOtherFields (self, dclass, di)
 
- Public Member Functions inherited from DistributedObjectBase
def handleChildLeaveZone (self, childObj, zoneId)
 
def handleQueryObjectChildrenLocalDone (self, context)
 
def hasParentingRules (self)
 
- Public Member Functions inherited from DirectObject
def __init__ (self)
 
def accept (self, event, method, extraArgs=[])
 
def acceptOnce (self, event, method, extraArgs=[])
 
def addTask (self, *args, **kwargs)
 
def detectLeaks (self)
 
def doMethodLater (self, *args, **kwargs)
 
def getAllAccepting (self)
 
def ignore (self, event)
 
def ignoreAll (self)
 
def isAccepting (self, event)
 
def isIgnoring (self, event)
 
def removeAllTasks (self)
 
def removeTask (self, taskOrName)
 
- Public Member Functions inherited from CartesianGridBase
def getConcentricZones (self, zoneId, radius)
 
def getGridSizeFromSphere (self, sphereRadius, spherePos, cellWidth, gridRadius)
 
def getGridSizeFromSphereRadius (self, sphereRadius, cellWidth, gridRadius)
 
def getZoneCellOrigin (self, zoneId)
 
def getZoneCellOriginCenter (self, zoneId)
 
def getZoneFromXYZ (self, pos, wantRowAndCol=False)
 
def isValidZone (self, zoneId)
 

Public Attributes

 cellLabelParent
 
 cellMarkers
 
 cellWidth
 
 centerLines
 
 centerPos
 
 gridColor
 
 gridSize
 
 gridVisContext
 
 haveGridLines
 
 lines
 
 majorLines
 
 markerParent
 
 minorLines
 
 startingZone
 
 style
 
 viewingRadius
 
 visAvatar
 
 visDirty
 
 visZone
 
- Public Attributes inherited from DistributedNode
 DistributedNode_deleted
 
 DistributedNode_initialized
 
 gotStringParentToken
 
 gridParent
 
- Public Attributes inherited from DistributedObject
 activeState
 
 autoInterests
 
 cacheable
 
 cr
 
 dclass
 
 destroyDoStackTrace
 
 DistributedObject_deleted
 
 DistributedObject_initialized
 
 neverDisable
 
 parentId
 
 zoneId
 
- Public Attributes inherited from DistributedObjectBase
 cr
 
 parentId
 
 zoneId
 
- Public Attributes inherited from CartesianGridBase
 style
 

Static Public Attributes

 notify = directNotify.newCategory("DistributedCartesianGrid")
 
string RuleSeparator = ":"
 
 VisualizeGrid = ConfigVariableBool("visualize-cartesian-grid", False)
 
- Static Public Attributes inherited from DistributedObject
int neverDisable = 0
 
 notify = directNotify.newCategory("DistributedObject")
 
- Static Public Attributes inherited from DistributedObjectBase
 notify = directNotify.newCategory("DistributedObjectBase")
 
- Static Public Attributes inherited from DirectObject
def accept_once = acceptOnce
 
def add_task = addTask
 
def detect_leaks = detectLeaks
 
def do_method_later = doMethodLater
 
def get_all_accepting = getAllAccepting
 
def ignore_all = ignoreAll
 
def is_accepting = isAccepting
 
def is_ignoring = isIgnoring
 
def remove_all_tasks = removeAllTasks
 
def remove_task = removeTask
 

Constructor & Destructor Documentation

◆ __init__()

def __init__ (   self,
  cr 
)

Reimplemented from DistributedNode.

Member Function Documentation

◆ addObjectToGrid()

def addObjectToGrid (   self,
  av 
)

◆ clearWorldContext()

def clearWorldContext (   self,
  event = None 
)

◆ delete()

def delete (   self)
Inheritors should redefine this to take appropriate action on delete

Reimplemented from DistributedNode.

◆ disable()

def disable (   self)
Inheritors should redefine this to take appropriate action on disable

Reimplemented from DistributedNode.

◆ generate()

def generate (   self)
Inheritors should redefine this to take appropriate action on generate

Reimplemented from DistributedNode.

◆ getCenterPos()

def getCenterPos (   self)

◆ handleAvatarZoneChange()

def handleAvatarZoneChange (   self,
  av,
  zoneId 
)

◆ handleChildArrive()

def handleChildArrive (   self,
  childObj,
  zoneId 
)
A new child has just setLocation beneath us.  Give us a
chance to run code when a new child sets location to us. For
example, we may want to scene graph reparent the child to
some subnode we own.

Reimplemented from DistributedObjectBase.

◆ handleChildArriveZone()

def handleChildArriveZone (   self,
  childObj,
  zoneId 
)
A child has just changed zones beneath us with setLocation.
Give us a chance to run code when an existing child sets
location to us. For example, we may want to scene graph
reparent the child to some subnode we own.

Reimplemented from DistributedObjectBase.

◆ handleChildLeave()

def handleChildLeave (   self,
  childObj,
  zoneId 
)
A child is about to setLocation away from us.  Give us a
chance to run code just before a child sets location away from us.

Reimplemented from DistributedObjectBase.

◆ initializeGridLines()

def initializeGridLines (   self)

Visualization Tools.

◆ isGridParent()

def isGridParent (   self)

Reimplemented from DistributedObject.

◆ labelCells()

def labelCells (   self)

◆ markCells()

def markCells (   self)

◆ processVisibility()

def processVisibility (   self,
  task 
)

◆ removeObjectFromGrid()

def removeObjectFromGrid (   self,
  av 
)

◆ setCellWidth()

def setCellWidth (   self,
  width 
)

◆ setParentingRules()

def setParentingRules (   self,
  style,
  rule 
)

◆ setWorldContext()

def setWorldContext (   self,
  worldContext 
)

◆ startProcessVisibility()

def startProcessVisibility (   self,
  avatar 
)

◆ stopProcessVisibility()

def stopProcessVisibility (   self,
  clearAll = False,
  event = None 
)

◆ turnOff()

def turnOff (   self)

◆ turnOn()

def turnOn (   self,
  av = None 
)

◆ unmarkCells()

def unmarkCells (   self)

◆ updateGrid()

def updateGrid (   self)

◆ visualizeGrid()

def visualizeGrid (   self)

Member Data Documentation

◆ cellLabelParent

cellLabelParent

◆ cellMarkers

cellMarkers

◆ cellWidth

cellWidth

◆ centerLines

centerLines

◆ centerPos

centerPos

◆ gridColor

gridColor

◆ gridSize

gridSize

◆ gridVisContext

gridVisContext

◆ haveGridLines

haveGridLines

◆ lines

lines

◆ majorLines

majorLines

◆ markerParent

markerParent

◆ minorLines

minorLines

◆ notify

notify = directNotify.newCategory("DistributedCartesianGrid")
static

◆ RuleSeparator

string RuleSeparator = ":"
static

◆ startingZone

startingZone

◆ style

style

◆ viewingRadius

viewingRadius

◆ visAvatar

visAvatar

◆ visDirty

visDirty

◆ VisualizeGrid

VisualizeGrid = ConfigVariableBool("visualize-cartesian-grid", False)
static

◆ visZone

visZone