Jump to content

Ocean submarine test


shadmar
 Share

Recommended Posts

owww bummer - tiles might match but its seams like the wave calculation is not tilable but iam no expert either ... you might can interpolate vertex.y like in the curve function ?!

 

You can use a simple linepick from above to below waterpatch to place stuff at the intersecting point - however, sice the sender knows nothing about the receiver and the receiver usually doesnt care about any stuff the sender might tries to archive the user in question might have to come up with its own kind of filter to get rid of failures forwarded into space by the sender.

 

Ps :

there was a (very) early preview of sea waves [in] le3d which appearance a little more realistic, however afaik

AMD 64 X2 Dual 5k - 4GB - XFX GForce9800GT - nv196.21 - WinXP Sp3

zBrush4R2 - Silo2Pro - Unwrap3DPro - Gile - MaPZone2.5

 

adv_banner-april2012_720x150_tex01.png

 

Xxploration FPS in progress ...

Link to comment
Share on other sites

Guest Red Ocktober

i managed to get a 3x3 tiled surface to line up perfectly without to much trouble in my cpu based waves...

 

'--------------------------------------------------  ANIMATE THE WAVES IF WATERMODE
'
Function AnimateWaves(theWater:TMesh)
  Local vertex:TVec3[2181]
  Local theWaves:TSurface
  Local waveFreq:Float
  theWaves=GetSurface(theWater,1)
For Local i:Int =0 To 2177
  Local waveFreq:Float=MilliSecs()/20
  vertex[i]=GetVertexPosition(theWaves,i)
  vertex[i].y=Sin( waveFreq+vertex[i].x*50 + vertex[i].z*30)*(GAME.seaState*4)
  SetVertexPosition (theWaves,i,vertex[i])
Next
EndFunction

'--------------------------------------------------  MOVE OCEAN WITH VIEW IF WATERMODE
'
Function SyncOceanToView()

	  Local patchPos:TVec3 =EntityPosition(Game.fw.Main.camera)

	  Local dist:Float = Game.oldViewLocation.DistanceTo(game.viewLocation)
	If(dist>340)
	  patchPos.y=game.waterheight-3
	  PositionEntity GAME.fw.renderer.waterpatch,patchPos

	  patchPos.y=GAME.waterheight

	  patchPos.x=Game.ViewLocation.x-340
	  patchPos.z=Game.ViewLocation.z+340
 PositionEntity GAME.fw.renderer.waterpatch1,patchPos

	  patchPos.x=Game.ViewLocation.x
	  patchPos.z=Game.ViewLocation.z+340  
 PositionEntity GAME.fw.renderer.waterpatch2,patchPos

	  patchPos.x=Game.ViewLocation.x+340
	  patchPos.z=Game.ViewLocation.z+340  
 PositionEntity GAME.fw.renderer.waterpatch3,patchPos

	  patchPos.x=Game.ViewLocation.x-340
	  patchPos.z=Game.ViewLocation.z  
 PositionEntity GAME.fw.renderer.waterpatch4,patchPos

	  patchPos.x=Game.ViewLocation.x
	  patchPos.z=Game.ViewLocation.z  
 PositionEntity GAME.fw.renderer.waterpatch5,patchPos

	  patchPos.x=Game.ViewLocation.x+340
	  patchPos.z=Game.ViewLocation.z
 PositionEntity GAME.fw.renderer.waterpatch6,patchPos

	  patchPos.x=Game.ViewLocation.x-340
	  patchPos.z=Game.ViewLocation.z-340  
 PositionEntity GAME.fw.renderer.waterpatch7,patchPos

	  patchPos.x=Game.ViewLocation.x
	  patchPos.z=Game.ViewLocation.z-340  
 PositionEntity GAME.fw.renderer.waterpatch8,patchPos

	  patchPos.x=Game.ViewLocation.x+340
	  patchPos.z=Game.ViewLocation.z-340  
 PositionEntity GAME.fw.renderer.waterpatch9,patchPos	
	  Game.oldViewLocation=EntityPosition(Game.fw.Main.camera)
	  Game.oldViewLocation.y=Game.waterHeight
	  Game.centerOceanPatchLoc=Game.oldViewLocation
	  Game.centerOceanIndex=5
	  Game.IsOceanSyncedToView=True
 EndIf
End Function

 

i'm gonna try basically the same approach with this...

 

Shad... those screenshots look better and better with each iteration...

 

--Mike

Link to comment
Share on other sites

Hmm... well xz and y displacement with 12 aggregated waves, makes not perfectly tilable.

If you still want it I can upload it in it's current state. I tried with some skirts but you can still notice.

But I guess an adaptive mesh would maybe solve this, but that's beyond my programming skills.

Max mesh size are 32k triangles, I get all sorts of distortion if I go any higher.

HP Omen - 16GB - i7 - Nvidia GTX 1060 6GB

Link to comment
Share on other sites

Ok it's in the store now, let me know if it works smile.png

Checking it out now. smile.png

Thanks a lot, man! Nice work!

 

Cheers

 

ZBrush 4R7 64-bit - 3DCoat 4.5 BETA 12 - Fl Studio 12 64Bit - LE 3.2 Indie version - Truespace 7 - Blender 2.71 - iClone 5.51 Pro - iClone 3DXChange 5.51 pipeline - Kontakt 5 - Bryce 7 - UU3D Pro - Substance Designer/Painter - Shadermap 3 - PaintShop Photo Pro X7 - Hexagon - Audacity - Gimp 2.8 - Vue 2015 - Reaktor 5 - Guitar Rig 5 - Bitmap2Material 3

Link to comment
Share on other sites

One more thing, the mesh has skirts, but the skirt normals points straight up to minimize tiling visibility.

 

And... forgot to change the deafults

For best look with deafult skybox, set cubemap blend to 0.35 and bump to 0.3 and normal to 0.5 - fixed and reuploaded.

 

Should look like this then:

 

LE_ocean10.jpg

HP Omen - 16GB - i7 - Nvidia GTX 1060 6GB

Link to comment
Share on other sites

Hum...for some reason, I can't get it to work. sad.png

I did as mentioned, copied the shaders in the 'mesh' folder of the shaders.pak, and put the 'ocean' folder in the 'Models' folder. I can see and put the ocean patch in the editor, but I only see a transparent red plane. I've matched the skybox material of the atmosphere to the one in the ocean material, but no changes. Also, when I click the checkbox 'Active' in the 'General' settings of the ocean and click apply, the name of the ocean patch dissappears. Very weird.unsure.png

 

EDIT: clicking apply makes the ocean (red plane) dissappear, and also the name.

 

Any ideas/suggestions? Thanks.

 

ZBrush 4R7 64-bit - 3DCoat 4.5 BETA 12 - Fl Studio 12 64Bit - LE 3.2 Indie version - Truespace 7 - Blender 2.71 - iClone 5.51 Pro - iClone 3DXChange 5.51 pipeline - Kontakt 5 - Bryce 7 - UU3D Pro - Substance Designer/Painter - Shadermap 3 - PaintShop Photo Pro X7 - Hexagon - Audacity - Gimp 2.8 - Vue 2015 - Reaktor 5 - Guitar Rig 5 - Bitmap2Material 3

Link to comment
Share on other sites

Guest Red Ocktober

works fine here (2.50) with one or two small things...

 

name property and y position won't persist after i close properties dialogue...

 

also, checkbox for active remains unchecked...

 

otherwise, ocean looks great...

 

still looking...

 

oh yeah... almost forgot in my haste BIG THANKS for this...

 

more...

x and z positions work...

second test neither x,y,z position properties persist...

 

what's the dimensions of the mesh?

 

 

--Mike

Link to comment
Share on other sites

Can you change the transparency of the water? I can't try it out till Monday cause of a lack of computers, and I was just wondering. I was playing Uncharted 3 and there is this map where it is a couple shipwrecks in water and you can swim around, and you can see about 10 feet into the water before it gets cloudy. Is this possible with shaders? Josh's waterplane got transparent when you set the softness at the right amount and looked down at it, that effect was very well done and I am wondering if maybe you reused some of his code? So you could see some fish in the water close to the surface, but not very deep. It would add that last bit of realism. So I guess my question is: Can you make it transparent, and if so how advanced is that transparency? And what does it look like underwater?

Windows 7 Professional 64 bit, 16 gigs ram, 3.30GHz Quad Core, GeForce GTX 460 one gig, Leadwerks 2.5, Blender 2.62, Photoshop CS3, UU3D

Link to comment
Share on other sites

Not in the current version, maybe in a later version, its just an wavy mesh for now, no underwater or transparency. Haven't figured out how transpericy in the shaders works (refraction) I seem to get reflection or some distortion. Ah well learing from the existing shadersis hard :)

HP Omen - 16GB - i7 - Nvidia GTX 1060 6GB

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...