#declare Y_Ground = (223/255)*4;
#declare RiverBankTranslateVector = < 0, 0, -2 >;

#declare HF_RiverBank = height_field{
						png "heightFields/wjr_riverBank.png"
						smooth
                        water_level 0.001
                        translate <-0.5, 0, -0.5> scale <160, 4, 80> 
                        translate RiverBankTranslateVector
					}
					
#declare HF_Mountain = height_field{
						png "heightFields/mountain1.png"
						smooth
					   }
					   
#declare HF_fileResolution = 1280;
#declare LeftPosBank = 896;
#declare RightPosBank = 832;

#declare RiverBankLeftSurroundingBox = box{<-160, 0, -(LeftPosBank - HF_fileResolution/2) * 40 / (HF_fileResolution/2) >,< -80, 223/255*4, 40 >}//Left of river bank
#declare RiverBankRightSurroundingBox = box{<160, 0, -(RightPosBank - HF_fileResolution/2) * 40 / (HF_fileResolution/2) >,< 80, 223/255*4, 40> }//Right of river bank 

#declare RiverBankSurroundings = union{
                                       object{ RiverBankLeftSurroundingBox }
                                       object{ RiverBankRightSurroundingBox }
                                       box{< -4000, 0, 40 >,< 4000, 223 / 255 * 4, 8000 >} //Background 
                                       translate RiverBankTranslateVector
                                 }

#declare GrassBladeGround = union{
								object{ HF_RiverBank translate -RiverBankTranslateVector}
								object{ RiverBankLeftSurroundingBox }
								object{ RiverBankRightSurroundingBox }
							}

#declare MountainC = object{HF_Mountain translate <-0.5,0,-0.5>              scale <2048, 512, 512> translate <0, -64, 2048> texture{MountainSlopeTexture} }
#declare MountainA = object{HF_Mountain translate <-0.5,0,-0.5> rotate 90*y  scale <1792, 512, 768> translate <768, -64, 1536> texture{MountainSlopeTexture} }
#declare MountainB = object{HF_Mountain translate <-0.5,0,-0.5> rotate 180*y scale <1536, 512, 512> translate <-768, -64, 1536> texture{MountainSlopeTexture} }
#declare MountainD = object{HF_Mountain translate <-0.5,0,-0.5>              scale <1536, 512, 512> translate <-2048, -64, 2560> texture{MountainSlopeTexture} }
#declare MountainE = object{HF_Mountain translate <-0.5,0,-0.5> rotate 90*y  scale <1792, 512, 768> translate <2048, -64, 2560> texture{MountainSlopeTexture} }  

#declare PathWayRadius = (255 - 223) / 255 * 4;
#declare PathWayCenter = 0;
#declare PathWayWidth = 4;

#declare PathWay = union{
						cylinder{<-120, 3.95 - PathWayRadius, 0 >, < 0, 3.95 - PathWayRadius, 0 >, PathWayRadius }
						cylinder{<-120, 3.95 - PathWayRadius, -PathWayWidth >, < 0, 3.95 - PathWayRadius, -PathWayWidth >, PathWayRadius }
						box{< -120, 3.95, 0 >,< 0, 0, -PathWayWidth > }
						texture{ T_brown4 }
					}