MCPcopy Create free account
hub / github.com/PDAL/PDAL / addArgs

Method addArgs

io/CopcWriter.cpp:92–137  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

90}
91
92void CopcWriter::addArgs(ProgramArgs& args)
93{
94 std::time_t now;
95 std::time(&now);
96 uint16_t year = 1900;
97 uint16_t doy = 1;
98 std::tm* ptm = std::gmtime(&now);
99 if (ptm)
100 {
101 year += ptm->tm_year;
102 doy += ptm->tm_yday;
103 }
104
105 args.add("forward", "Dimensions to forward from LAS reader", b->opts.forwardSpec);
106
107 args.add("filesource_id", "File source ID number.", b->opts.filesourceId,
108 decltype(b->opts.filesourceId)(0));
109 args.add("global_encoding", "Global encoding byte", b->opts.globalEncoding,
110 decltype(b->opts.globalEncoding)(0));
111 args.add("project_id", "Project ID", b->opts.projectId);
112 args.add("system_id", "System ID", b->opts.systemId, decltype(b->opts.systemId)("PDAL"));
113 args.add("software_id", "Software ID", b->opts.softwareId,
114 decltype(b->opts.softwareId)(las::generateSoftwareId()));
115 args.add("creation_doy", "Creation day of year", b->opts.creationDoy,
116 decltype(b->opts.creationDoy)(doy));
117 args.add("creation_year", "Creation year", b->opts.creationYear,
118 decltype(b->opts.creationYear)(year));
119 args.add("scale_x", "X scale factor", b->opts.scaleX, decltype(b->opts.scaleX)(".01"));
120 args.add("scale_y", "Y scale factor", b->opts.scaleY, decltype(b->opts.scaleY)(".01"));
121 args.add("scale_z", "Z scale factor", b->opts.scaleZ, decltype(b->opts.scaleZ)(".01"));
122 args.add("offset_x", "X offset", b->opts.offsetX);
123 args.add("offset_y", "Y offset", b->opts.offsetY);
124 args.add("offset_z", "Z offset", b->opts.offsetZ);
125 args.add("vlrs", "List of VLRs to set", b->opts.userVlrs);
126 args.add("pipeline", "Emit a JSON-represetation of the pipeline as a VLR",
127 b->opts.emitPipeline);
128 args.add("pdal_metadata", "Emit a JSON-represetation of the pipeline's metadata as a VLR",
129 b->opts.emitMetadata);
130 args.add("fixed_seed", "Fix the random seed", b->opts.fixedSeed).setHidden();
131 args.add("a_srs", "Spatial reference to use to write output", b->opts.aSrs);
132 args.add("threads", "", b->opts.threadCount).setHidden();
133 args.add("enhanced_srs_vlrs", "Write WKT2 and PROJJSON as VLR?", b->opts.enhancedSrsVlrs,
134 decltype(b->opts.enhancedSrsVlrs)(false));
135 args.add("extra_dims", "List of dimension names to write in addition to those of the "
136 "point format or 'all' for all available dimensions", b->opts.extraDimSpec);
137}
138
139void CopcWriter::fillForwardList()
140{

Callers

nothing calls this directly

Calls 2

generateSoftwareIdFunction · 0.85
addMethod · 0.45

Tested by

no test coverage detected