Skip to content
This repository has been archived by the owner on Oct 19, 2020. It is now read-only.

Decide on how to deal global material IDs (material API) #94

Open
tomas-polach opened this issue Oct 26, 2017 · 1 comment
Open

Decide on how to deal global material IDs (material API) #94

tomas-polach opened this issue Oct 26, 2017 · 1 comment

Comments

@tomas-polach
Copy link
Contributor

global material IDs are common in dynamic elements (aka parametric objects) in the scene structure in the editor (spaces.archilogic.com)

this is not a pressing issue since:

  • we do not yet support dynamic elements in our aframe components
  • when exporting data3d, global material IDs are being converted to full material attributes (means they are not present in data3d files)

the idea of global material IDs was to store them in database at some point and serve them via material API. (similar approach as with furniture)

@frederic-schwarz
Copy link
Member

frederic-schwarz commented Oct 26, 2017

take a look at dynamic-entities branch
https://github.com/archilogic-com/3dio-js/tree/dynamic-entities/src/aframe/component/dynamic-entities
it has already support for library materials
material definition follows implementation for io3d-furniture

<a-entity io3d-wall="h:2.4, l:3, material_front:bricks" position="2 0 -1" rotation="0 12 0"></a-entity>

support for custom materials could look like this:

  <a-assets>
     <a-asset-item id="my-mat" io3d-material="colorDiffuse: #fff; colorSpecular: #09f; mapDiffuse: texture1.jps"></a-asset-item>
  </a-assets>
<a-entity io3d-wall="h:2.4, l:3, material_front: #my-mat" position="2 0 -1" rotation="0 12 0"></a-entity>

@frederic-schwarz frederic-schwarz added this to the parametric object support milestone Oct 26, 2017
@frederic-schwarz frederic-schwarz removed this from the architectural toolkit milestone Dec 10, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants