DCAtomicField
from panda3d.direct import DCAtomicField
- class DCAtomicField
Bases:
DCField
A single atomic field of a Distributed Class, as read from a .dc file. This defines an interface to the Distributed Class, and is always implemented as a remote procedure method.
Inheritance diagram
- __init__(*args, **kwargs)
- getElement()
C++ Interface: get_element(DCAtomicField self, int n)
- /**
Returns the parameter object describing the nth element.
*/
- getElementDefault()
C++ Interface: get_element_default(DCAtomicField self, int n)
// These five methods are deprecated and will be removed soon.
- /**
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.
@deprecated use get_element() instead.
*/
- getElementDivisor()
C++ Interface: get_element_divisor(DCAtomicField self, 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.
*/
- getElementName()
C++ Interface: get_element_name(DCAtomicField self, 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.
@deprecated use get_element()->get_name() instead.
*/
- getElementType()
C++ Interface: get_element_type(DCAtomicField self, int n)
- /**
Returns the numeric type of the nth element of the field. This method is
deprecated; use get_element() instead.
*/
- getNumElements()
C++ Interface: get_num_elements(DCAtomicField self)
- /**
Returns the number of elements (parameters) of the atomic field.
*/
- get_element()
C++ Interface: get_element(DCAtomicField self, int n)
- /**
Returns the parameter object describing the nth element.
*/
- get_element_default()
C++ Interface: get_element_default(DCAtomicField self, int n)
// These five methods are deprecated and will be removed soon.
- /**
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.
@deprecated use get_element() instead.
*/
- get_element_divisor()
C++ Interface: get_element_divisor(DCAtomicField self, 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.
*/
- get_element_name()
C++ Interface: get_element_name(DCAtomicField self, 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.
@deprecated use get_element()->get_name() instead.
*/
- get_element_type()
C++ Interface: get_element_type(DCAtomicField self, int n)
- /**
Returns the numeric type of the nth element of the field. This method is
deprecated; use get_element() instead.
*/
- get_num_elements()
C++ Interface: get_num_elements(DCAtomicField self)
- /**
Returns the number of elements (parameters) of the atomic field.
*/