Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Alchemy Viewer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package Registry
Operate
Terraform modules
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Silent mode is enabled
All outbound communications are blocked.
Learn more
.
Show more breadcrumbs
Alchemy Viewer
Alchemy Viewer
Commits
0b99da8b
Commit
0b99da8b
authored
13 years ago
by
prep
Browse files
Options
Downloads
Patches
Plain Diff
WIP: Implementing VB manager for complex physics shapes
parent
0539b083
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
indra/llrender/llrendernavprim.cpp
+10
-4
10 additions, 4 deletions
indra/llrender/llrendernavprim.cpp
indra/llrender/llrendernavprim.h
+6
-2
6 additions, 2 deletions
indra/llrender/llrendernavprim.h
with
16 additions
and
6 deletions
indra/llrender/llrendernavprim.cpp
+
10
−
4
View file @
0b99da8b
...
@@ -29,11 +29,11 @@
...
@@ -29,11 +29,11 @@
#include
"llrendernavprim.h"
#include
"llrendernavprim.h"
#include
"llerror.h"
#include
"llerror.h"
#include
"llglheaders.h"
#include
"llglheaders.h"
#include
"llvertexbuffer.h"
//=============================================================================
//=============================================================================
LLRenderNavPrim
gRenderNav
;
LLRenderNavPrim
gRenderNav
;
//=============================================================================
//=============================================================================
void
LLRenderNavPrim
::
renderSegment
(
const
LLVector3
&
start
,
const
LLVector3
&
end
,
int
color
)
void
LLRenderNavPrim
::
renderSegment
(
const
LLVector3
&
start
,
const
LLVector3
&
end
,
int
color
)
const
{
{
LLColor4
colorA
(
color
);
LLColor4
colorA
(
color
);
...
@@ -49,13 +49,13 @@ void LLRenderNavPrim::renderSegment( const LLVector3& start, const LLVector3& en
...
@@ -49,13 +49,13 @@ void LLRenderNavPrim::renderSegment( const LLVector3& start, const LLVector3& en
glLineWidth
(
1.0
f
);
glLineWidth
(
1.0
f
);
}
}
//=============================================================================
//=============================================================================
void
LLRenderNavPrim
::
renderTri
(
const
LLVector3
&
a
,
const
LLVector3
&
b
,
const
LLVector3
&
c
,
int
color
)
void
LLRenderNavPrim
::
renderTri
(
const
LLVector3
&
a
,
const
LLVector3
&
b
,
const
LLVector3
&
c
,
int
color
)
const
{
{
LLGLEnable
offset
(
GL_POLYGON_OFFSET_LINE
);
LLGLEnable
offset
(
GL_POLYGON_OFFSET_LINE
);
glPolygonMode
(
GL_FRONT_AND_BACK
,
GL_FILL
);
glPolygonMode
(
GL_FRONT_AND_BACK
,
GL_FILL
);
glLineWidth
(
1.5
f
);
glLineWidth
(
1.5
f
);
LLColor4
colorA
(
color
);
LLColor4
colorA
(
color
);
gGL
.
color4fv
(
colorA
.
mV
);
gGL
.
color4fv
(
colorA
.
mV
);
gGL
.
begin
(
LLRender
::
TRIANGLES
);
gGL
.
begin
(
LLRender
::
TRIANGLES
);
{
{
gGL
.
vertex3fv
(
a
.
mV
);
gGL
.
vertex3fv
(
a
.
mV
);
...
@@ -66,4 +66,10 @@ void LLRenderNavPrim::renderTri( const LLVector3& a, const LLVector3& b, const L
...
@@ -66,4 +66,10 @@ void LLRenderNavPrim::renderTri( const LLVector3& a, const LLVector3& b, const L
glLineWidth
(
1.
f
);
glLineWidth
(
1.
f
);
}
}
//=============================================================================
void
LLRenderNavPrim
::
renderNavMeshVB
(
const
LLVertexBuffer
*
pVBO
,
int
vertCnt
)
const
{
//pVBO->setBuffer( LLVertexBuffer::MAP_VERTEX );
pVBO
->
drawArrays
(
LLRender
::
TRIANGLES
,
0
,
vertCnt
);
}
//=============================================================================
//=============================================================================
\ No newline at end of file
This diff is collapsed.
Click to expand it.
indra/llrender/llrendernavprim.h
+
6
−
2
View file @
0b99da8b
...
@@ -39,8 +39,12 @@
...
@@ -39,8 +39,12 @@
class
LLRenderNavPrim
class
LLRenderNavPrim
{
{
public:
public:
void
renderSegment
(
const
LLVector3
&
start
,
const
LLVector3
&
end
,
int
color
);
//Draw a line
void
renderTri
(
const
LLVector3
&
a
,
const
LLVector3
&
b
,
const
LLVector3
&
c
,
int
color
);
void
renderSegment
(
const
LLVector3
&
start
,
const
LLVector3
&
end
,
int
color
)
const
;
//Draw simple tri
void
renderTri
(
const
LLVector3
&
a
,
const
LLVector3
&
b
,
const
LLVector3
&
c
,
int
color
)
const
;
//Draw the contents of vertex buffer
void
renderNavMeshVB
(
const
LLVertexBuffer
*
pVBO
,
int
vertCnt
)
const
;
private:
private:
};
};
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment