better queue render
This commit is contained in:
@@ -4,7 +4,9 @@ const App = {
|
||||
|
||||
init: () => {
|
||||
ConsoleLog.init();
|
||||
RenderSettings.init();
|
||||
CameraList.init(App._on_camera_select);
|
||||
CollectionList.init();
|
||||
CameraConfig.init();
|
||||
RenderQueue.init();
|
||||
PreviewPanel.init();
|
||||
@@ -70,6 +72,12 @@ const App = {
|
||||
obj_radio_both.addEventListener("change", () => { App._update_output_example(); });
|
||||
obj_input_frame_prefix.addEventListener("input", () => { App._update_output_example(); });
|
||||
obj_input_frame_padding.addEventListener("input", () => { App._update_output_example(); });
|
||||
|
||||
let obj_btn_reset_cols = document.getElementById("btn_reset_collections");
|
||||
obj_btn_reset_cols.addEventListener("click", () => {
|
||||
CollectionList.reset_to_original();
|
||||
ConsoleLog.add("Collections restaurees aux valeurs originales.");
|
||||
});
|
||||
},
|
||||
|
||||
_bind_render_events: () => {
|
||||
@@ -129,6 +137,18 @@ const App = {
|
||||
|
||||
CameraList.set_cameras(obj_result.list_cameras, obj_result.obj_scene);
|
||||
CameraConfig.clear();
|
||||
|
||||
if (obj_result.obj_render_settings) {
|
||||
RenderSettings.set_from_blend(obj_result.obj_render_settings);
|
||||
}
|
||||
|
||||
if (obj_result.list_collections) {
|
||||
CollectionList.set_collections(obj_result.list_collections);
|
||||
ConsoleLog.add(obj_result.list_collections.length + " collection(s) trouvee(s).");
|
||||
} else {
|
||||
CollectionList.clear();
|
||||
}
|
||||
|
||||
ConsoleLog.add(obj_result.list_cameras.length + " camera(s) trouvee(s).");
|
||||
App._update_start_button();
|
||||
})
|
||||
@@ -188,6 +208,8 @@ const App = {
|
||||
nb_frame_padding: nb_frame_padding,
|
||||
str_output_path: App.str_output_path,
|
||||
list_cameras: list_cameras,
|
||||
list_collections: CollectionList.get_overrides(),
|
||||
obj_render_settings: RenderSettings.get_settings(),
|
||||
};
|
||||
|
||||
RenderQueue.build_display(str_mode, list_cameras);
|
||||
@@ -249,6 +271,7 @@ const App = {
|
||||
nb_frame_padding: nb_frame_padding,
|
||||
str_output_path: App.str_output_path,
|
||||
list_cameras: list_cameras,
|
||||
list_collections: CollectionList.get_overrides(),
|
||||
};
|
||||
|
||||
RenderQueue.build_display(str_mode, list_cameras);
|
||||
@@ -284,6 +307,8 @@ const App = {
|
||||
nb_frame_padding: nb_frame_padding,
|
||||
str_output_path: App.str_output_path,
|
||||
list_cameras: CameraList.list_cameras,
|
||||
list_collections: CollectionList.list_collections,
|
||||
obj_render_settings: RenderSettings.get_settings(),
|
||||
};
|
||||
|
||||
window.api.save_config(obj_config)
|
||||
@@ -338,6 +363,8 @@ const App = {
|
||||
|
||||
App._update_output_example();
|
||||
|
||||
RenderSettings.set_from_config(obj_config);
|
||||
|
||||
if (obj_config.list_cameras && obj_config.list_cameras.length > 0) {
|
||||
CameraList.list_cameras = obj_config.list_cameras;
|
||||
CameraList.str_selected_camera = null;
|
||||
@@ -347,6 +374,15 @@ const App = {
|
||||
obj_badge.textContent = String(obj_config.list_cameras.length);
|
||||
}
|
||||
|
||||
if (obj_config.list_collections && obj_config.list_collections.length > 0) {
|
||||
CollectionList.list_collections = obj_config.list_collections;
|
||||
CollectionList.render();
|
||||
let obj_badge_col = document.getElementById("badge_collection_count");
|
||||
obj_badge_col.textContent = String(obj_config.list_collections.length);
|
||||
} else {
|
||||
CollectionList.clear();
|
||||
}
|
||||
|
||||
CameraConfig.clear();
|
||||
App._update_start_button();
|
||||
ConsoleLog.add("Configuration importee.");
|
||||
|
||||
Reference in New Issue
Block a user