Skip to content

Commit e3b15aa

Browse files
author
Rob Sanderson
committed
UnitQuantityMeasureAmountExtentValue
1 parent 36f4d9e commit e3b15aa

File tree

1 file changed

+48
-41
lines changed

1 file changed

+48
-41
lines changed

source/presentation/4.0/model.md

Lines changed: 48 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -836,9 +836,9 @@ Spot Lights _MAY_ have the following additional properties: [lookAt](#lookAt)
836836
"color": "#FFFFFF",
837837
"intensity": {
838838
"id": "https://example.org/iiif/spotlight/1/value",
839-
"type": "UnitValue",
839+
"type": "Quantity",
840840
"unit": "relative",
841-
"value": 0.5
841+
"quantityValue": 0.5
842842
}
843843
}
844844
```
@@ -923,9 +923,9 @@ Spot Audio Emitters _MAY_ have the following additional properties: [lookAt](#lo
923923
"angle": 45.0,
924924
"volume": {
925925
"id": "https://example.org/iiif/value/1",
926-
"type": "UnitValue",
926+
"type": "Quantity",
927927
"unit": "relative",
928-
"value": 1.0
928+
"quantityValue": 1.0
929929
}
930930
}
931931
```
@@ -1065,24 +1065,24 @@ Services will also have specific requirements as to additional properties based
10651065
{: .note}
10661066

10671067

1068-
#### Unit Value
1069-
{: #UnitValue}
1068+
#### Quantity
1069+
{: #Quantity}
10701070

1071-
> `"type": "UnitValue"`
1071+
> `"type": "Quantity"`
10721072
1073-
A UnitValue expresses a quantity through a numerical value and associated unit of measurement. The value of `unit` _MUST_ be drawn from the list of possible units, or a registered extension.
1073+
A Quantity expresses a quantity through a numerical value and associated unit of measurement. The value of `unit` _MUST_ be drawn from the list of possible units, or a registered extension.
10741074

10751075
__Properties__<br/>
1076-
A Unit Value _MUST_ have the following properties: [type](#type), [value](#value), and [unit](#unit).<br/><br/>
1077-
A Unit Value _MAY_ have the following properties: [id](#id) and [label](#label).
1076+
A Quantity _MUST_ have the following properties: [type](#type), [quantityValue](#value), and [unit](#unit).<br/><br/>
1077+
A Quantity _MAY_ have the following properties: [id](#id) and [label](#label).
10781078
{: .note}
10791079

10801080
{% include api/code_header.html %}
10811081
```json
10821082
{
10831083
"id": "https://example.org/iiif/unit/2",
1084-
"type": "UnitValue",
1085-
"value": 1.0,
1084+
"type": "Quantity",
1085+
"quantityValue": 1.0,
10861086
"unit": "m"
10871087
}
10881088
```
@@ -1522,11 +1522,11 @@ A floating point number giving the time of the point in seconds from the beginni
15221522
### intensity
15231523
{: #intensity}
15241524

1525-
This property sets the strength or brightness of a Light. The `value` of the referenced UnitValue indicates the desired intensity on a linear scale between 0.0 (no brightness) and 1.0 (as bright as the client will render). If this property is not specified, then the default intensity value is client-dependent.
1525+
This property sets the strength or brightness of a Light. The `value` of the referenced Quantity indicates the desired intensity on a linear scale between 0.0 (no brightness) and 1.0 (as bright as the client will render). If this property is not specified, then the default intensity value is client-dependent.
15261526

1527-
The value of this proerty _MUST_ be a UnitValue.
1528-
The `unit` property of the UnitValue _MUST_ be `relative`.
1529-
The `value` property of the UnitValue _MUST_ be between 0.0 and 1.0.
1527+
The value of this property _MUST_ be a Quantity.
1528+
The `unit` property of the Quantity _MUST_ be `relative`.
1529+
The `value` property of the Quantity _MUST_ be between 0.0 and 1.0.
15301530

15311531
* A Light _SHOULD_ have the `intensity` property.<br/>
15321532
Clients _SHOULD_ process the `intensity` property on a Light.
@@ -1535,8 +1535,8 @@ The `value` property of the UnitValue _MUST_ be between 0.0 and 1.0.
15351535
{
15361536
"intensity": {
15371537
"id": "https://example.org/iiif/intensity/1",
1538-
"type": "UnitValue",
1539-
"value": 0.5,
1538+
"type": "Quantity",
1539+
"quantityValue": 0.5,
15401540
"unit": "relative"}
15411541
}
15421542
```
@@ -2088,14 +2088,15 @@ The value of the quality parameter in the IIIF Image API URL structure, as recor
20882088
{ "quality": "default" }
20892089
```
20902090

2091-
### quantity
2091+
### quantityValue
2092+
{: #quantityValue}
20922093

2093-
The `quantity` property of a Unit Value conveys its numerical component.
2094+
The `quantityValue` property of a Quantity conveys its numerical component.
20942095

2095-
The value _MUST_ be a floating point number.
2096+
The value of `quantityValue` _MUST_ be a floating point number.
20962097

2097-
* A UnitValue _MUST_ have the `quantity` property.<br/>
2098-
Clients _MUST_ process the `quantity` property on a Unit Value.
2098+
* A Quantity _MUST_ have the `quantity` property.<br/>
2099+
Clients _MUST_ process the `quantity` property on a Quantity.
20992100

21002101
{% include api/code_header.html %}
21012102
``` json-doc
@@ -2386,26 +2387,27 @@ The value _MUST_ be a string, and the value _MUST_ be a URI.
23862387
### spatialScale
23872388
{: #spatialScale}
23882389

2389-
A single UnitValue that defines a real-world scale factor for the coordinate units of a Canvas or Scene. For a Canvas, this defines the physical distance corresponding to the length of a single Canvas coordinate unit. A Canvas with a `width` of 5000 and a `spatialScale` with `quantity` 0.00008 represents a physical space 0.4 meters wide. For a Scene, this defines the physical distance corresponding to the XYZ coordinate units, or in other words, the physical distance length of a unit vector in the 3D coordinate space. The value of `unit` _MUST_ be a length unit. In this specification, the only length unit defined is `m`, i.e., meters. Unless other values are defined externally as an [extension][prezi30-ldce], the value of `unit` _SHOULD_ always be `m`.
2390+
A single Quantity that defines a real-world scale factor for the coordinate units of a Canvas or Scene. For a Canvas, this defines the physical distance corresponding to the length of a single Canvas coordinate unit. A Canvas with a `width` of 5000 and a `spatialScale` with `quantityValue` 0.00008 represents a physical space 0.4 meters wide. For a Scene, this defines the physical distance corresponding to the XYZ coordinate units, or in other words, the physical distance length of a unit vector in the 3D coordinate space. The value of `unit` _MUST_ be a length unit. In this specification, the only length unit defined is `m`, i.e., meters. Unless other values are defined externally as an [extension][prezi30-ldce], the value of `unit` _SHOULD_ always be `m`.
23902391

23912392
To assert a `spatialScale` for a Content Resource, the resource _MUST_ first be painted into a Container and the `spatialScale` is asserted on that Container. For example, a 3d model would be painted into a Scene, and then `spatialScale` is asserted on the Scene.
23922393

2394+
* A Canvas _MAY_ have the `spatialScale` property.<br/>
2395+
Clients _SHOULD_ process `spatialScale` on a Canvas.
2396+
* A Scene _MAY_ have the `spatialScale` property.<br/>
2397+
Clients _SHOULD_ process `spatialScale` on a Scene.
2398+
23932399
{% include api/code_header.html %}
23942400
``` json-doc
23952401
{
23962402
"type": "Scene",
23972403
"spatialScale": {
2398-
"type": "UnitValue",
2399-
"quantity": 22.0,
2404+
"type": "Quantity",
2405+
"quantityValue": 22.0,
24002406
"unit": "m"
24012407
}
24022408
}
24032409
```
24042410

2405-
* A Canvas _MAY_ have the `spatialScale` property.<br/>
2406-
Clients _SHOULD_ process `spatialScale` on a Canvas.
2407-
* A Scene _MAY_ have the `spatialScale` property.<br/>
2408-
Clients _SHOULD_ process `spatialScale` on a Scene.
24092411

24102412
### start
24112413
{: #start}
@@ -2555,7 +2557,7 @@ The value _MUST_ be an array of JSON objects.
25552557
### temporalScale
25562558
{: #temporalScale}
25572559

2558-
A single UnitValue that defines a multiplier or scale factor for the `duration` property of a Container, indicating that one second in "Container time" represents some other real world duration. A Canvas with a `duration` of 450 seconds and a `temporalScale` with `quantity` 1000 represents a real-world duration of 450,000 seconds (5.2 days), for example a time-lapse video of a growing plant. The value of `unit` _MUST_ be a time unit. In this specification, the only time unit defined is `s`, i.e., seconds. Unless other values are defined externally as an [extension][prezi30-ldce], the value of `unit` _SHOULD_ always be `s`.
2560+
A single Quantity that defines a multiplier or scale factor for the `duration` property of a Container, indicating that one second in "Container time" represents some other real world duration. A Canvas with a `duration` of 450 seconds and a `temporalScale` with `quantityValue` 1000 represents a real-world duration of 450,000 seconds (5.2 days), for example a time-lapse video of a growing plant. The value of `unit` _MUST_ be a time unit. In this specification, the only time unit defined is `s`, i.e., seconds. Unless other values are defined externally as an [extension][prezi30-ldce], the value of `unit` _SHOULD_ always be `s`.
25592561

25602562
To assert a `temporalScale` for a Content Resource, the resource _MUST_ first be painted into a Container with a `duration` and the `temporalScale` is asserted on that Container. For example, an Audio file is painted into a Timeline, and then `temporalScale` is asserted on the Timeline.
25612563

@@ -2572,8 +2574,8 @@ To assert a `temporalScale` for a Content Resource, the resource _MUST_ first be
25722574
{
25732575
"type": "Canvas",
25742576
"temporalScale": {
2575-
"type": "UnitValue",
2576-
"quantity": 1000,
2577+
"type": "Quantity",
2578+
"quantityValue": 1000,
25772579
"unit": "s"
25782580
}
25792581
}
@@ -2717,7 +2719,7 @@ For compatibility with previous versions, clients _SHOULD_ accept `Sound` as a s
27172719

27182720
### unit
27192721

2720-
The unit of measurement of a quantity expressed by a UnitValue.
2722+
The unit of measurement of a quantity expressed by a Quantity.
27212723

27222724
The value _MUST_ be a string value. This specification defines the values in the table below. Others may be defined externally as an [extension][prezi30-ldce].
27232725

@@ -2727,9 +2729,14 @@ The value _MUST_ be a string value. This specification defines the values in th
27272729
| s | seconds |
27282730
| relative | relative |
27292731

2730-
* A UnitValue _MUST_ have the `unit` property
2732+
* A Quantity _MUST_ have the `unit` property.<br/>
2733+
Clients _SHOULD_ process the `unit` property on Quantity instances.
2734+
2735+
{% include api/code_header.html %}
2736+
``` json-doc
2737+
{ "unit": "m" }
2738+
```
27312739

2732-
FIXME: possible values are 'm' and 's' and 'relative'. Is relative always 0-1.0, or context-dependent (see def of intensity)? Allow extensions?
27332740

27342741
### value
27352742

@@ -2805,18 +2812,18 @@ The value _MUST_ be a string.
28052812
### volume
28062813
{: #volume}
28072814

2808-
The volume property represents the relative volume of an audio source. The `value` of the specified UnitValue represents the desired volume on a linear scale from 0.0 (silence) to 1.0 (maximum volume). If this property is not specified, then the default volume value is client-dependent.
2815+
The volume property represents the relative volume of an audio source. The `quantityValue` of the specified Quantity represents the desired volume on a linear scale from 0.0 (silence) to 1.0 (maximum volume). If this property is not specified, then the default volume value is client-dependent.
28092816

2810-
The value of this property _MUST_ be a UnitValue.
2811-
The `unit` property of the UnitValue _MUST_ be `relative`.
2812-
The `value` property of the UnitValue _MUST_ be between 0.0 and 1.0.
2817+
The value of this property _MUST_ be a Quantity.
2818+
The `unit` property of the Quantity _MUST_ be `relative`.
2819+
The `value` property of the Quantity _MUST_ be between 0.0 and 1.0.
28132820

28142821
* Audio resource types _SHOULD_ have the `volume` property.<br/>
28152822
Clients _SHOULD_ process the `volume` property on an Audio resource.
28162823

28172824
{% include api/code_header.html %}
28182825
``` json-doc
2819-
{ "volume": { "unit": "relative", "value": 0.5 } }
2826+
{ "volume": { "type": "Quantity", "unit": "relative", "quantityValue": 0.5 } }
28202827
```
28212828

28222829

0 commit comments

Comments
 (0)