UI widget questions--hopefully now in correct forum

I'll try to collect and collate what I've already got into this forum thread.

For starters:

What this thread is all about:

Here's a PDF from a presentation from Jeremy Ernst given at the 2011 Game
Developer's Conference, called "Fast and Efficient Facial RIgging." He
describes the system he created for Gears of War 3, including using FACS for
the face.



I want it.

Except I want it as a semi-transparent widget overlaying the 3D window.

Like this:

Post edited by athenenoctua on


  • athenenoctuaathenenoctua Posts: 0
    edited December 2012

    I made that widget ui in Qt Designer, an app included with DAZ Studio 4.5.

    But now I have to hook up the sliders of this _non-standard_ interface to manipulate the morph values (not the deltas).

    I have considered the SDK, but the simplest, most straightforward way seems to be to use Daz Script.
    In doing so, the widget will be customizable. Just go into Qt Designer, move the sliders to where you want them, then hook up the code to the parameters you want to move.

    What I know so far:

    The code should probably be put into a .dsa file.

    I don't want to iterate through morph names. I want a one-to-one correspondence, coded out in longhand. In that way, idiots such as myself can simply go in and change the morphname in the .dsa when they put a different morphname in the .ui. See Jeremy Ernst's presentation for the reason why.

    In the first line I want to tell the script to use the user interface FACS.ui, which will be located in the folder FACS, the same folder as the script file, FACS.dsa. The way to do that may or may not be:

    //Declare and hook up the ui

    var sUiPath = String(“FACS/FACS.ui”);
    var oUiFile = new DzFileInfo( sUiPath );

    // Call the FACS widget into existence.

    Then make sure it exists.

    if( oUiFile.exists() )

    Then make it appear in the pane, or nested inside the nested widgets.

    // Call the sliders QSliders into existence.
    // Connect morphvalue names such as CTRLMouthOpen to the corresponding QSlider with that name
    // Use Signals/Slots concept to make the sliders do exactly what the Parameters controls would do

    } else {
    MessageBox.information( sUiPath, “The Cake is a Lie”, “&OK;” );


    Hopefully this script will change and develop as I learn more.

    Problems and issues:

    I can’t find the syntax to call the .ui file. Rob’s coding examples show how to call nested .ui’s. I successfully tested this theory by replacing “Select the property group from the list on the left” with “THE CAKE IS A LIE” in the “What do I do?” widget.

    Also, the example code formats the widget to match the other panes/widgets in the user interface. That formatting would make this widget useless.

    Post edited by athenenoctua on
  • athenenoctuaathenenoctua Posts: 0
    edited December 2012

    Tugpsx was kind enough to contribute a slider script.

    // DAZ Studio version 3.1 filetype DAZ Script

    var wDlg = new DzDialog;
    var box = new DzVGroupBox(wDlg);
    var w = new DzEnumSlider( box )
    w.addItem( "oh" )
    w.addItem( "my" )
    w.addItem( "Bob" )
    w.value = 2;

    // setup button to update debug results
    but = new DzPushButton( box );
    but.text = "debug";
    connect( but, "clicked()", butclicked )// click button to show update in debug

    function butclicked()
    debug( "val = " + w.value );

    I put this into a .dsa file, put the .dsa file into the Sripts folder in the content directory ran it from Content Manager, and this popped up:
    Very cool.

    337 x 257 - 17K
    353 x 268 - 19K
    376 x 286 - 15K
    Post edited by athenenoctua on
  • athenenoctuaathenenoctua Posts: 0
    edited December 1969

    I have gone to Window/Tabs/Script IDE and pasted in the script as follows, and got the following results.

    Note: As a former technical writer, a parent, and a current student of all that is DAZ, I know it's important to start excruciatingly simple and to be visual. So here goes:

    516 x 300 - 23K
  • athenenoctuaathenenoctua Posts: 0
    edited December 1969

    Some screenshots playing around with the standard widget examples in the documentation:

    671 x 433 - 39K
    658 x 393 - 33K
    635 x 328 - 31K
    638 x 336 - 24K
  • athenenoctuaathenenoctua Posts: 0
    edited December 2012

    This link might be helpful.

    And this one.

    So does the DAZ Script IDE window equal the QSA Workbench, then?


    Post edited by athenenoctua on
Sign In or Register to comment.