Jump to content

View id is lost after a CIGI reset


photo

Recommended Posts

Posted

Hi, the view id is lost after a cigi reset, meaning a view can no longer be controlled correctly after a reset.

Reproduction:

  1. add a view definition in ig_config.xml, such as <channel view_id="4" use_syncker_projection="0" syncker_name="myview"/>
  2. start the IG with the option -sync_view myview
  3. Verify with HEmu that you actually see the view #4 by changing the view pitch with CIGI ViewControl message
  4. Trigger a CIGI reset (the database will reload)
  5. with HEMU, you can no longer control the view, as it has been cleared to the default view ID #0.

Is there a workaround? (code with 2.16.1, probably the same for 2.17)

Posted

you can change default_view_id in ig_config.xml

<item name="default_view_id" type="int">0</item>

 

Posted

This requires to change ig_config.xml, which I'd like to avoid. Isn't there an API way to set the current view ID for the IG? or a command-line to set the default view ID ? (which I thought the -sync_view was for... The current behavior looks like a bug to me, or at the very least an oversight in the Reset procedure)

Posted
35 minutes ago, Amerio.Stephane said:

Isn't there an API way to set the current view ID for the IG?

yes sure, you can use ig->setCurrentView

Posted
19 hours ago, Amerio.Stephane said:
  • add a view definition in ig_config.xml, such as <channel view_id="4" use_syncker_projection="0" syncker_name="myview"/>
  • start the IG with the option -sync_view myview
  • Verify with HEmu that you actually see the view #4 by changing the view pitch with CIGI ViewControl message

3rd point sounds strange i can not reproduce this behavior. i stll can change only view #0. 

Posted
7 hours ago, cash-metall said:

3rd point sounds strange i can not reproduce this behavior. i stll can change only view #0

Is Syncker loaded (-sync_master 1)? Are you testing on 2.16.1 (I didn't checked 2.17)? It should definitively work, as this is how we use the IG since Unigine IG mode exists...

Posted
20 hours ago, Amerio.Stephane said:

Is Syncker loaded (-sync_master 1)? Are you testing on 2.16.1 (I didn't checked 2.17)? It should definitively work, as this is how we use the IG since Unigine IG mode exists...

We are currently attempting to reproduce the issue on both 2.16.x and 2.17.x, but we have not been successful thus far. But if we were able to reproduce, I think the fix would be quite simple :)

Thanks!

How to submit a good bug report
---
FTP server for test scenes and user uploads:

Posted

I made a comparative test 2.16/2.17, and they both behave the same. In 2.17 my startup line is

Quote

start ""  "%app%" -video_app dx12 -video_refresh 0 -video_debug 0 -main_window_size 1024 640 -main_window_resizable 1 -main_window_fullscreen 0 -render_vsync 0 -video_offscreen 0 -sound_app auto -data_path ../data/ -extern_plugin UnigineIG,UnigineCIGIConnector -console_command "config_autosave 1" -sync_master 1 -sync_view other

    <syncker_channels>
        <channel view_id="0" use_syncker_projection="0" syncker_name="main"/>
        <channel view_id="1" use_syncker_projection="0" syncker_name="other"/>
    </syncker_channels>

The step to reproduce are exactly as described: At startup, the HEMU can control the IG through view 1. After a CIGI reset, the view has been reset to view ID 0. The proposed fix to setCurrentView(id) in code works, but it really feels like an oversight: the -sync_view should persist after a CIGI reset.

Note: -sync_master 1 is mandatory, otherwise Syncker is not loaded and sync_view is ignored.

Small note: in 2.17, you changed the default sync_count to 1. Good for me, but absent in the doc/migration. Since 2.17 you no longer have to had it if there is a solo master (good!)

 

  • Thanks 1
×
×
  • Create New...