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

Work with a room object exported from RoomScanLiDAR application #31

Closed
arthedza opened this issue Jun 29, 2021 · 2 comments
Closed

Work with a room object exported from RoomScanLiDAR application #31

arthedza opened this issue Jun 29, 2021 · 2 comments
Labels
bug Something isn't working more info requested Further information is requested to help diagnose the issue

Comments

@arthedza
Copy link

arthedza commented Jun 29, 2021

Hello! I try to add a 3D Object of a room in actual size (.obj) exported from the RoomScanLiDAR application to my scene but it isn't appearing in the AR scene. I set both of the onLoadStart and onLoadEnd callbacks and they work as expected, which means that the object was successfully loaded. I have added an ambient light to the scene, and another 3d object was rendered as expected. What I am doing wrong?

ViroMaterials.createMaterials({
  test: {
    lightingModel: 'Blinn',
    diffuseColor: 'yellow',
    shininess: 0.5,
  },
});

<ViroARScene
        onTrackingUpdated={this._onInitialized}
      >
        <ViroAmbientLight color="#ffffff" />
        <ViroNode scale={[0.7, 0.7, 0.7]} position={[0, 0, -1]}>
          <ViroText
            text={this.state.text}
            scale={[0.7, 0.7, 0.7]}
            position={[0, 0, 0]}
            style={styles.helloWorldTextStyle}
          />
          <Viro3DObject
            source={require('./src/assets/3d/property-obj.obj')}
            materials={['test']}
            scale={[0.5, 0.5, 0.5]}
            type="OBJ"
            onLoadStart={() => {
              console.log('LoadStart');
            }}
            onLoadEnd={() => {
              console.log('LoadEnd');
            }}
          />
        </ViroNode>
      </ViroARScene>

UPDATE
I've tried to put a small Viro box and small custom object also in the scene and everything was rendered. I think that probably Viro doesn't work with point cloud objects. Is there maybe some way to convert the point cloud to a normal 3d object?

@robertjcolley
Copy link
Collaborator

I'm not sure if I can reproduce this - can you help by seeing if you get the same behavior I'm seeing?

I do see an error in the console but it looks like everything is working to me.

IMG_E1643209DBCC-1

Error: Asset not found: /Users/XXX/starter-kit/assets/vp.mtl for platform: null
    at getAbsoluteAssetRecord (/Users/XXXXX/starter-kit/node_modules/metro/src/Assets.js:110:11)
    at async getAsset (/Users/XXX/starter-kit/node_modules/metro/src/Assets.js:238:18)
    at async Server._processSingleAssetRequest (/Users/XXX/starter-kit/node_modules/metro/src/Server.js:326:20)
    at async Server._processRequest (/Users/XXX/starter-kit/node_modules/metro/src/Server.js:401:7)

@robertjcolley robertjcolley added bug Something isn't working more info requested Further information is requested to help diagnose the issue labels Dec 18, 2021
@robertjcolley
Copy link
Collaborator

closing for no response.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working more info requested Further information is requested to help diagnose the issue
Projects
No open projects
Status: No status
Development

No branches or pull requests

2 participants