Merge branch 'master' into cmake

This commit is contained in:
Sam Edwards 2018-09-02 16:06:41 -06:00
commit 208ecd6708
182 changed files with 957 additions and 383 deletions

View File

@ -52,7 +52,7 @@ operator = (const DCNumericRange<NUM> &copy) {
* otherwise.
*/
template <class NUM>
bool DCNumericRange<NUM>::
INLINE bool DCNumericRange<NUM>::
is_in_range(Number num) const {
if (_ranges.empty()) {
return true;
@ -106,7 +106,7 @@ get_one_value() const {
*
*/
template <class NUM>
void DCNumericRange<NUM>::
INLINE void DCNumericRange<NUM>::
generate_hash(HashGenerator &hashgen) const {
if (!_ranges.empty()) {
hashgen.add_int(_ranges.size());
@ -124,7 +124,7 @@ generate_hash(HashGenerator &hashgen) const {
*
*/
template <class NUM>
void DCNumericRange<NUM>::
INLINE void DCNumericRange<NUM>::
output(std::ostream &out, Number divisor) const {
if (!_ranges.empty()) {
typename Ranges::const_iterator ri;
@ -144,7 +144,7 @@ output(std::ostream &out, Number divisor) const {
* characters.
*/
template <class NUM>
void DCNumericRange<NUM>::
INLINE void DCNumericRange<NUM>::
output_char(std::ostream &out, Number divisor) const {
if (divisor != 1) {
output(out, divisor);
@ -179,7 +179,7 @@ clear() {
* minmax overlaps an existing minmax.
*/
template <class NUM>
bool DCNumericRange<NUM>::
INLINE bool DCNumericRange<NUM>::
add_range(Number min, Number max) {
// Check for an overlap. This is probably indicative of a typo and should
// be reported.

View File

@ -32,20 +32,20 @@ public:
INLINE DCNumericRange(const DCNumericRange &copy);
INLINE void operator = (const DCNumericRange &copy);
bool is_in_range(Number num) const;
INLINE bool is_in_range(Number num) const;
INLINE void validate(Number num, bool &range_error) const;
INLINE bool has_one_value() const;
INLINE Number get_one_value() const;
void generate_hash(HashGenerator &hashgen) const;
INLINE void generate_hash(HashGenerator &hashgen) const;
void output(std::ostream &out, Number divisor = 1) const;
void output_char(std::ostream &out, Number divisor = 1) const;
INLINE void output(std::ostream &out, Number divisor = 1) const;
INLINE void output_char(std::ostream &out, Number divisor = 1) const;
public:
INLINE void clear();
bool add_range(Number min, Number max);
INLINE bool add_range(Number min, Number max);
INLINE bool is_empty() const;
INLINE int get_num_ranges() const;

View File

@ -15,7 +15,7 @@
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_DIRECT_DEADREC)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_DIRECT_DEADREC)
#error Buildsystem error: BUILDING_DIRECT_DEADREC not defined
#endif

View File

@ -30,7 +30,7 @@
#include "pset.h"
#if !defined(CPPPARSER) && !defined(BUILDING_DIRECT_DIRECTD)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_DIRECT_DIRECTD)
#error Buildsystem error: BUILDING_DIRECT_DIRECTD not defined
#endif

View File

@ -25,8 +25,8 @@ class PyDatagram(Datagram):
STUint64: (Datagram.addUint64, int),
STFloat64: (Datagram.addFloat64, None),
STString: (Datagram.addString, None),
STBlob: (Datagram.addString, None),
STBlob32: (Datagram.addString32, None),
STBlob: (Datagram.addBlob, None),
STBlob32: (Datagram.addBlob32, None),
}
#def addChannel(self, channelId):

View File

@ -23,8 +23,8 @@ class PyDatagramIterator(DatagramIterator):
STUint64: DatagramIterator.getUint64,
STFloat64: DatagramIterator.getFloat64,
STString: DatagramIterator.getString,
STBlob: DatagramIterator.getString,
STBlob32: DatagramIterator.getString32,
STBlob: DatagramIterator.getBlob,
STBlob32: DatagramIterator.getBlob32,
}
getChannel = DatagramIterator.getUint64

View File

@ -14,7 +14,7 @@
#include "config_distributed.h"
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_DIRECT_DISTRIBUTED)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_DIRECT_DISTRIBUTED)
#error Buildsystem error: BUILDING_DIRECT_DISTRIBUTED not defined
#endif

View File

@ -29,7 +29,7 @@
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_DIRECT_INTERVAL)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_DIRECT_INTERVAL)
#error Buildsystem error: BUILDING_DIRECT_INTERVAL not defined
#endif

View File

@ -3,6 +3,7 @@ Palette for Prototyping
"""
from .ProtoPaletteBase import *
import os
class ProtoPalette(ProtoPaletteBase):
def __init__(self):

View File

@ -14,7 +14,7 @@
#include "config_motiontrail.h"
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_DIRECT_MOTIONTRAIL)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_DIRECT_MOTIONTRAIL)
#error Buildsystem error: BUILDING_DIRECT_MOTIONTRAIL not defined
#endif

View File

@ -37,7 +37,7 @@ FILTERKEYS g_StartupFilterKeys = {sizeof(FILTERKEYS), 0};
using std::max;
using std::min;
#if !defined(CPPPARSER) && !defined(BUILDING_DIRECT_SHOWBASE)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_DIRECT_SHOWBASE)
#error Buildsystem error: BUILDING_DIRECT_SHOWBASE not defined
#endif

View File

@ -292,6 +292,10 @@ output_instance(ostream &out, int indent_level, CPPScope *scope,
out << str;
} else if (_flags & F_operator_typecast) {
out << "operator ";
_return_type->output_instance(out, indent_level, scope, complete, "", prename + str);
} else {
if (prename.empty()) {
_return_type->output_instance(out, indent_level, scope, complete,

View File

@ -13,7 +13,7 @@
#include "config_dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_DTOOL_DCONFIG)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_DTOOL_DCONFIG)
#error Buildsystem error: BUILDING_DTOOL_DCONFIG not defined
#endif

View File

@ -30,6 +30,20 @@ struct AtomicAdjust {
#include "atomicAdjustDummyImpl.h"
typedef AtomicAdjustDummyImpl AtomicAdjust;
#elif (defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 7))) || (defined(__clang__) && (__clang_major__ >= 3))
// GCC 4.7 and above has built-in __atomic functions for atomic operations.
// Clang 3.0 and above also supports them.
#include "atomicAdjustGccImpl.h"
typedef AtomicAdjustGccImpl AtomicAdjust;
#if (__GCC_ATOMIC_INT_LOCK_FREE + __GCC_ATOMIC_LONG_LOCK_FREE) > 0
#define HAVE_ATOMIC_COMPARE_AND_EXCHANGE 1
#endif
#if __GCC_ATOMIC_POINTER_LOCK_FREE > 0
#define HAVE_ATOMIC_COMPARE_AND_EXCHANGE_PTR 1
#endif
#elif (defined(__i386__) || defined(_M_IX86)) && !defined(__APPLE__)
// For an i386 architecture, we'll always use the i386 implementation. It
// should be safe for any OS, and it might be a bit faster than any OS-
@ -45,20 +59,6 @@ typedef AtomicAdjustI386Impl AtomicAdjust;
#define HAVE_ATOMIC_COMPARE_AND_EXCHANGE 1
#define HAVE_ATOMIC_COMPARE_AND_EXCHANGE_PTR 1
#elif (defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 7))) || (defined(__clang__) && (__clang_major__ >= 3))
// GCC 4.7 and above has built-in __atomic functions for atomic operations.
// Clang 3.0 and above also supports them.
#include "atomicAdjustGccImpl.h"
typedef AtomicAdjustGccImpl AtomicAdjust;
#if (__GCC_ATOMIC_INT_LOCK_FREE + __GCC_ATOMIC_INT_LOCK_FREE) > 0
#define HAVE_ATOMIC_COMPARE_AND_EXCHANGE 1
#endif
#if __GCC_ATOMIC_POINTER_LOCK_FREE > 0
#define HAVE_ATOMIC_COMPARE_AND_EXCHANGE_PTR 1
#endif
#elif defined(THREAD_WIN32_IMPL)
#include "atomicAdjustWin32Impl.h"

View File

@ -63,6 +63,9 @@
#define DTOOL_PLATFORM "android_i386"
#endif
#elif defined(__aarch64__)
#define DTOOL_PLATFORM "linux_aarch64"
#elif defined(__x86_64)
#define DTOOL_PLATFORM "linux_amd64"

View File

@ -14,7 +14,7 @@
#include "dtoolbase.h"
#include "memoryHook.h"
#if !defined(CPPPARSER) && !defined(BUILDING_DTOOL_DTOOLBASE)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_DTOOL_DTOOLBASE)
#error Buildsystem error: BUILDING_DTOOL_DTOOLBASE not defined
#endif

View File

@ -169,7 +169,7 @@ add_hash(size_t hash, const Key &key) {
#ifdef _DEBUG
// We assume that the sequence is laid out sequentially in memory.
if (key.size() > 0) {
assert(&key[key.size() - 1] - &key[0] == key.size() - 1);
assert(&key[key.size() - 1] - &key[0] == (ptrdiff_t)key.size() - 1);
}
#endif
size_t num_bytes = (key.size() * sizeof(key[0]));

View File

@ -16,7 +16,7 @@
#include "filename.h"
#include "pandaSystem.h"
#if !defined(CPPPARSER) && !defined(BUILDING_DTOOL_DTOOLUTIL)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_DTOOL_DTOOLUTIL)
#error Buildsystem error: BUILDING_DTOOL_DCTOOLUTIL not defined
#endif

View File

@ -789,8 +789,6 @@ InterfaceMakerPythonNative::
*/
void InterfaceMakerPythonNative::
write_prototypes(ostream &out_code, ostream *out_h) {
Functions::iterator fi;
if (out_h != nullptr) {
*out_h << "#include \"py_panda.h\"\n\n";
}
@ -917,7 +915,6 @@ write_prototypes_class_external(ostream &out, Object *obj) {
void InterfaceMakerPythonNative::
write_prototypes_class(ostream &out_code, ostream *out_h, Object *obj) {
std::string ClassName = make_safe_name(obj->_itype.get_scoped_name());
Functions::iterator fi;
out_code << "/**\n";
out_code << " * Forward declarations for top-level class " << ClassName << "\n";
@ -1089,6 +1086,27 @@ write_class_details(ostream &out, Object *obj) {
}
}
// Are there any implicit cast operators that can cast this object to our
// desired pointer?
for (Function *func : obj->_methods) {
for (FunctionRemap *remap : func->_remaps) {
if (remap->_type == FunctionRemap::T_typecast_method &&
is_remap_legal(remap) &&
!remap->_return_type->return_value_needs_management() &&
(remap->_cppfunc->_storage_class & CPPInstance::SC_explicit) == 0 &&
TypeManager::is_pointer(remap->_return_type->get_new_type())) {
CPPType *cast_type = remap->_return_type->get_orig_type();
CPPType *obj_type = TypeManager::unwrap(TypeManager::resolve_type(remap->_return_type->get_new_type()));
string return_expr = "(" + cast_type->get_local_name(&parser) + ")*local_this";
out << " // " << *remap->_cppfunc << "\n";
out << " if (requested_type == Dtool_Ptr_" << make_safe_name(obj_type->get_local_name(&parser)) << ") {\n";
out << " return (void *)(" << remap->_return_type->get_return_expr(return_expr) << ");\n";
out << " }\n";
}
}
}
out << " return nullptr;\n";
out << "}\n\n";
@ -3301,7 +3319,7 @@ write_prototype_for(ostream &out, InterfaceMaker::Function *func) {
*/
void InterfaceMakerPythonNative::
write_prototype_for_name(ostream &out, InterfaceMaker::Function *func, const std::string &function_namename) {
Function::Remaps::const_iterator ri;
// Function::Remaps::const_iterator ri;
// for (ri = func->_remaps.begin(); ri != func->_remaps.end(); ++ri) {
// FunctionRemap *remap = (*ri);

View File

@ -16,7 +16,7 @@
#include "configVariableEnum.h"
#include "pandaFileStreamBuf.h"
#if !defined(CPPPARSER) && !defined(BUILDING_DTOOL_PRC)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_DTOOL_PRC)
#error Buildsystem error: BUILDING_DTOOL_PRC not defined
#endif

View File

@ -5219,7 +5219,7 @@ if (PkgSkip("DIRECT")==0):
#
if (PkgSkip("DIRECT")==0):
OPTS=['DIR:direct/src/dcparser', 'WITHINPANDA', 'BISONPREFIX_dcyy', 'PYTHON']
OPTS=['DIR:direct/src/dcparser', 'BUILDING:DIRECT_DCPARSER', 'WITHINPANDA', 'BISONPREFIX_dcyy', 'PYTHON']
CreateFile(GetOutputDir()+"/include/dcParser.h")
TargetAdd('p3dcparser_dcParser.obj', opts=OPTS, input='dcParser.yxx')
TargetAdd('dcParser.h', input='p3dcparser_dcParser.obj', opts=['DEPENDENCYONLY'])

61
makepanda/test_wheel.py Executable file
View File

@ -0,0 +1,61 @@
#!/usr/bin/env python
"""
Tests a .whl file by installing it and pytest into a virtual environment and
running the test suite.
Requires pip to be installed, as well as 'virtualenv' on Python 2.
"""
import os
import sys
import shutil
import subprocess
import tempfile
from optparse import OptionParser
def test_wheel(wheel, verbose=False):
envdir = tempfile.mkdtemp(prefix="venv-")
print("Setting up virtual environment in {0}".format(envdir))
if sys.version_info >= (3, 0):
subprocess.call([sys.executable, "-m", "venv", "--clear", envdir])
else:
subprocess.call([sys.executable, "-m", "virtualenv", "--clear", envdir])
# Install pytest into the environment, as well as our wheel.
if sys.platform == "win32":
pip = os.path.join(envdir, "Scripts", "pip.exe")
else:
pip = os.path.join(envdir, "bin", "pip")
if subprocess.call([pip, "install", "pytest", wheel]) != 0:
shutil.rmtree(envdir)
sys.exit(1)
# Run the test suite.
if sys.platform == "win32":
python = os.path.join(envdir, "Scripts", "python.exe")
else:
python = os.path.join(envdir, "bin", "python")
test_cmd = [python, "-m", "pytest", "tests"]
if verbose:
test_cmd.append("--verbose")
exit_code = subprocess.call(test_cmd)
shutil.rmtree(envdir)
if exit_code != 0:
sys.exit(exit_code)
if __name__ == "__main__":
parser = OptionParser(usage="%prog [options] file...")
parser.add_option('', '--verbose', dest = 'verbose', help = 'Enable verbose output', action = 'store_true', default = False)
(options, args) = parser.parse_args()
if not args:
parser.print_usage()
sys.exit(1)
for arg in args:
test_wheel(arg, verbose=options.verbose)

View File

@ -14,7 +14,7 @@
#include "config_pstatclient.h"
#endif
#if !defined(CPPPARSER) && !defined(BUILDING_LIBPANDA)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_LIBPANDA)
#error Buildsystem error: BUILDING_LIBPANDA not defined
#endif

View File

@ -86,7 +86,7 @@ PUBLISHED:
virtual bool is_valid() = 0;
// Get a sound:
virtual PT(AudioSound) get_sound(const std::string& file_name, bool positional = false, int mode=SM_heuristic) = 0;
virtual PT(AudioSound) get_sound(const Filename &file_name, bool positional = false, int mode=SM_heuristic) = 0;
virtual PT(AudioSound) get_sound(MovieAudio *source, bool positional = false, int mode=SM_heuristic) = 0;
PT(AudioSound) get_null_sound();
@ -95,7 +95,7 @@ PUBLISHED:
// doesn't break any connection between AudioSounds that have already given
// by get_sound() from this manager. It's only affecting whether the
// AudioManager keeps a copy of the sound in its poolcache.
virtual void uncache_sound(const std::string& file_name) = 0;
virtual void uncache_sound(const Filename &file_name) = 0;
virtual void clear_cache() = 0;
virtual void set_cache_limit(unsigned int count) = 0;
virtual unsigned int get_cache_limit() const = 0;

View File

@ -21,7 +21,7 @@
#include "nullAudioSound.h"
#include "string_utils.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDA_AUDIO)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDA_AUDIO)
#error Buildsystem error: BUILDING_PANDA_AUDIO not defined
#endif

View File

@ -49,7 +49,7 @@ is_valid() {
*
*/
PT(AudioSound) NullAudioManager::
get_sound(const std::string&, bool positional, int mode) {
get_sound(const Filename &, bool positional, int mode) {
return get_null_sound();
}
@ -65,7 +65,7 @@ get_sound(MovieAudio *sound, bool positional, int mode) {
*
*/
void NullAudioManager::
uncache_sound(const std::string&) {
uncache_sound(const Filename &) {
// intentionally blank.
}

View File

@ -29,9 +29,9 @@ public:
virtual bool is_valid();
virtual PT(AudioSound) get_sound(const std::string&, bool positional = false, int mode=SM_heuristic);
virtual PT(AudioSound) get_sound(const Filename &, bool positional = false, int mode=SM_heuristic);
virtual PT(AudioSound) get_sound(MovieAudio *sound, bool positional = false, int mode=SM_heuristic);
virtual void uncache_sound(const std::string&);
virtual void uncache_sound(const Filename &);
virtual void clear_cache();
virtual void set_cache_limit(unsigned int);
virtual unsigned int get_cache_limit() const;

View File

@ -19,7 +19,7 @@
#include "pandaSystem.h"
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_FMOD_AUDIO)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_FMOD_AUDIO)
#error Buildsystem error: BUILDING_FMOD_AUDIO not defined
#endif

View File

@ -22,7 +22,7 @@
#include "pandaSystem.h"
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_MILES_AUDIO)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_MILES_AUDIO)
#error Buildsystem error: BUILDING_MILES_AUDIO not defined
#endif

View File

@ -18,7 +18,7 @@
#include "pandaSystem.h"
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_OPENAL_AUDIO)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_OPENAL_AUDIO)
#error Buildsystem error: BUILDING_OPENAL_AUDIO not defined
#endif

View File

@ -409,7 +409,7 @@ configure_filters(FilterProperties *config) {
* This is what creates a sound instance.
*/
PT(AudioSound) FmodAudioManager::
get_sound(const std::string &file_name, bool positional, int) {
get_sound(const Filename &file_name, bool positional, int) {
ReMutexHolder holder(_lock);
// Needed so People use Panda's Generic UNIX Style Paths for Filename.
// path.to_os_specific() converts it back to the proper OS version later on.
@ -772,7 +772,7 @@ reduce_sounds_playing_to(unsigned int count) {
* NOT USED FOR FMOD-EX!!! Clears a sound out of the sound cache.
*/
void FmodAudioManager::
uncache_sound(const std::string& file_name) {
uncache_sound(const Filename &file_name) {
audio_debug("FmodAudioManager::uncache_sound(\""<<file_name<<"\")");
}

View File

@ -88,7 +88,7 @@ public:
virtual bool is_valid();
virtual PT(AudioSound) get_sound(const std::string&, bool positional = false, int mode=SM_heuristic);
virtual PT(AudioSound) get_sound(const Filename &, bool positional = false, int mode=SM_heuristic);
virtual PT(AudioSound) get_sound(MovieAudio *, bool positional = false, int mode=SM_heuristic);
virtual int get_speaker_setup();
@ -146,7 +146,7 @@ public:
virtual void set_concurrent_sound_limit(unsigned int limit = 0);
virtual unsigned int get_concurrent_sound_limit() const;
virtual void reduce_sounds_playing_to(unsigned int count);
virtual void uncache_sound(const std::string&);
virtual void uncache_sound(const Filename &);
virtual void clear_cache();
virtual void set_cache_limit(unsigned int count);
virtual unsigned int get_cache_limit() const;

View File

@ -122,7 +122,7 @@ is_valid() {
*
*/
PT(AudioSound) MilesAudioManager::
get_sound(const string &file_name, bool, int) {
get_sound(const Filename &file_name, bool, int) {
LightReMutexHolder holder(_lock);
audio_debug("MilesAudioManager::get_sound(file_name=\""<<file_name<<"\")");
@ -218,7 +218,7 @@ get_sound(MovieAudio *sound, bool, int) {
*
*/
void MilesAudioManager::
uncache_sound(const string &file_name) {
uncache_sound(const Filename &file_name) {
audio_debug("MilesAudioManager::uncache_sound(file_name=\""
<<file_name<<"\")");
LightReMutexHolder holder(_lock);

View File

@ -43,9 +43,9 @@ public:
virtual bool is_valid();
virtual PT(AudioSound) get_sound(const std::string &file_name, bool positional = false, int mode=SM_heuristic);
virtual PT(AudioSound) get_sound(const Filename &file_name, bool positional = false, int mode=SM_heuristic);
virtual PT(AudioSound) get_sound(MovieAudio *sound, bool positional = false, int mode=SM_heuristic);
virtual void uncache_sound(const std::string &file_name);
virtual void uncache_sound(const Filename &file_name);
virtual void clear_cache();
virtual void set_cache_limit(unsigned int count);
virtual unsigned int get_cache_limit() const;

View File

@ -489,7 +489,7 @@ get_sound(MovieAudio *sound, bool positional, int mode) {
* This is what creates a sound instance.
*/
PT(AudioSound) OpenALAudioManager::
get_sound(const string &file_name, bool positional, int mode) {
get_sound(const Filename &file_name, bool positional, int mode) {
ReMutexHolder holder(_lock);
if(!is_valid()) {
return get_null_sound();
@ -525,7 +525,7 @@ get_sound(const string &file_name, bool positional, int mode) {
* use, then the sound cannot be deleted, and this function has no effect.
*/
void OpenALAudioManager::
uncache_sound(const string& file_name) {
uncache_sound(const Filename &file_name) {
ReMutexHolder holder(_lock);
nassertv(is_valid());
Filename path = file_name;

View File

@ -51,10 +51,10 @@ class EXPCL_OPENAL_AUDIO OpenALAudioManager : public AudioManager {
virtual bool is_valid();
virtual PT(AudioSound) get_sound(const std::string&, bool positional = false, int mode=SM_heuristic);
virtual PT(AudioSound) get_sound(const Filename &, bool positional = false, int mode=SM_heuristic);
virtual PT(AudioSound) get_sound(MovieAudio *sound, bool positional = false, int mode=SM_heuristic);
virtual void uncache_sound(const std::string&);
virtual void uncache_sound(const Filename &);
virtual void clear_cache();
virtual void set_cache_limit(unsigned int count);
virtual unsigned int get_cache_limit() const;

View File

@ -18,7 +18,7 @@
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDAAWESOMIUM)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDAAWESOMIUM)
#error Buildsystem error: BUILDING_PANDAAWESOMIUM not defined
#endif

View File

@ -12,9 +12,17 @@
*/
#include "bulletBodyNode.h"
#include "config_bullet.h"
#include "bulletShape.h"
#include "bulletWorld.h"
#include "bulletBoxShape.h"
#include "bulletCapsuleShape.h"
#include "bulletPlaneShape.h"
#include "bulletSphereShape.h"
#include "bulletTriangleMeshShape.h"
#include "bulletTriangleMesh.h"
#include "bulletWorld.h"
#include "collisionBox.h"
#include "collisionPlane.h"

View File

@ -16,6 +16,8 @@
#include "pandabase.h"
#include "bulletShape.h"
#include "bullet_includes.h"
#include "bullet_utils.h"
@ -25,8 +27,6 @@
#include "transformState.h"
#include "boundingSphere.h"
class BulletShape;
/**
*
*/

View File

@ -12,6 +12,9 @@
*/
#include "bulletBoxShape.h"
#include "bulletWorld.h"
#include "bullet_utils.h"
TypeHandle BulletBoxShape::_type_handle;

View File

@ -13,6 +13,8 @@
#include "bulletCapsuleShape.h"
#include "config_bullet.h"
TypeHandle BulletCapsuleShape::_type_handle;
/**

View File

@ -13,6 +13,10 @@
#include "bulletCharacterControllerNode.h"
#include "config_bullet.h"
#include "bulletWorld.h"
#if BT_BULLET_VERSION >= 285
static const btVector3 up_vectors[3] = {btVector3(1.0f, 0.0f, 0.0f), btVector3(0.0f, 1.0f, 0.0f), btVector3(0.0f, 0.0f, 1.0f)};
#endif

View File

@ -13,6 +13,10 @@
#include "bulletConeShape.h"
#include "config_bullet.h"
#include "bulletWorld.h"
TypeHandle BulletConeShape::_type_handle;
/**

View File

@ -12,7 +12,9 @@
*/
#include "bulletConeTwistConstraint.h"
#include "bulletRigidBodyNode.h"
#include "bulletWorld.h"
#include "deg_2_rad.h"

View File

@ -12,7 +12,9 @@
*/
#include "bulletConstraint.h"
#include "bulletRigidBodyNode.h"
#include "bulletShape.h"
TypeHandle BulletConstraint::_type_handle;

View File

@ -13,6 +13,8 @@
#include "bulletConvexHullShape.h"
#include "bulletWorld.h"
#include "nodePathCollection.h"
#include "geomNode.h"
#include "geomVertexReader.h"

View File

@ -22,6 +22,7 @@
#include "luse.h"
#include "geom.h"
#include "pta_LVecBase3.h"
#include "transformState.h"
/**
*

View File

@ -13,6 +13,10 @@
#include "bulletConvexPointCloudShape.h"
#include "bulletWorld.h"
#include "bullet_utils.h"
#include "geomVertexReader.h"
TypeHandle BulletConvexPointCloudShape::_type_handle;

View File

@ -13,6 +13,8 @@
#include "bulletCylinderShape.h"
#include "config_bullet.h"
using std::endl;
TypeHandle BulletCylinderShape::_type_handle;

View File

@ -13,6 +13,10 @@
#include "bulletDebugNode.h"
#include "config_bullet.h"
#include "bulletWorld.h"
#include "cullHandler.h"
#include "cullTraverser.h"
#include "cullableObject.h"

View File

@ -16,8 +16,13 @@
#include "pandabase.h"
#include "pandaNode.h"
#include "bullet_includes.h"
class CullTraverser;
class CullTraverserData;
/**
*
*/

View File

@ -12,7 +12,9 @@
*/
#include "bulletGenericConstraint.h"
#include "bulletRigidBodyNode.h"
#include "bulletWorld.h"
TypeHandle BulletGenericConstraint::_type_handle;

View File

@ -12,7 +12,9 @@
*/
#include "bulletGhostNode.h"
#include "bulletShape.h"
#include "bulletWorld.h"
TypeHandle BulletGhostNode::_type_handle;

View File

@ -13,6 +13,10 @@
#include "bulletHeightfieldShape.h"
#include "config_bullet.h"
#include "bulletWorld.h"
TypeHandle BulletHeightfieldShape::_type_handle;
/**

View File

@ -12,13 +12,17 @@
*/
#include "bulletHelper.h"
#include "bulletRigidBodyNode.h"
#include "bulletSoftBodyNode.h"
#include "bulletGhostNode.h"
#include "geomLines.h"
#include "geomTriangles.h"
#include "geomVertexRewriter.h"
#include "bullet_utils.h"
PT(InternalName) BulletHelper::_sb_index;
PT(InternalName) BulletHelper::_sb_flip;

View File

@ -23,6 +23,8 @@
#include "nodePath.h"
#include "nodePathCollection.h"
class BulletSoftBodyNode;
/**
*
*/

View File

@ -12,7 +12,9 @@
*/
#include "bulletHingeConstraint.h"
#include "bulletRigidBodyNode.h"
#include "bulletWorld.h"
#include "deg_2_rad.h"

View File

@ -13,6 +13,8 @@
#include "bulletManifoldPoint.h"
#include "bulletWorld.h"
/**
*
*/

View File

@ -13,6 +13,8 @@
#include "bulletMinkowskiSumShape.h"
#include "bulletWorld.h"
TypeHandle BulletMinkowskiSumShape::_type_handle;
/**

View File

@ -13,6 +13,8 @@
#include "bulletMultiSphereShape.h"
#include "bulletWorld.h"
#include "geomVertexReader.h"
TypeHandle BulletMultiSphereShape::_type_handle;

View File

@ -19,6 +19,7 @@
#include "bullet_includes.h"
#include "bulletShape.h"
#include "factoryParams.h"
#include "pta_LVecBase3.h"
#include "pta_stdfloat.h"

View File

@ -12,7 +12,9 @@
*/
#include "bulletPersistentManifold.h"
#include "bulletManifoldPoint.h"
#include "bulletWorld.h"
/**
*

View File

@ -13,6 +13,8 @@
#include "bulletPlaneShape.h"
#include "bulletWorld.h"
TypeHandle BulletPlaneShape::_type_handle;
/**

View File

@ -12,7 +12,11 @@
*/
#include "bulletRigidBodyNode.h"
#include "config_bullet.h"
#include "bulletShape.h"
#include "bulletWorld.h"
TypeHandle BulletRigidBodyNode::_type_handle;

View File

@ -13,6 +13,8 @@
#include "bulletRotationalLimitMotor.h"
#include "bulletWorld.h"
/**
*
*/

View File

@ -12,6 +12,9 @@
*/
#include "bulletShape.h"
#include "bulletWorld.h"
#include "bullet_utils.h"
TypeHandle BulletShape::_type_handle;

View File

@ -18,7 +18,7 @@
#include "bullet_includes.h"
#include "typedReferenceCount.h"
#include "typedWritableReferenceCount.h"
#include "boundingSphere.h"
/**

View File

@ -12,7 +12,9 @@
*/
#include "bulletSliderConstraint.h"
#include "bulletRigidBodyNode.h"
#include "bulletWorld.h"
#include "deg_2_rad.h"

View File

@ -13,6 +13,10 @@
#include "bulletSoftBodyConfig.h"
#include "bulletWorld.h"
#include "lightMutexHolder.h"
/**
*
*/

View File

@ -18,6 +18,8 @@
#include "bullet_includes.h"
#include "numeric_types.h"
/**
*
*/

View File

@ -30,3 +30,12 @@ empty() {
return BulletSoftBodyMaterial(material);
}
/**
*
*/
INLINE btSoftBody::Material &BulletSoftBodyMaterial::
get_material() const {
return _material;
}

View File

@ -13,6 +13,8 @@
#include "bulletSoftBodyMaterial.h"
#include "bulletWorld.h"
/**
*
*/
@ -21,15 +23,6 @@ BulletSoftBodyMaterial(btSoftBody::Material &material) : _material(material) {
}
/**
*
*/
btSoftBody::Material &BulletSoftBodyMaterial::
get_material() const {
return _material;
}
/**
* Getter for the property m_kLST.
*/

View File

@ -18,6 +18,8 @@
#include "bullet_includes.h"
#include "numeric_types.h"
/**
*
*/

View File

@ -12,12 +12,14 @@
*/
#include "bulletSoftBodyNode.h"
#include "bulletSoftBodyConfig.h"
#include "bulletSoftBodyControl.h"
#include "bulletSoftBodyMaterial.h"
#include "bulletSoftBodyShape.h"
#include "bulletSoftBodyWorldInfo.h"
#include "bulletHelper.h"
#include "bulletWorld.h"
#include "geomVertexRewriter.h"
#include "geomVertexReader.h"

View File

@ -29,6 +29,7 @@
#include "nurbsSurfaceEvaluator.h"
#include "pta_LVecBase3.h"
class BulletRigidBodyNode;
class BulletSoftBodyConfig;
class BulletSoftBodyControl;
class BulletSoftBodyMaterial;

View File

@ -12,7 +12,9 @@
*/
#include "bulletSoftBodyShape.h"
#include "bulletSoftBodyNode.h"
#include "bulletWorld.h"
TypeHandle BulletSoftBodyShape::_type_handle;

View File

@ -13,6 +13,8 @@
#include "bulletSoftBodyWorldInfo.h"
#include "bulletWorld.h"
/**
*
*/

View File

@ -13,6 +13,8 @@
#include "bulletSphereShape.h"
#include "bulletWorld.h"
TypeHandle BulletSphereShape::_type_handle;
/**

View File

@ -12,7 +12,9 @@
*/
#include "bulletSphericalConstraint.h"
#include "bulletRigidBodyNode.h"
#include "bulletWorld.h"
TypeHandle BulletSphericalConstraint::_type_handle;

View File

@ -13,6 +13,8 @@
#include "bulletTranslationalLimitMotor.h"
#include "bulletWorld.h"
/**
*
*/

View File

@ -13,7 +13,10 @@
#include "bulletTriangleMesh.h"
#include "bulletWorld.h"
#include "pvector.h"
#include "geomTriangles.h"
#include "geomVertexData.h"
#include "geomVertexReader.h"

View File

@ -12,7 +12,11 @@
*/
#include "bulletTriangleMeshShape.h"
#include "config_bullet.h"
#include "bulletTriangleMesh.h"
#include "bulletWorld.h"
#include "nodePathCollection.h"
#include "geomNode.h"

View File

@ -19,6 +19,7 @@
#include "bullet_includes.h"
#include "bulletShape.h"
#include "factoryParams.h"
#include "luse.h"
class BulletTriangleMesh;

View File

@ -12,6 +12,9 @@
*/
#include "bulletVehicle.h"
#include "config_bullet.h"
#include "bulletWorld.h"
#include "bulletRigidBodyNode.h"
#include "bulletWheel.h"

View File

@ -13,6 +13,8 @@
#include "bulletWheel.h"
#include "bulletWorld.h"
/**
*
*/

View File

@ -12,9 +12,14 @@
*/
#include "bulletWorld.h"
#include "config_bullet.h"
#include "bulletFilterCallbackData.h"
#include "bulletPersistentManifold.h"
#include "bulletShape.h"
#include "bulletSoftBodyWorldInfo.h"
#include "bulletTickCallbackData.h"
#include "collideMask.h"
#include "lightMutexHolder.h"

View File

@ -44,6 +44,8 @@ EXPCL_PANDABULLET CPT(TransformState) btTrans_to_TransformState(
EXPCL_PANDABULLET btTransform TransformState_to_btTrans(
CPT(TransformState) ts);
EXPCL_PANDABULLET void get_node_transform(btTransform &trans, PandaNode *node);
// UpAxis
BEGIN_PUBLISH

View File

@ -56,7 +56,7 @@ extern ContactDestroyedCallback gContactDestroyedCallback;
#include "dconfig.h"
#include "pandaSystem.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDABULLET)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDABULLET)
#error Buildsystem error: BUILDING_PANDABULLET not defined
#endif

View File

@ -34,7 +34,7 @@
#include "luse.h"
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDA_CHAN)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDA_CHAN)
#error Buildsystem error: BUILDING_PANDA_CHAN not defined
#endif

View File

@ -21,7 +21,7 @@
#include "jointVertexTransform.h"
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDA_CHAR)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDA_CHAR)
#error Buildsystem error: BUILDING_PANDA_CHAR not defined
#endif

View File

@ -20,7 +20,7 @@
#include "dconfig.h"
#include "pandaSystem.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDA_COCOADISPLAY)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDA_COCOADISPLAY)
#error Buildsystem error: BUILDING_PANDA_COCOADISPLAY not defined
#endif

View File

@ -17,7 +17,7 @@
#include "loaderFileTypeDae.h"
#include "loaderFileTypeRegistry.h"
#if !defined(CPPPARSER) && !defined(BUILDING_COLLADA)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_COLLADA)
#error Buildsystem error: BUILDING_COLLADA not defined
#endif

View File

@ -42,7 +42,7 @@
#include "collisionVisualizer.h"
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDA_COLLIDE)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDA_COLLIDE)
#error Buildsystem error: BUILDING_PANDA_COLLIDE not defined
#endif

View File

@ -22,7 +22,7 @@
#include "cullBinManager.h"
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDA_CULL)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDA_CULL)
#error Buildsystem error: BUILDING_PANDA_CULL not defined
#endif

View File

@ -27,7 +27,7 @@
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDA_DEVICE)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDA_DEVICE)
#error Buildsystem error: BUILDING_PANDA_DEVICE not defined
#endif

View File

@ -17,7 +17,7 @@
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDA_DGRAPH)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDA_DGRAPH)
#error Buildsystem error: BUILDING_PANDA_DGRAPH not defined
#endif

View File

@ -31,7 +31,7 @@
#include "subprocessWindow.h"
#include "windowHandle.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDA_DISPLAY)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDA_DISPLAY)
#error Buildsystem error: BUILDING_PANDA_DISPLAY not defined
#endif

View File

@ -20,7 +20,7 @@
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDAFX)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDAFX)
#error Buildsystem error: BUILDING_PANDAFX not defined
#endif

View File

@ -19,7 +19,7 @@
#include "pandaSystem.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDA_DOWNLOADER)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDA_DOWNLOADER)
#error Buildsystem error: BUILDING_PANDA_DOWNLOADER not defined
#endif

View File

@ -27,7 +27,7 @@
#include "dconfig.h"
#if !defined(CPPPARSER) && !defined(BUILDING_PANDADX)
#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_PANDADX)
#error Buildsystem error: BUILDING_PANDADX not defined
#endif

Some files were not shown because too many files have changed in this diff Show More