Measurement units, including imperial and SI units

View versions (1)

Interface

#include <codecogs/units/convert/light.h>

using namespace Units::Convert;

Overview

The standard measurement units are:

Unit names Alternate names / spellings Abbreviation Enumeration Code Conversion Rate (relative to first unit)
Light
Lux Lux lx unit_lx 1
Flames Flame fl unit_fl 0.02322576
Footcandles Feetcandles fc unit_fc 0.09290304
Meter-candles Metre-candles mc unit_mc 1
GPL Licence — free for non commercial use. See Licence details.

FUNCTION

light

Converts a numbers from one light unit to another.

Example 1

#include <iostream>
#include <codecogs/units/convert/light.h>

using namespace Units::Convert;
int main()
{
  std::cout << "light(10.2,unit_m, unit_ft)=" << light(10.2,unit_m, unit_ft);

  return 0;
}

Output:

light(123, unit_W, unit_HP)= 0.013678405

Parameters

number
the value in from_unit 's to convert
from_unit
an enumerated value of the initial light type
to_unit
an emuerated value of the output light type

Returns

the value in the converted unit.