OpenSim
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
Classes | Public Member Functions | Protected Attributes | Properties | List of all members
OpenSim.Region.Framework.Scenes.TerrainChannel Class Reference

A new version of the old Channel class, simplified More...

Inheritance diagram for OpenSim.Region.Framework.Scenes.TerrainChannel:
Inheritance graph
[legend]
Collaboration diagram for OpenSim.Region.Framework.Scenes.TerrainChannel:
Collaboration graph
[legend]

Public Member Functions

 TerrainChannel ()
 
 TerrainChannel (int pX, int pY)
 
 TerrainChannel (String type, int pX, int pY, int pZ)
 
 TerrainChannel (double[,] pM, int pSizeX, int pSizeY, int pAltitude)
 
 TerrainChannel (TerrainData pTerrData)
 
ITerrainChannel MakeCopy ()
 
TerrainData GetTerrainData ()
 
float[] GetFloatsSerialised ()
 Squash the entire heightmap into a single dimensioned array More...
 
double[,] GetDoubles ()
 
float GetHeightAtXYZ (float x, float y, float z)
 
bool Tainted (int x, int y)
 
string SaveToXmlString ()
 
void LoadFromXmlString (string data)
 
void Merge (ITerrainChannel newTerrain, Vector3 displacement, float radianRotation, Vector2 rotationDisplacement)
 
void MergeWithBounding (ITerrainChannel newTerrain, Vector3 displacement, float rotationDegrees, Vector2 boundingOrigin, Vector2 boundingSize)
 A new version of terrain merge that processes the terrain in a specific order and corrects the problems with rotated terrains having 'holes' in that need to be smoothed. The correct way to rotate something is to iterate over the target, taking data from the source, not the other way around. This ensures that the target has no holes in it. The processing order of an incoming terrain is: More...
 
TerrainChannel Copy ()
 

Protected Attributes

TerrainData m_terrainData
 

Properties

int Width [get]
 
int Height [get]
 
int Altitude [get]
 
double this[int x, int y] [get, set]
 
- Properties inherited from OpenSim.Region.Framework.Interfaces.ITerrainChannel
int Width [get]
 
int Height [get]
 
int Altitude [get]
 
double this[int x, int y] [get, set]
 

Detailed Description

A new version of the old Channel class, simplified

Definition at line 48 of file TerrainChannel.cs.

Constructor & Destructor Documentation

OpenSim.Region.Framework.Scenes.TerrainChannel.TerrainChannel ( )
inline

Definition at line 62 of file TerrainChannel.cs.

OpenSim.Region.Framework.Scenes.TerrainChannel.TerrainChannel ( int  pX,
int  pY 
)
inline

Definition at line 70 of file TerrainChannel.cs.

OpenSim.Region.Framework.Scenes.TerrainChannel.TerrainChannel ( String  type,
int  pX,
int  pY,
int  pZ 
)
inline

Definition at line 77 of file TerrainChannel.cs.

OpenSim.Region.Framework.Scenes.TerrainChannel.TerrainChannel ( double  pM[,],
int  pSizeX,
int  pSizeY,
int  pAltitude 
)
inline

Definition at line 88 of file TerrainChannel.cs.

OpenSim.Region.Framework.Scenes.TerrainChannel.TerrainChannel ( TerrainData  pTerrData)
inline

Definition at line 103 of file TerrainChannel.cs.

Member Function Documentation

TerrainChannel OpenSim.Region.Framework.Scenes.TerrainChannel.Copy ( )
inline

Definition at line 426 of file TerrainChannel.cs.

double [,] OpenSim.Region.Framework.Scenes.TerrainChannel.GetDoubles ( )
inline
float [] OpenSim.Region.Framework.Scenes.TerrainChannel.GetFloatsSerialised ( )
inline

Squash the entire heightmap into a single dimensioned array

Returns

Implements OpenSim.Region.Framework.Interfaces.ITerrainChannel.

Definition at line 126 of file TerrainChannel.cs.

float OpenSim.Region.Framework.Scenes.TerrainChannel.GetHeightAtXYZ ( float  x,
float  y,
float  z 
)
inline
TerrainData OpenSim.Region.Framework.Scenes.TerrainChannel.GetTerrainData ( )
inline
void OpenSim.Region.Framework.Scenes.TerrainChannel.LoadFromXmlString ( string  data)
inline
ITerrainChannel OpenSim.Region.Framework.Scenes.TerrainChannel.MakeCopy ( )
inline
void OpenSim.Region.Framework.Scenes.TerrainChannel.Merge ( ITerrainChannel  newTerrain,
Vector3  displacement,
float  radianRotation,
Vector2  rotationDisplacement 
)
inline
void OpenSim.Region.Framework.Scenes.TerrainChannel.MergeWithBounding ( ITerrainChannel  newTerrain,
Vector3  displacement,
float  rotationDegrees,
Vector2  boundingOrigin,
Vector2  boundingSize 
)
inline

A new version of terrain merge that processes the terrain in a specific order and corrects the problems with rotated terrains having 'holes' in that need to be smoothed. The correct way to rotate something is to iterate over the target, taking data from the source, not the other way around. This ensures that the target has no holes in it. The processing order of an incoming terrain is:

  1. Apply rotation
  2. Apply bounding rectangle
  3. Apply displacement rotationCenter is no longer needed and has been discarded.
Parameters
newTerrain
displacement<x, y, z>
rotationDegrees
boundingOrigin<x, y>
boundingSize<x, y>

Implements OpenSim.Region.Framework.Interfaces.ITerrainChannel.

Definition at line 297 of file TerrainChannel.cs.

string OpenSim.Region.Framework.Scenes.TerrainChannel.SaveToXmlString ( )
inline
bool OpenSim.Region.Framework.Scenes.TerrainChannel.Tainted ( int  x,
int  y 
)
inline

Member Data Documentation

TerrainData OpenSim.Region.Framework.Scenes.TerrainChannel.m_terrainData
protected

Definition at line 53 of file TerrainChannel.cs.

Property Documentation

int OpenSim.Region.Framework.Scenes.TerrainChannel.Altitude
get

Definition at line 58 of file TerrainChannel.cs.

int OpenSim.Region.Framework.Scenes.TerrainChannel.Height
get

Definition at line 57 of file TerrainChannel.cs.

double OpenSim.Region.Framework.Scenes.TerrainChannel.this[int x, int y]
getset

Definition at line 151 of file TerrainChannel.cs.

int OpenSim.Region.Framework.Scenes.TerrainChannel.Width
get

Definition at line 55 of file TerrainChannel.cs.


The documentation for this class was generated from the following file: