mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-30 08:44:19 -04:00
Merge tag 'v1.10.1'
This commit is contained in:
commit
6d927aaa52
@ -62,8 +62,8 @@ depending on whether you are on a 32-bit or 64-bit system, or you can
|
|||||||
[click here](https://github.com/rdb/panda3d-thirdparty) for instructions on
|
[click here](https://github.com/rdb/panda3d-thirdparty) for instructions on
|
||||||
building them from source.
|
building them from source.
|
||||||
|
|
||||||
https://www.panda3d.org/download/panda3d-1.10.0/panda3d-1.10.0-tools-win64.zip
|
https://www.panda3d.org/download/panda3d-1.10.1/panda3d-1.10.1-tools-win64.zip
|
||||||
https://www.panda3d.org/download/panda3d-1.10.0/panda3d-1.10.0-tools-win32.zip
|
https://www.panda3d.org/download/panda3d-1.10.1/panda3d-1.10.1-tools-win32.zip
|
||||||
|
|
||||||
After acquiring these dependencies, you may simply build Panda3D from the
|
After acquiring these dependencies, you may simply build Panda3D from the
|
||||||
command prompt using the following command. (Change `14.1` to `14` if you are
|
command prompt using the following command. (Change `14.1` to `14` if you are
|
||||||
@ -133,7 +133,7 @@ macOS
|
|||||||
-----
|
-----
|
||||||
|
|
||||||
On macOS, you will need to download a set of precompiled thirdparty packages in order to
|
On macOS, you will need to download a set of precompiled thirdparty packages in order to
|
||||||
compile Panda3D, which can be acquired from [here](https://www.panda3d.org/download/panda3d-1.9.4/panda3d-1.9.4-tools-mac.tar.gz).
|
compile Panda3D, which can be acquired from [here](https://www.panda3d.org/download/panda3d-1.10.1/panda3d-1.10.1-tools-mac.tar.gz).
|
||||||
|
|
||||||
After placing the thirdparty directory inside the panda3d source directory,
|
After placing the thirdparty directory inside the panda3d source directory,
|
||||||
you may build Panda3D using a command like the following:
|
you may build Panda3D using a command like the following:
|
||||||
|
@ -106,6 +106,8 @@ set_end_hpr(const LQuaternion &quat) {
|
|||||||
* if either set_end_quat() or set_end_hpr() is also called. This parameter
|
* if either set_end_quat() or set_end_hpr() is also called. This parameter
|
||||||
* is optional; if unspecified, the value will be taken from the node's actual
|
* is optional; if unspecified, the value will be taken from the node's actual
|
||||||
* rotation at the time the lerp is performed.
|
* rotation at the time the lerp is performed.
|
||||||
|
*
|
||||||
|
* The given quaternion needs to be normalized.
|
||||||
*/
|
*/
|
||||||
INLINE void CLerpNodePathInterval::
|
INLINE void CLerpNodePathInterval::
|
||||||
set_start_quat(const LQuaternion &quat) {
|
set_start_quat(const LQuaternion &quat) {
|
||||||
@ -143,6 +145,8 @@ set_end_quat(const LVecBase3 &hpr) {
|
|||||||
* This replaces a previous call to set_end_hpr(). If neither set_end_quat()
|
* This replaces a previous call to set_end_hpr(). If neither set_end_quat()
|
||||||
* nor set_end_hpr() is called, the node's rotation will not be affected by
|
* nor set_end_hpr() is called, the node's rotation will not be affected by
|
||||||
* the lerp.
|
* the lerp.
|
||||||
|
*
|
||||||
|
* The given quaternion needs to be normalized.
|
||||||
*/
|
*/
|
||||||
INLINE void CLerpNodePathInterval::
|
INLINE void CLerpNodePathInterval::
|
||||||
set_end_quat(const LQuaternion &quat) {
|
set_end_quat(const LQuaternion &quat) {
|
||||||
|
@ -174,14 +174,14 @@ priv_step(double t) {
|
|||||||
setup_slerp();
|
setup_slerp();
|
||||||
|
|
||||||
} else if ((_flags & F_bake_in_start) != 0) {
|
} else if ((_flags & F_bake_in_start) != 0) {
|
||||||
set_start_quat(transform->get_quat());
|
set_start_quat(transform->get_norm_quat());
|
||||||
setup_slerp();
|
setup_slerp();
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
if (_prev_d == 1.0) {
|
if (_prev_d == 1.0) {
|
||||||
_start_quat = _end_quat;
|
_start_quat = _end_quat;
|
||||||
} else {
|
} else {
|
||||||
LQuaternion prev_value = transform->get_quat();
|
LQuaternion prev_value = transform->get_norm_quat();
|
||||||
_start_quat = (prev_value - _prev_d * _end_quat) / (1.0 - _prev_d);
|
_start_quat = (prev_value - _prev_d * _end_quat) / (1.0 - _prev_d);
|
||||||
}
|
}
|
||||||
setup_slerp();
|
setup_slerp();
|
||||||
|
@ -19,7 +19,7 @@ class EventManager:
|
|||||||
Create a C++ event queue and handler
|
Create a C++ event queue and handler
|
||||||
"""
|
"""
|
||||||
# Make a notify category for this class (unless there already is one)
|
# Make a notify category for this class (unless there already is one)
|
||||||
if (EventManager.notify == None):
|
if EventManager.notify is None:
|
||||||
EventManager.notify = directNotify.newCategory("EventManager")
|
EventManager.notify = directNotify.newCategory("EventManager")
|
||||||
|
|
||||||
self.eventQueue = eventQueue
|
self.eventQueue = eventQueue
|
||||||
@ -37,8 +37,10 @@ class EventManager:
|
|||||||
processFunc = self.processEventPstats
|
processFunc = self.processEventPstats
|
||||||
else:
|
else:
|
||||||
processFunc = self.processEvent
|
processFunc = self.processEvent
|
||||||
while (not self.eventQueue.isQueueEmpty()):
|
isEmptyFunc = self.eventQueue.isQueueEmpty
|
||||||
processFunc(self.eventQueue.dequeueEvent())
|
dequeueFunc = self.eventQueue.dequeueEvent
|
||||||
|
while not isEmptyFunc():
|
||||||
|
processFunc(dequeueFunc())
|
||||||
|
|
||||||
def eventLoopTask(self, task):
|
def eventLoopTask(self, task):
|
||||||
"""
|
"""
|
||||||
@ -78,13 +80,13 @@ class EventManager:
|
|||||||
# ******** Duplicate any changes in processEventPstats *********
|
# ******** Duplicate any changes in processEventPstats *********
|
||||||
# **************************************************************
|
# **************************************************************
|
||||||
# Get the event name
|
# Get the event name
|
||||||
eventName = event.getName()
|
eventName = event.name
|
||||||
if eventName:
|
if eventName:
|
||||||
paramList = []
|
paramList = []
|
||||||
for i in range(event.getNumParameters()):
|
for eventParameter in event.parameters:
|
||||||
eventParameter = event.getParameter(i)
|
|
||||||
eventParameterData = self.parseEventParameter(eventParameter)
|
eventParameterData = self.parseEventParameter(eventParameter)
|
||||||
paramList.append(eventParameterData)
|
paramList.append(eventParameterData)
|
||||||
|
|
||||||
# Do not print the new frame debug, it is too noisy!
|
# Do not print the new frame debug, it is too noisy!
|
||||||
if (EventManager.notify.getDebug() and eventName != 'NewFrame'):
|
if (EventManager.notify.getDebug() and eventName != 'NewFrame'):
|
||||||
EventManager.notify.debug('received C++ event named: ' + eventName +
|
EventManager.notify.debug('received C++ event named: ' + eventName +
|
||||||
@ -94,13 +96,12 @@ class EventManager:
|
|||||||
# **************************************************************
|
# **************************************************************
|
||||||
# Send the event, we used to send it with the event
|
# Send the event, we used to send it with the event
|
||||||
# name as a parameter, but now you can use extraArgs for that
|
# name as a parameter, but now you can use extraArgs for that
|
||||||
if paramList:
|
|
||||||
messenger.send(eventName, paramList)
|
messenger.send(eventName, paramList)
|
||||||
else:
|
|
||||||
messenger.send(eventName)
|
|
||||||
# Also send the event down into C++ land
|
# Also send the event down into C++ land
|
||||||
if self.eventHandler:
|
handler = self.eventHandler
|
||||||
self.eventHandler.dispatchEvent(event)
|
if handler:
|
||||||
|
handler.dispatchEvent(event)
|
||||||
|
|
||||||
else:
|
else:
|
||||||
# An unnamed event from C++ is probably a bad thing
|
# An unnamed event from C++ is probably a bad thing
|
||||||
@ -115,13 +116,13 @@ class EventManager:
|
|||||||
# ******** Duplicate any changes in processEvent *********
|
# ******** Duplicate any changes in processEvent *********
|
||||||
# ********************************************************
|
# ********************************************************
|
||||||
# Get the event name
|
# Get the event name
|
||||||
eventName = event.getName()
|
eventName = event.name
|
||||||
if eventName:
|
if eventName:
|
||||||
paramList = []
|
paramList = []
|
||||||
for i in range(event.getNumParameters()):
|
for eventParameter in event.parameters:
|
||||||
eventParameter = event.getParameter(i)
|
|
||||||
eventParameterData = self.parseEventParameter(eventParameter)
|
eventParameterData = self.parseEventParameter(eventParameter)
|
||||||
paramList.append(eventParameterData)
|
paramList.append(eventParameterData)
|
||||||
|
|
||||||
# Do not print the new frame debug, it is too noisy!
|
# Do not print the new frame debug, it is too noisy!
|
||||||
if (EventManager.notify.getDebug() and eventName != 'NewFrame'):
|
if (EventManager.notify.getDebug() and eventName != 'NewFrame'):
|
||||||
EventManager.notify.debug('received C++ event named: ' + eventName +
|
EventManager.notify.debug('received C++ event named: ' + eventName +
|
||||||
@ -131,7 +132,6 @@ class EventManager:
|
|||||||
# ********************************************************
|
# ********************************************************
|
||||||
# ******** Duplicate any changes in processEvent *********
|
# ******** Duplicate any changes in processEvent *********
|
||||||
# ********************************************************
|
# ********************************************************
|
||||||
if self._wantPstats:
|
|
||||||
name = eventName
|
name = eventName
|
||||||
hyphen = name.find('-')
|
hyphen = name.find('-')
|
||||||
if hyphen >= 0:
|
if hyphen >= 0:
|
||||||
@ -142,34 +142,26 @@ class EventManager:
|
|||||||
cppPstatCollector = PStatCollector(
|
cppPstatCollector = PStatCollector(
|
||||||
'App:Show code:eventManager:' + name + ':C++')
|
'App:Show code:eventManager:' + name + ':C++')
|
||||||
|
|
||||||
if paramList:
|
|
||||||
messenger.send(eventName, paramList)
|
messenger.send(eventName, paramList)
|
||||||
else:
|
|
||||||
messenger.send(eventName)
|
|
||||||
# Also send the event down into C++ land
|
|
||||||
if self.eventHandler:
|
|
||||||
if self._wantPstats:
|
|
||||||
cppPstatCollector.start()
|
|
||||||
self.eventHandler.dispatchEvent(event)
|
|
||||||
# ********************************************************
|
|
||||||
# ******** Duplicate any changes in processEvent *********
|
|
||||||
# ********************************************************
|
|
||||||
|
|
||||||
if self._wantPstats:
|
# Also send the event down into C++ land
|
||||||
if self.eventHandler:
|
handler = self.eventHandler
|
||||||
|
if handler:
|
||||||
|
cppPstatCollector.start()
|
||||||
|
handler.dispatchEvent(event)
|
||||||
cppPstatCollector.stop()
|
cppPstatCollector.stop()
|
||||||
|
|
||||||
pstatCollector.stop()
|
pstatCollector.stop()
|
||||||
|
|
||||||
else:
|
else:
|
||||||
# An unnamed event from C++ is probably a bad thing
|
# An unnamed event from C++ is probably a bad thing
|
||||||
EventManager.notify.warning('unnamed event in processEvent')
|
EventManager.notify.warning('unnamed event in processEvent')
|
||||||
|
|
||||||
|
|
||||||
def restart(self):
|
def restart(self):
|
||||||
if self.eventQueue == None:
|
if self.eventQueue is None:
|
||||||
self.eventQueue = EventQueue.getGlobalEventQueue()
|
self.eventQueue = EventQueue.getGlobalEventQueue()
|
||||||
|
|
||||||
if self.eventHandler == None:
|
if self.eventHandler is None:
|
||||||
if self.eventQueue == EventQueue.getGlobalEventQueue():
|
if self.eventQueue == EventQueue.getGlobalEventQueue():
|
||||||
# If we are using the global event queue, then we also
|
# If we are using the global event queue, then we also
|
||||||
# want to use the global event handler.
|
# want to use the global event handler.
|
||||||
|
@ -4,6 +4,7 @@ This is a bugfix release intended to fix several issues in 1.10.0.
|
|||||||
|
|
||||||
* Fix crashes when gamepad is plugged in on 32-bit Windows
|
* Fix crashes when gamepad is plugged in on 32-bit Windows
|
||||||
* Fix deploy-ng error regarding 'exist_ok' on Python 2
|
* Fix deploy-ng error regarding 'exist_ok' on Python 2
|
||||||
|
* Fix Linux install from pip not working with some mesa drivers
|
||||||
* Fix compatibility issues with upcoming Python 3.8
|
* Fix compatibility issues with upcoming Python 3.8
|
||||||
* Fix regression with Audio3DManager.setSoundVelocityAuto()
|
* Fix regression with Audio3DManager.setSoundVelocityAuto()
|
||||||
* Fix issues when awaiting loader.loadModel in Python 3.7
|
* Fix issues when awaiting loader.loadModel in Python 3.7
|
||||||
@ -13,6 +14,7 @@ This is a bugfix release intended to fix several issues in 1.10.0.
|
|||||||
* Depth buffer now defaults to 24-bit on macOS (fixes flickering)
|
* Depth buffer now defaults to 24-bit on macOS (fixes flickering)
|
||||||
* Fix no devices being detected on Windows with threading-model
|
* Fix no devices being detected on Windows with threading-model
|
||||||
* Implement collision tests from Capsule and Box into InvSphere
|
* Implement collision tests from Capsule and Box into InvSphere
|
||||||
|
* Fix odd behavior and occasional crash in QuatInterval
|
||||||
* Fix SpriteAnim error in particle system
|
* Fix SpriteAnim error in particle system
|
||||||
* Fix ShaderGenerator error when using too many shadowing lights
|
* Fix ShaderGenerator error when using too many shadowing lights
|
||||||
* Fix interrogate crash in Python 3 with optional wstring args
|
* Fix interrogate crash in Python 3 with optional wstring args
|
||||||
|
@ -104,7 +104,7 @@ MANYLINUX_LIBS = [
|
|||||||
|
|
||||||
# These are not mentioned in manylinux1 spec but should nonetheless always
|
# These are not mentioned in manylinux1 spec but should nonetheless always
|
||||||
# be excluded.
|
# be excluded.
|
||||||
"linux-vdso.so.1", "linux-gate.so.1", "ld-linux.so.2",
|
"linux-vdso.so.1", "linux-gate.so.1", "ld-linux.so.2", "libdrm.so.2",
|
||||||
]
|
]
|
||||||
|
|
||||||
# Binaries to never scan for dependencies on non-Windows systems.
|
# Binaries to never scan for dependencies on non-Windows systems.
|
||||||
@ -144,6 +144,32 @@ METADATA = {
|
|||||||
"classifiers": GetMetadataValue('classifiers'),
|
"classifiers": GetMetadataValue('classifiers'),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
DESCRIPTION = """
|
||||||
|
The Panda3D free 3D game engine
|
||||||
|
===============================
|
||||||
|
|
||||||
|
Panda3D is a powerful 3D engine written in C++, with a complete set of Python
|
||||||
|
bindings. Unlike other engines, these bindings are automatically generated,
|
||||||
|
meaning that they are always up-to-date and complete: all functions of the
|
||||||
|
engine can be controlled from Python. All major Panda3D applications have been
|
||||||
|
written in Python, this is the intended way of using the engine.
|
||||||
|
|
||||||
|
Panda3D now supports automatic shader generation, which now means you can use
|
||||||
|
normal maps, gloss maps, glow maps, HDR, cartoon shading, and the like without
|
||||||
|
having to write any shaders.
|
||||||
|
|
||||||
|
Panda3D is a modern engine supporting advanced features such as shaders,
|
||||||
|
stencil, and render-to-texture. Panda3D is unusual in that it emphasizes a
|
||||||
|
short learning curve, rapid development, and extreme stability and robustness.
|
||||||
|
Panda3D is free software that runs under Windows, Linux, or macOS.
|
||||||
|
|
||||||
|
The Panda3D team is very concerned with making the engine accessible to new
|
||||||
|
users. We provide a detailed manual, a complete API reference, and a large
|
||||||
|
collection of sample programs to help you get started. We have active forums,
|
||||||
|
with many helpful users, and the developers are regularly online to answer
|
||||||
|
questions.
|
||||||
|
"""
|
||||||
|
|
||||||
PANDA3D_TOOLS_INIT = """import os, sys
|
PANDA3D_TOOLS_INIT = """import os, sys
|
||||||
import panda3d
|
import panda3d
|
||||||
|
|
||||||
@ -544,6 +570,8 @@ def makewheel(version, output_dir, platform=None):
|
|||||||
"Platform: {0}\n".format(platform),
|
"Platform: {0}\n".format(platform),
|
||||||
] + ["Classifier: {0}\n".format(c) for c in METADATA['classifiers']])
|
] + ["Classifier: {0}\n".format(c) for c in METADATA['classifiers']])
|
||||||
|
|
||||||
|
metadata += '\n' + DESCRIPTION.strip() + '\n'
|
||||||
|
|
||||||
# Zip it up and name it the right thing
|
# Zip it up and name it the right thing
|
||||||
whl = WheelFile('panda3d', version, platform)
|
whl = WheelFile('panda3d', version, platform)
|
||||||
whl.lib_path = [libs_dir]
|
whl.lib_path = [libs_dir]
|
||||||
|
@ -58,6 +58,7 @@ ThreadPosixImpl::
|
|||||||
void ThreadPosixImpl::
|
void ThreadPosixImpl::
|
||||||
setup_main_thread() {
|
setup_main_thread() {
|
||||||
_status = S_running;
|
_status = S_running;
|
||||||
|
_thread = pthread_self();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -180,7 +181,7 @@ join() {
|
|||||||
std::string ThreadPosixImpl::
|
std::string ThreadPosixImpl::
|
||||||
get_unique_id() const {
|
get_unique_id() const {
|
||||||
std::ostringstream strm;
|
std::ostringstream strm;
|
||||||
strm << getpid() << "." << _thread;
|
strm << getpid() << "." << (uintptr_t)_thread;
|
||||||
|
|
||||||
return strm.str();
|
return strm.str();
|
||||||
}
|
}
|
||||||
|
@ -34,7 +34,7 @@ PT(XFile) XFile::_standard_templates;
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
XFile::
|
XFile::
|
||||||
XFile(bool keep_names) : XFileNode(this, "") {
|
XFile(bool keep_names) : XFileNode(this) {
|
||||||
_major_version = 3;
|
_major_version = 3;
|
||||||
_minor_version = 2;
|
_minor_version = 2;
|
||||||
_format_type = FT_text;
|
_format_type = FT_text;
|
||||||
|
@ -11,6 +11,16 @@
|
|||||||
* @date 2004-10-03
|
* @date 2004-10-03
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
INLINE XFileNode::
|
||||||
|
XFileNode(XFile *x_file) :
|
||||||
|
Namable(),
|
||||||
|
_x_file(x_file)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
@ -38,6 +38,9 @@ class Filename;
|
|||||||
*/
|
*/
|
||||||
class XFileNode : public TypedObject, public Namable,
|
class XFileNode : public TypedObject, public Namable,
|
||||||
virtual public ReferenceCount {
|
virtual public ReferenceCount {
|
||||||
|
protected:
|
||||||
|
INLINE XFileNode(XFile *x_file);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
XFileNode(XFile *x_file, const std::string &name);
|
XFileNode(XFile *x_file, const std::string &name);
|
||||||
virtual ~XFileNode();
|
virtual ~XFileNode();
|
||||||
|
@ -141,11 +141,14 @@ def drawBody(nodePath, vdata, pos, vecList, radius=1, keepDrawing=True, numVerti
|
|||||||
drawReWriter.addData1f(keepDrawing)
|
drawReWriter.addData1f(keepDrawing)
|
||||||
currAngle += angleSlice
|
currAngle += angleSlice
|
||||||
|
|
||||||
|
if startRow == 0:
|
||||||
|
return
|
||||||
|
|
||||||
drawReader = GeomVertexReader(vdata, "drawFlag")
|
drawReader = GeomVertexReader(vdata, "drawFlag")
|
||||||
drawReader.setRow(startRow - numVertices)
|
drawReader.setRow(startRow - numVertices)
|
||||||
|
|
||||||
# we cant draw quads directly so we use Tristrips
|
# we cant draw quads directly so we use Tristrips
|
||||||
if (startRow != 0) & (drawReader.getData1f() != False):
|
if drawReader.getData1i() != 0:
|
||||||
lines = GeomTristrips(Geom.UHStatic)
|
lines = GeomTristrips(Geom.UHStatic)
|
||||||
half = int(numVertices * 0.5)
|
half = int(numVertices * 0.5)
|
||||||
for i in range(numVertices):
|
for i in range(numVertices):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user