INNER CODE UNIT · Go

aspect

g3n/g3nd · app/app.go:129

	aspect := float32(width) / float32(height)
	a.camera = camera.New(aspect)
	a.scene.Add(a.camera) // Add camera to scene (important for audio demos)
	a.orbit = camera.NewOrbitControl(a.camera)

	// Create and add ambient light to scene
	a.ambLight = light.NewAmbient(&math32.Color{1.0, 1.0, 1.0}, 0.5)
	a.scene.Add(a.ambLight)

	// Create frame rater
	a.frameRater = util.NewFrameRater(*oTargetFPS)

	flag.Usage = usage // Sets the application usage
	flag.Parse()       // Parse command line flags

	// Apply log levels to engine package loggers
	if *oLogs != "" {
		logs := strings.Split(*oLogs, ",")

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…