2012-11-03 2 views

답변

2

인라인을 변형으로 래핑 한 다음 변형의 배율을 변경하여 인라인의 크기를 변경할 수 있습니다. 예를 들어

는 : http://jsfiddle.net/wildpeaks/ZZfb2/2/


<X3D width="400px" height="300px" showStat="true"> 
    <Scene> 
     <Transform id="redBox"> 
      <Inline url="http://x3dom.org/x3dom/example/scene/redBox.x3d" /> 
     </Transform> 
    </Scene> 
</X3D> 

<button onclick="change_size()">Click to change the size</button> 

function change_size() { 
    document.getElementById('redBox').setAttribute('scale', '3 0.5 1'); 
}​ 
+0

이것은 객체의 크기가 아니라 그 크기를 설정한다. 이 작업을 수행 할 때 : 같은 결과가 나타납니다. 하지만 노력해 줘서 고마워. – user1796705