summaryrefslogtreecommitdiff
path: root/indra/newview/llvopartgroup.h
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llvopartgroup.h')
-rwxr-xr-x[-rw-r--r--]indra/newview/llvopartgroup.h42
1 files changed, 37 insertions, 5 deletions
diff --git a/indra/newview/llvopartgroup.h b/indra/newview/llvopartgroup.h
index e58fed86d9..724e915d02 100644..100755
--- a/indra/newview/llvopartgroup.h
+++ b/indra/newview/llvopartgroup.h
@@ -31,43 +31,75 @@
#include "v3math.h"
#include "v3color.h"
#include "llframetimer.h"
+#include "llviewerpartsim.h"
+#include "llvertexbuffer.h"
class LLViewerPartGroup;
class LLVOPartGroup : public LLAlphaObject
{
public:
+
+ //vertex buffer for holding all particles
+ static LLPointer<LLVertexBuffer> sVB;
+ static S32 sVBSlotCursor;
+
+ static void initClass();
+ static void restoreGL();
+ static void destroyGL();
+ static S32 findAvailableVBSlot();
+ static void freeVBSlot(S32 idx);
+
enum
{
- VERTEX_DATA_MASK = (1 << LLVertexBuffer::TYPE_VERTEX) |
- (1 << LLVertexBuffer::TYPE_NORMAL) |
- (1 << LLVertexBuffer::TYPE_TEXCOORD0) |
- (1 << LLVertexBuffer::TYPE_COLOR)
+ VERTEX_DATA_MASK = LLVertexBuffer::MAP_VERTEX |
+ LLVertexBuffer::MAP_NORMAL |
+ LLVertexBuffer::MAP_TEXCOORD0 |
+ LLVertexBuffer::MAP_COLOR |
+ LLVertexBuffer::MAP_EMISSIVE |
+ LLVertexBuffer::MAP_TEXTURE_INDEX
};
LLVOPartGroup(const LLUUID &id, const LLPCode pcode, LLViewerRegion *regionp);
/*virtual*/ BOOL isActive() const; // Whether this object needs to do an idleUpdate.
- BOOL idleUpdate(LLAgent &agent, LLWorld &world, const F64 &time);
+ void idleUpdate(LLAgent &agent, LLWorld &world, const F64 &time);
virtual F32 getBinRadius();
virtual void updateSpatialExtents(LLVector4a& newMin, LLVector4a& newMax);
virtual U32 getPartitionType() const;
+ /*virtual*/ BOOL lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end,
+ S32 face,
+ BOOL pick_transparent,
+ S32* face_hit,
+ LLVector4a* intersection,
+ LLVector2* tex_coord,
+ LLVector4a* normal,
+ LLVector4a* tangent);
+
/*virtual*/ void setPixelAreaAndAngle(LLAgent &agent);
/*virtual*/ void updateTextures();
/*virtual*/ LLDrawable* createDrawable(LLPipeline *pipeline);
/*virtual*/ BOOL updateGeometry(LLDrawable *drawable);
+ void getGeometry(const LLViewerPart& part,
+ LLStrider<LLVector4a>& verticesp);
+
void getGeometry(S32 idx,
LLStrider<LLVector4a>& verticesp,
LLStrider<LLVector3>& normalsp,
LLStrider<LLVector2>& texcoordsp,
LLStrider<LLColor4U>& colorsp,
+ LLStrider<LLColor4U>& emissivep,
LLStrider<U16>& indicesp);
void updateFaceSize(S32 idx) { }
F32 getPartSize(S32 idx);
+ void getBlendFunc(S32 idx, U32& src, U32& dst);
+ LLUUID getPartOwner(S32 idx);
+ LLUUID getPartSource(S32 idx);
+
void setViewerPartGroup(LLViewerPartGroup *part_groupp) { mViewerPartGroupp = part_groupp; }
LLViewerPartGroup* getViewerPartGroup() { return mViewerPartGroupp; }