(lines ln.Paths, matrix ln.Matrix)
| 61 | } |
| 62 | |
| 63 | func Render(lines ln.Paths, matrix ln.Matrix) ln.Paths { |
| 64 | scene := ln.Scene{} |
| 65 | sphere := ln.NewSphere(ln.Vector{}, 1) |
| 66 | earth := Earth{sphere, lines} |
| 67 | shape := ln.NewTransformedShape(&earth, matrix) |
| 68 | scene.Add(shape) |
| 69 | eye := ln.LatLngToXYZ(35.7806, -78.6389, 1).Normalize().MulScalar(2.46) |
| 70 | center := ln.Vector{} |
| 71 | up := ln.Vector{0, 0, 1} |
| 72 | return scene.Render(eye, center, up, 60, 1, 0.1, 100, 0.01) |
| 73 | } |
| 74 | |
| 75 | func Circle(r float64) ln.Path { |
| 76 | var result ln.Path |