//----------------------------------------------------------------------------
void UIButtonBase::Save(OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	UIFrame::Save(target);
	PX2_VERSION_SAVE(target);

	target.WriteEnum(mButType);

	target.WriteAggregate(mNormalColor);
	target.WriteAggregate(mHoveredColor);
	target.WriteAggregate(mPressedColor);
	target.WriteAggregate(mDisableColor);
	target.Write(mNormalAlpha);
	target.Write(mHoveredAlpha);
	target.Write(mPressedAlpha);
	target.Write(mDisableAlpha);
	target.Write(mNormalBrightness);
	target.Write(mHoveredBrightness);
	target.Write(mPressedBrightness);
	target.Write(mDisableBrightness);

	target.WritePointer(mPicBoxNormal);
	target.WritePointer(mPicBoxOver);
	target.WritePointer(mPicBoxDown);
	target.WritePointer(mPicBoxDisabled);
	target.WriteEnum(mButtonState);

	PX2_END_DEBUG_STREAM_SAVE(UIButtonBase, target);
}
//----------------------------------------------------------------------------
void RawTerrainPage::Save (OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	TerrainPage::Save(target);
	PX2_VERSION_SAVE(target);

	target.WritePointer(mMtlInst);

	target.WriteString(mTextureDefaultFilename);
	target.WriteString(mTexture0Filename);

	target.WritePointer(mTextureAlpha);

	target.WriteString(mTexture1Filename);
	target.WriteString(mTexture2Filename);
	target.WriteString(mTexture3Filename);
	target.WriteString(mTexture4Filename);

	target.WriteAggregate(mUV01);
	target.WriteAggregate(mUV23);
	target.WriteAggregate(mUV4);
	target.WritePointer(mUV01Float);
	target.WritePointer(mUV23Float);
	target.WritePointer(mUV4Float);

	PX2_END_DEBUG_STREAM_SAVE(RawTerrainPage, target);
}
示例#3
0
//----------------------------------------------------------------------------
void RawTerrain::Save (OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	Node::Save(target);

	target.WriteEnum(mMode);
	target.Write(mNumRows);
	target.Write(mNumCols);
	target.Write(mSize);
	target.Write(mMinElevation);
	target.Write(mMaxElevation);
	target.Write(mSpacing);
	target.Write(mCameraRow);
	target.Write(mCameraCol);
	target.WritePointer(mVFormat);
	target.WritePointer(mCamera);
	target.WritePointer(mShine);

	for (int row = 0; row < mNumRows; ++row)
	{
		for (int col = 0; col < mNumCols; ++col)
		{
			target.WritePointer(mPages[row][col]);
		}
	}

	PX2_END_DEBUG_STREAM_SAVE(RawTerrain, target);
}
示例#4
0
//----------------------------------------------------------------------------
void CurveMesh::Save (OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	Polysegment::Save(target);
	PX2_VERSION_SAVE(target);

	target.Write(mNumFullVertices);
	target.Write(mNumSegments);
	target.Write(mLevel);
	target.WriteBool(mAllowDynamicChange);
	target.WritePointer(mOrigVBuffer);
	target.WritePointer(mOrigParams);
	target.WritePointerN(mNumSegments, mSegments);

	if (mCInfo)
	{
		for (int i = 0; i < mNumFullVertices; ++i)
		{
			target.WritePointer(mCInfo[i].Segment);
			target.Write(mCInfo[i].Param);
		}
	}

	PX2_END_DEBUG_STREAM_SAVE(CurveMesh, target);
}
示例#5
0
//----------------------------------------------------------------------------
void UI::Save(OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	UIFrame::Save(target);
	PX2_VERSION_SAVE(target);

	target.WritePointer(mDefaultCamera);
	target.WritePointer(mDefaultCameraNode);

	PX2_END_DEBUG_STREAM_SAVE(UI, target);
}
示例#6
0
//----------------------------------------------------------------------------
void RawTerrainPage::Save (OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	TriMesh::Save(target);

	target.Write(mSize);
	int numVertices = mSize*mSize;
	target.WriteN(numVertices, mHeights);
	target.WriteAggregate(mOrigin);
	target.Write(mSpacing);

	target.WritePointer(mMaterialInstance);
	target.WritePointer(mTextureDefault);
	target.WritePointer(mTexture0);
	target.WritePointer(mTextureAlpha);
	target.WritePointer(mTexture1);
	target.WritePointer(mTexture2);
	target.WritePointer(mTexture3);
	target.WritePointer(mTexture4);
	target.WriteAggregate(mUV01);
	target.WriteAggregate(mUV23);
	target.WriteAggregate(mUV4);
	target.WritePointer(mUV01Float);
	target.WritePointer(mUV23Float);
	target.WritePointer(mUV4Float);

	PX2_END_DEBUG_STREAM_SAVE(RawTerrainPage, target);
}
示例#7
0
//----------------------------------------------------------------------------
void Visual::Save (OutStream& target) const
{
    WM5_BEGIN_DEBUG_STREAM_SAVE(target);

    Spatial::Save(target);

    target.WriteEnum(mType);
    target.WriteAggregate(mModelBound);
    target.WritePointer(mVFormat);
    target.WritePointer(mVBuffer);
    target.WritePointer(mIBuffer);
    target.WritePointer(mEffect);

    WM5_END_DEBUG_STREAM_SAVE(Visual, target);
}
示例#8
0
//----------------------------------------------------------------------------
void Renderable::Save (OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	Movable::Save(target);

	target.WriteEnum(mType);
	target.WriteAggregate(mModelBound);
	target.WritePointer(mVFormat);
	target.WritePointer(mVBuffer);
	target.WritePointer(mIBuffer);
	target.WritePointer(mMaterial);

	PX2_END_DEBUG_STREAM_SAVE(Renderable, target);
}
示例#9
0
//----------------------------------------------------------------------------
void Actor::Save (OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	Netable::Save(target);

	target.WriteAggregate(mScale);
	target.WriteAggregate(mRotation);
	target.WriteAggregate(mPosition);
	target.WriteBool(mVisible);
	target.Write(mTransAlpha);
	target.WritePointer(mMovable);
	target.WritePointer(mHelpMovable);
	target.WriteBool(mShowHelpMovable);

	PX2_END_DEBUG_STREAM_SAVE(Actor, target);
}
示例#10
0
//----------------------------------------------------------------------------
void Scene::Save (OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	Netable::Save(target);

	target.Write<int>(mSceneID);

	target.WritePointer(mSceneNode);

	const int numActors = (int)mActors.size();
	target.Write(numActors);
	for (int i=0; i<numActors; ++i)
	{
		if (mActors[i])
		{
			target.WritePointer(mActors[i]);
		}
		else
		{
			target.WritePointer((Actor*)0);
		}
	}
	target.WritePointer(mTerrainActor);

	target.WritePointer(mDefaultLight);
	target.WritePointer(mDefaultCameraActor);
	target.WritePointer(mDefaultARActor);

	PX2_END_DEBUG_STREAM_SAVE(Scene, target);
}
示例#11
0
//----------------------------------------------------------------------------
void SkyActor::Save (OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	Actor::Save(target);
	target.WritePointer(mSky);

	PX2_END_DEBUG_STREAM_SAVE(SkyActor, target);
}
//----------------------------------------------------------------------------
void SMShadowEffect::Save (OutStream& target) const
{
    WM5_BEGIN_DEBUG_STREAM_SAVE(target);

    GlobalEffect::Save(target);

    target.WritePointer(mInstance);

    WM5_END_DEBUG_STREAM_SAVE(SMShadowEffect, target);
}
示例#13
0
//----------------------------------------------------------------------------
void BillboardNode::Save (OutStream& target) const
{
    WM5_BEGIN_DEBUG_STREAM_SAVE(target);

    Node::Save(target);

    target.WritePointer(mCamera);

    WM5_END_DEBUG_STREAM_SAVE(BillboardNode, target);
}
示例#14
0
//----------------------------------------------------------------------------
void RawTerrain::Save (OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	Terrain::Save(target);

	target.WritePointer(mVFormat);
	for (int row = 0; row < mNumRows; ++row)
	{
		for (int col = 0; col < mNumCols; ++col)
		{
			target.WritePointer(mPages[row][col]);
		}
	}

	target.WritePointer(mShine);

	PX2_END_DEBUG_STREAM_SAVE(RawTerrain, target);
}
//----------------------------------------------------------------------------
void ProjectorWorldPositionConstant::Save (OutStream& target) const
{
    WM5_BEGIN_DEBUG_STREAM_SAVE(target);

    ShaderFloat::Save(target);

    target.WritePointer(mProjector);

    WM5_END_DEBUG_STREAM_SAVE(ProjectorWorldPositionConstant, target);
}
//----------------------------------------------------------------------------
void LightSpecularConstant::Save (OutStream& target) const
{
	WM5_BEGIN_DEBUG_STREAM_SAVE(target);

	ShaderFloat::Save(target);

	target.WritePointer(mLight);

	WM5_END_DEBUG_STREAM_SAVE(LightSpecularConstant, target);
}
示例#17
0
//----------------------------------------------------------------------------
void LightNode::Save (OutStream& target) const
{
    WM5_BEGIN_DEBUG_STREAM_SAVE(target);

    Node::Save(target);

    target.WritePointer(mLight);

    WM5_END_DEBUG_STREAM_SAVE(LightNode, target);
}
//----------------------------------------------------------------------------
void LightAmbientConstant::Save (OutStream& target) const
{
    PX2_BEGIN_DEBUG_STREAM_SAVE(target);

    ShaderFloat::Save(target);

    target.WritePointer(mLight);

    PX2_END_DEBUG_STREAM_SAVE(LightAmbientConstant, target);
}
//----------------------------------------------------------------------------
void BlendedTerrainEffect::Save (OutStream& target) const
{
    WM5_BEGIN_DEBUG_STREAM_SAVE(target);

    VisualEffect::Save(target);

    target.WritePointer(mBlendTexture);

    WM5_END_DEBUG_STREAM_SAVE(BlendedTerrainEffect, target);
}
//----------------------------------------------------------------------------
void MaterialEmissiveConstant::Save (OutStream& target) const
{
    WM5_BEGIN_DEBUG_STREAM_SAVE(target);

    ShaderFloat::Save(target);

    target.WritePointer(mMaterial);

    WM5_END_DEBUG_STREAM_SAVE(MaterialEmissiveConstant, target);
}
示例#21
0
//----------------------------------------------------------------------------
void UIFText::Save(OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	UIFrame::Save(target);
	PX2_VERSION_SAVE(target);

	target.WritePointer(mText);

	PX2_END_DEBUG_STREAM_SAVE(UIFText, target);
}
//----------------------------------------------------------------------------
void ShineDiffuseConstant::Save (OutStream& target) const
{
    PX2_BEGIN_DEBUG_STREAM_SAVE(target);

    ShaderFloat::Save(target);
	PX2_VERSION_SAVE(target);

    target.WritePointer(mShine);

    PX2_END_DEBUG_STREAM_SAVE(ShineDiffuseConstant, target);
}
示例#23
0
//----------------------------------------------------------------------------
void ShaderParameters::Save (OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	Object::Save(target);

	target.WritePointer(mShader);
	target.WritePointerW(mNumConstants, mConstants);
	target.WritePointerW(mNumTextures, mTextures);

	PX2_END_DEBUG_STREAM_SAVE(ShaderParameters, target);
}
//----------------------------------------------------------------------------
void ProjectorMatrixConstant::Save (OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	ShaderFloat::Save(target);
	PX2_VERSION_SAVE(target);

	target.WritePointer(mProjector);
	target.WriteBool(mBiased);

	PX2_END_DEBUG_STREAM_SAVE(ProjectorMatrixConstant, target);
}
示例#25
0
//----------------------------------------------------------------------------
void LightConstant::Save(OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	ShaderFloat::Save(target);
	PX2_VERSION_SAVE(target);

	target.WritePointer(mLight);
	target.WriteBool(mIsDefualtDir);

	PX2_END_DEBUG_STREAM_SAVE(LightConstant, target);
}
示例#26
0
//----------------------------------------------------------------------------
void RenderTarget::Save (OutStream& target) const
{
    WM5_BEGIN_DEBUG_STREAM_SAVE(target);

    Object::Save(target);

    target.WritePointerW(mNumTargets, mColorTextures);
    target.WritePointer(mDepthStencilTexture);
    target.WriteBool(mHasMipmaps);

    WM5_END_DEBUG_STREAM_SAVE(RenderTarget, target);
}
示例#27
0
//----------------------------------------------------------------------------
void Terrain::Save (OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	Node::Save(target);

	target.Write(mNumRows);
	target.Write(mNumCols);
	target.Write(mSize);
	target.Write(mMinElevation);
	target.Write(mMaxElevation);
	target.Write(mSpacing);

	for (int row = 0; row < mNumRows; ++row)
	{
		for (int col = 0; col < mNumCols; ++col)
		{
			target.WritePointer(mPages[row][col]);
		}
	}

	target.WriteBool(mIsUseSimpleMtl);
	target.WritePointer(mVFormatEdit);
	target.WritePointer(mVFormatSimple);
	target.WritePointer(mMtlEdit);
	target.WritePointer(mMtlSimple);
	target.WritePointer(mShine);
	target.Write(mJunglerFrequency);
	target.Write(mJunglerStrength);

	PX2_END_DEBUG_STREAM_SAVE(Terrain, target);
}
示例#28
0
//----------------------------------------------------------------------------
void TerrainActor::Save(OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	Actor::Save(target);
	PX2_VERSION_SAVE(target);

	target.WriteBool(mIsUseLOD);
	target.WritePointer(mRawTerrain); 
	target.WritePointer(mLODTerrain);

	PX2_END_DEBUG_STREAM_SAVE(TerrainActor, target);
}
//----------------------------------------------------------------------------
void PlanarShadowEffect::Save (OutStream& target) const
{
	WM5_BEGIN_DEBUG_STREAM_SAVE(target);

	GlobalEffect::Save(target);

	target.WriteAggregateW(mNumPlanes, mShadowColors);
	target.WritePointerN(mNumPlanes, mPlanes);
	target.WritePointerN(mNumPlanes, mProjectors);
	target.WritePointer(mShadowCaster);

	WM5_END_DEBUG_STREAM_SAVE(PlanarShadowEffect, target);
}
示例#30
0
//----------------------------------------------------------------------------
void ClodMesh::Save (OutStream& target) const
{
	PX2_BEGIN_DEBUG_STREAM_SAVE(target);

	TriMesh::Save(target);
	PX2_VERSION_SAVE(target);

	target.Write(mCurrentRecord);
	target.Write(mTargetRecord);
	target.WritePointer(mRecordArray);

	PX2_END_DEBUG_STREAM_SAVE(ClodMesh, target);
}