problem with cameras

Help
Abe
2009-03-31
2013-05-01
  • Abe

    Abe - 2009-03-31

    Hi everybody,
    I have a collada file that includes a camera (camera3), whose details in the collada file are below. However, when I load the file, I get:

    CrtScene, always create a default camera and it is the first camera to use
    CrtScene, no instance_camera found creating a node with an instance

    and the view is not corresponding to the camera location. Should I have to change something in the code? Or where and how I tell to use camera3 as camera?

    When I debug, the scene attribute of _CrtRenderer, has two cameras, the first named "cameraShape3" and two CameraInstances. The first is referring to cameraShape3, but when I check its transform is the unit matrix and not the data loaded from file.

    again, am I doing something wrong?
    best regards to all,
    abe

    <library_cameras>
    <camera id="cameraShape3" name="cameraShape3">
    <optics>
    <technique_common>
    <perspective>
    <yfov>67.4467</yfov>
    <aspect_ratio>1.2484</aspect_ratio>
    <znear>0.001</znear>
    <zfar>100000</zfar>
    </perspective>
    </technique_common>
    </optics>
    <extra>
    <technique profile="MAYA">
    <vertical_aperture>2.4</vertical_aperture>
    <horizontal_aperture>2.99615</horizontal_aperture>
    <lens_squeeze>1</lens_squeeze>
    <film_fit>0</film_fit>
    <film_fit_offset>0</film_fit_offset>
    <film_offsetX>0</film_offsetX>
    <film_offsetY>0</film_offsetY>
    </technique>
    </extra>
    </camera>
    </library_cameras>

    <node id="camera3" name="camera3" type="NODE">
    <translate sid="translate">-149.85 -2.20374 297.329</translate>
    <rotate sid="rotateZ">0 0 1 0</rotate>
    <rotate sid="rotateY">0 1 0 -12.4</rotate>
    <rotate sid="rotateX">1 0 0 12.5923</rotate>
    <instance_camera url="#cameraShape3"/>
    </node>

     
    • Christoph Nenning

      Hi,

      by digging in the SVN log I found a small code snippet which might be what you need. See file rt/src/Crt/1.4/CrtScene.cpp revision 219 (comment: "don't add default camera when there is a camera is the scene").

      I don't know why this code has been removed later.

       

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks