Panda3D

- Main Page
- Packages
- Classes

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions

# DCAtomicField Class Reference

Inheritance diagram for DCAtomicField:

List of all members.

## Public Member Functions
DCParameter | getElement (int n)
| Returns the parameter object describing the nth element.
string | getElementDefault (int n)
| Returns the pre-formatted default value associated with the nth element of the field.
int | getElementDivisor (int n)
| Returns the divisor associated with the nth element of the field.
string | getElementName (int n)
| Returns the name of the nth element of the field.
DCSubatomicType | getElementType (int n)
| Returns the numeric type of the nth element of the field.
int | getNumElements ()
| Returns the number of elements (parameters) of the atomic field.
bool | hasElementDefault (int n)
| Returns true if the nth element of the field has a default value specified, false otherwise.

## Member Function Documentation

DCParameter getElement | ( | int | n | ) |

Returns the parameter object describing the nth element.

string getElementDefault | ( | int | n | ) |

Returns the pre-formatted default value associated with the nth element of the field.

This is only valid if has_element_default() returns true, in which case this string represents the bytes that should be assigned to the field as a default value.

If the element is an array-type element, the returned value will include the two-byte length preceding the array data.

This is deprecated; use get_element() instead.

int getElementDivisor | ( | int | n | ) |

Returns the divisor associated with the nth element of the field.

This implements an implicit fixed-point system; floating-point values are to be multiplied by this value before encoding into a packet, and divided by this number after decoding.

This method is deprecated; use get_element()->get_divisor() instead.

string getElementName | ( | int | n | ) |

Returns the name of the nth element of the field.

This name is strictly for documentary purposes; it does not generally affect operation. If a name is not specified, this will be the empty string.

This method is deprecated; use get_element()->get_name() instead.

DCSubatomicType getElementType | ( | int | n | ) |

Returns the numeric type of the nth element of the field.

This method is deprecated; use get_element() instead.

int getNumElements | ( |  | ) |

Returns the number of elements (parameters) of the atomic field.

bool hasElementDefault | ( | int | n | ) |

Returns true if the nth element of the field has a default value specified, false otherwise.

This is deprecated; use get_element() instead.

All Classes Namespaces Functions Variables Enumerations Enumerator Properties