dataFileUtils
(For high level concepts about how to use Lua to write scripted tasks, please see VR-Forces User's Guide.)
Contains utility functions for reading data from text files. To use, add this to the beginning of your script:
local fUtil = require "fileUtils"
locTable = fUtil.getPointsFromFile(filename)
Function List
| getPointsFromFile (fileName) | Reads a series of geocentric points from a text file and returns a table of Location3D objects representing each point. |
Functions
- getPointsFromFile (fileName)
-
Reads a series of geocentric points from a text file and returns a table of Location3D objects representing each point. Only one point is expected per line. This function is designed to work with the geocentric values printed by DtVector::string() in VR-Forces:
{ 1339076.331, -4652336.450, 4138579.354}Other formats of geocentric coordinates will also work, as it simply takes the first 3 decimal values found on the line.Parameters:
-
fileName:
-
