Display a set of lines as specified by the Edge skeleton of a grid.
Display a set of lines as specified by the Edge skeleton of a grid.Refinement levels and fragmented fields not implemented.
#include <bone/FishGrid.hpp>
#include <ocean/GLvish/VGLRenderObject.hpp>
#include <ocean/GLvish/BoundingBox.hpp>
#include <ocean/GLvish/GlossyTexture.hpp>
#include <eagle/PhysicalSpace.hpp>
#include <ocean/shrimp/TimeDependent.hpp>
#include <GL/fieldGL.hpp>
#include <GL/FieldBuffer.hpp>
#include <baseop/ExpandBBox.hpp>
#include <ocean/shrimp/VObjectStatus.hpp>
#include <grid/types/LineSet.hpp>
#include <bundle/BundleProperty.hpp>
#include <GL/LineSetRenderer.hpp>
#include <bone/GridActor.hpp>
namespace
{
{
public:
struct FieldState : State
{
};
{
return new FieldState();
}
nLines;
, GlossyParameters(this)
, LineGrid(this, "grid")
, Thickness(this, "thickness", 1.0)
, WhichLine(this, "lineid", -1, 1)
, nLines(this, "nlines", 1, 2)
{
}
{
}
bool update(
VRequest&R,
double precision)
override;
static string createChildname(
const string&
parent_name)
{
}
};
{
double time =
SI.getTime();
return setStatusError(
Context,
"No grid object found at T=" + String(time),
false );
setBoundingBall(
Context, getBoundingBox( *
SI.getGrid() ) );
{
return setStatusError(
Context,
"No line grid found at T=" + String(time),
false );
}
S->theGridOfInterest =
SI.getGrid();
index_t N =
LS.NumberOfLines();
WhichLine.setProperty("max", int(N) );
nLines.setProperty("max", int(N) );
return setStatusInfo(
Context, String(
int(N)) +
" Lines ready.");
}
{
if (!S) return false;
if (!S->theGridOfInterest)
return false;
try
{
}
{
Verbose(0) << "Got an GL Exception...";
}
if (!LineTexture)
{
LineTexture->enlighten();
LineTexture->enlighten(GlossyParameters,
Context);
}
double width = 1.0;
if (width<=0.0) width=0.01;
{
try
{
}
catch(...){}
Verbose(0) <<
"glossy lines continue..." <<
myVBO;
(
LS.Coords &&
myVBO->isOlderThan( *
LS.Coords) ) ||
(
LS.LineIndices &&
myVBO->isOlderThan( *
LS.LineIndices) ) )
{
return false;
#if 1
{
}
#endif
}
if (!R)
{
puts(
"GlossyLines: Renderer Problem");
return false;
}
}
return true;
}
{
{
}
};
}
An iterator with an optional DataCreator, which is just a class to intercept creation of data along a...
Definition CreativeIterator.hpp:34
Context information to select a grid from within a bundle.
Definition GridSelector.hpp:26
Info< Skeleton > getRefinementLevel(double time, int Level, int IndexDepth, const BundlePtr &SpaceTime=BundlePtr(NullPtr()))
Retrieve a skeleton for the given refinement level for the current time.
Definition GridSelector.cpp:14
A set of lines stored on a Grid.
Definition LineSet.hpp:55
A concrete Grid Property which looks for the existence of a Skeleton of the specified dimension and i...
Definition BundleProperty.hpp:76
bool setProperty(const string &theName, const Type &theValue) const
Given a fragmented field of curvilinear coordinates, (3D array of coordinates), build a uniform Grid ...
Definition FAQ.dox:2
note: cannot derive from FloatingSkeletonRenderer as long as independent base class TriangleRenderer ...
Definition GridInspector.hpp:13
Common base class for objects that render information given on line sets, merely for grouping purpose...
Definition eye/retina/LineSetRenderer.hpp:39