mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-30 16:58:40 -04:00
gobj: fix crash with ShaderBuffer
This commit is contained in:
parent
ed5e5386b9
commit
540122e703
@ -19,7 +19,8 @@ INLINE ShaderBuffer::
|
||||
ShaderBuffer(const string &name, uint64_t size, UsageHint usage_hint) :
|
||||
Namable(name),
|
||||
_data_size_bytes(size),
|
||||
_usage_hint(usage_hint) {
|
||||
_usage_hint(usage_hint),
|
||||
_contexts(nullptr) {
|
||||
}
|
||||
|
||||
/**
|
||||
@ -31,7 +32,8 @@ ShaderBuffer(const string &name, pvector<unsigned char> initial_data, UsageHint
|
||||
Namable(name),
|
||||
_data_size_bytes(initial_data.size()),
|
||||
_usage_hint(usage_hint),
|
||||
_initial_data(initial_data) {
|
||||
_initial_data(initial_data),
|
||||
_contexts(nullptr) {
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -16,6 +16,14 @@
|
||||
|
||||
TypeHandle ShaderBuffer::_type_handle;
|
||||
|
||||
/**
|
||||
* Destructor.
|
||||
*/
|
||||
ShaderBuffer::
|
||||
~ShaderBuffer() {
|
||||
release_all();
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
|
@ -32,6 +32,8 @@ private:
|
||||
INLINE ShaderBuffer() DEFAULT_CTOR;
|
||||
|
||||
PUBLISHED:
|
||||
~ShaderBuffer();
|
||||
|
||||
INLINE explicit ShaderBuffer(const string &name, uint64_t size, UsageHint usage_hint);
|
||||
INLINE explicit ShaderBuffer(const string &name, pvector<unsigned char> initial_data, UsageHint usage_hint);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user