Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can you target the whole Scene? #2254

Open
tomcrane opened this issue Jul 14, 2023 · 7 comments
Open

Can you target the whole Scene? #2254

tomcrane opened this issue Jul 14, 2023 · 7 comments
Labels
3d presentation Ready-for-Eds Editorial changes ready for Editorial review

Comments

@tomcrane
Copy link
Contributor

For the Canvas, a painting annotation can target the entire Canvas by id alone, without supplying a selector or xywh fragment shorthand. This is the 99.9…% use case for published Canvases. The implication is that the content resource fills the Canvas. But we can’t “fill” our unbounded 3D space.

Should we support the equivalent simple scenario of one 3D model in a Scene, with a painting annotation targeting the Scene by id (or by reference object with { id, type })? This seems a very useful pattern and is simple for the publisher.

    // ...
    "type": "AnnotationPage",
    "items": [
        {
            "id": "https://example.org/iiif/3d/anno1",
            "type": "Annotation",
            "motivation": [
                "painting"
            ],
            "body": {
                "id": "https://example.org/iiif/my-model.someFormat",
                "type": "Model",
                "format": "application/something"
            },
            "target": [
                "https://example.org/iiif/scene1/page/p1/1"
            ]
        }
    ]
    // ...

If so, what does this mean?

We can place the centroid of the model at the Scene’s (0,0,0) origin.

But how big is it? What are the dimensions of its bounding box?

Is this defined by the incoming model? We can take the incoming model’s “local” origin as the point that is placed at the origin (as per target issue), but can we get scale this way? (seems too loose given multitude of formats and their internal coordinate systems)?

This is important because if the Scene is later annotated (e.g., descriptive labels), those annotations need to target somewhere in the Scene, aligned with the model.

@azaroth42
Copy link
Member

I think you need to be able to target the entire scene for other reasons -- that you want to comment on it, or tag it, or use it in a content state annotation -- but the reason that it is simple for the 2d case is that there are boundaries for scaling.

Agree about the future annotations being problematic, but no more problematic than if you change the model being annotated to a larger one and don't subsequently add a scale transformation on it to bring it back to the Scene's dimensions. It just works in the bounded case ... it won't in the unbounded case. However, I think the risk is relatively low at least given the experience of 2d, as most organizations don't just silently replace their images (and by extrapolation models) with the same content at a different resolution.

We should discuss, but I would be in favor of allowing a painting annotation on the scene to be considered as at 0,0,0 (and then annotation target dependent as to what that means ... does the 2d image have it's 0,0 point at 3d space's 0,0,0?)

@JulieWinchester
Copy link
Contributor

At the Basel working meeting on October 26, 2023, there was general consensus in favor of painting annotations being able to target an entire scene via simple target reference of a Scene URI, and that doing so will place the annotation at the Scene origin (0, 0, 0). This scene origin placement behavior will not apply to comment annotations.

There was also a suggestion that potentially an OriginSelector (plus a Scene URI reference) could be used if we want to be able to explicitly designate that an annotation's target is the specific scene origin while still simplifying the manifest without needing to always specify a redundant boilerplate PointSelector of 0, 0, 0.

@tomcrane
Copy link
Contributor Author

tomcrane commented Jan 30, 2024

Target scenarios

  • The 99% use case; one model, one Scene, I want to paint this model onto this Scene, I don't want to think about positioning the model in the Scene, it doesn't really make sense to think about that when it's the only object in the world. Similar to the 99% use case for 2D images filling the Canvas.
  • I am making a comment about this entire Scene.
  • I am explicitly positioning this model at the origin (I might be putting some other models into the Scene later, elsewhere).
  • I am making a comment about (0,0,0) which happens to be the origin, but I'm not making a comment about the whole Scene.

Simple 99% case

            "target": [
                "https://example.org/iiif/scene1/page/p1/1"
            ]

Only applicable to painting annotations?

Specific positioning at (0,0,0)

    "target": [
        {
            "type": "SpecificResource",
            "source": [
                {
                    "id": "https://example.org/iiif/scene1/page/p1/1",
                    "type": "Scene"
                }
            ],
            "selector": [
                {
                    "type": "PointSelector",
                    "x": 0,
                    "y": 0,
                    "z": 0
                }
            ]
        }
    ]

Possible OriginSelector

    "target": [
        {
            "type": "SpecificResource",
            "source": [
                {
                    "id": "https://example.org/iiif/scene1/page/p1/1",
                    "type": "Scene"
                }
            ],
            "selector": [
                {
                    "type": "OriginSelector"
                }
            ]
        }
    ]

What are the scenarios in which you would use the OriginSelector?

@azaroth42
Copy link
Member

azaroth42 commented Jan 30, 2024

Propose a new issue for OriginSelector?
Propose that OriginSelector is just the default values case of PointSelector: #2253 (comment)

@azaroth42
Copy link
Member

To try and distill the cause of the issue: The difference between the scenes and canvases is that scenes are boundless whereas canvases are bounded, and thus scaling is conceivable for canvases but impossible for scenes. When we target the entire canvas we mean "the bounding box that starts at 0,0 and extends to width,height, and covers the entire duration of the canvas". Then when we paint something onto the canvas, we mean scale into that space.

However, when we target the Scene, we do not want to scale into the space, we want to translate content "pixels" into scene "pixels". It's more like the temporal scaling of AV material into a canvas (c.f. timeMode) where the default is to render at 'normal' speed, and that can be changed if needed.

Perhaps it's that the exception is 2d content painting, rather than the other way round?

@azaroth42
Copy link
Member

Use case: Ambient Lights and Directional Lights are painted into the scene, but not at any particular point. Thus it seems like the annotation targets the Scene as a whole, not the origin (which would make them not Ambient/Directional, but a Point or Spot Light)

@azaroth42
Copy link
Member

Ready for Eds I think

@azaroth42 azaroth42 added the Ready-for-Eds Editorial changes ready for Editorial review label Jan 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3d presentation Ready-for-Eds Editorial changes ready for Editorial review
Projects
None yet
Development

No branches or pull requests

3 participants