Ticket #928 (closed task: worksforme)

Opened 5 years ago

Last modified 2 years ago

soy.scenes.Planar

Reported by: ArcRiley Owned by: DavidCzech
Priority: Medium Milestone: beta4
Component: soy.scenes Version: Trunk
Keywords: Cc:

Description

This class will inherit from soy.scenes.Scene and add a ODE collision plane rendered as a large plane of the same size. It is important to note that the plane is a part of the scene itself, not a body.

The plane faces up in the direction of scene gravity, or in the Y axis if no gravity is used, and will have a size parameter accepting two elements.

The center of the plane will always be (0,0,0) unless a simple property allows otherwise.

The plane will have a .material property for changing the material. A second property may allow the texcoords to be something other that (0.0,0.0,1.0,1.0).

The plane will be a poly grid (triangles, quads, etc) such that specularity and other effects work as expected.

Lastly, a simple example should be written to render spheres on it with one of the spheres controlled by the keyboard, or a similarly basic example of how a plane works.

Attachments

qh.png Download (13.8 KB) - added by ArcRiley 5 years ago.
visual mockup

Change History

comment:1 Changed 5 years ago by DavidCzech

  • Owner set to DavidCzech

Changed 5 years ago by ArcRiley

visual mockup

comment:2 Changed 5 years ago by ArcRiley

Here is a mockup for one possible way to render the plane.

In this mockup, 1024 triangle units are rendered with only 16 tri's.

Likewise, 4096 would be rendered with only 19 tri's, 16384 with only 22, 65536 with only 25, 262144 with only 28 tri's, and a whopping 1048576 (> 1 million) with only 31. This pattern can continue to render billions of triangle units with less than 50 triangles.

Obviously the larger triangles (further out) should be rendered first.

visual mockup

comment:3 Changed 5 years ago by DavidCzech

  • Status changed from new to closed
  • Resolution set to worksforme
  • Summary changed from soy.scenes.Plane to soy.scenes.Planar

Done for Beta-3, but could use some work:

  • Correct Tex-coord generation
  • Optimize Vertex / Face generation ( Some Verticies could be used more than once)
  • Implement Bumpmapping
  • Allow 'Earthquakes' to be applied

comment:4 Changed 2 years ago by ArcRiley

  • Milestone changed from beta3 to beta4
Note: See TracTickets for help on using tickets.