colorbleed / maya-capture-gui Goto Github PK
View Code? Open in Web Editor NEWGUI front-end for maya-capture
License: MIT License
GUI front-end for maya-capture
License: MIT License
hi, trying to open the gui result this issue :
When the visible modelPanels currently all are legacy viewport renderers and extra objects are created (e.g. duplicating some) and then using the preview in the interface that forces it to render a Viewport 2.0 playblast the newly created objects are not present in the preview.
It seems viewport 2.0 doesn't know about these new objects until the Viewport 2.0 has been activated.
This sounds related to abstractfactory/maya-capture#60
To reproduce:
The newly created objects will not be present, until you've switched to Viewport 2.0.
Saving to a file with an empty directory field specified does not raise an error yet it also doesn't explicitly define where the output is going to end up. This should become more predictable, like default to the images
folder. It is currently unclear whether it already does so. We should enforce that behavior, or error out.
Whenever a relative path is not os.path.isabs(path)
is given in the directory field it should be relative to something static and artist-friendly, I'd recommend the workspace's image folder.
On maya 2017 I have the following error.
Replacing sys.maxint with maxint = 2 ** (struct.Struct('i').size * 8 - 1) - 1
works.
Maya sometimes crashes fatally when (re)running the gui.
To reproduce:
import capture_gui
app = capture_gui.main()
app.close()
Run this code, run it again, and again, and again. Most likely within the first 20 runs Maya would have already crashed. I'm unable to quickly identify the exact source of the problem, woohoo, time for some debugging?
Now and then a playblast might end up with a selection. Let's add an option that forces no selection prior to the playblast.
Or add something that always ensures the override on selectionHiliteDisplay
display to False.
prevent the user from using a non-chronological time window.
Example non-chronological :
The start frame should never be higher than the end frame and vise versa
Currently the resulting playblast will always be opened automatically. This is the usual preference for most situations and applications though I'm willing to discuss alternative situations where one might not want this to happen automatically.
Add a checkbox to allow the artist to toggle automatic playback after capturing.
When closing the UI whilst having custom settings (not a specific preset loaded but manually changed) then upon reopening these settings aren't necessarily preserved.
The settings are not preserved.
It seems that sometimes it reverts back to a preset instead of custom *
.
The user should be able to playblast a combination of small frames and frame ranges:
Example : 1-20, 25; 50; 75, 100-150
from-to, increment;
This translates to:
Currently the pan/zoom settings will always be playblasted when enabled on the camera. An animator requested allowing to ignore any pan/zoom with a setting in the capture-gui.
Add a plug-in that allows you to switch on/off this behavior.
Maya Version: 2016.5
Platform: Windows
I encounter 'unknown workspace' error while running from Maya 2016.5 on line 197:
images_rule = mc.workspace("images", q=1, fre=True)
I put a 'try' around that statement to get around the RuntimeError
wrong post
The Use default behavior under the Save options (in IOPlugin) doesn't describe how it behaves. The question from artists is: "What is default?"
I'd like to propose two solutions.
With the implementation of render tokens in #28 we can remove the default and maybe instead allow users to define their own "dynamic default" through render tokens. This way it's much less hardcoded and is clear to the user what it does.
This would clarify on mouse-hover what it does. Most artists are trained to request additional information from UI items by hovering over them, though in many scenarios it's not instantly clear what the UI item does. By implementing a tooltip we can add some clarification. It's debatable on how good of a solution this is UX-design wise.
Let's discuss what solution would be the best fit. I'm currently thinking about proposal 1.
Currently there's no option that can toggle whether DOF should be included in the playblast (if enabled on the camera)
Currently making a playblast will always show a browser (even though it has a default filename) which, for Artists, sometimes felt as a continuous interruption when doing many playblasts.
Allow a "save to default location" kind of setting where it doesn't show the browser but automatically continues to save to a default location.
Currently the feature of registering preset paths (that will list the presets it has) is undocumented. Let's add an example usage to the README just like how the callbacks are documented there.
How configurable should a playblast be in production?
@mottosso @tokejepsen @aardschok I'd be happy if you all could share some insights regarding this topic. Feel free to get others into the discussion as well.
This also adds to the question do we want to allow the user to generally take any form of playblasts through a capture GUI, so it's their go-to tool when doing any playblast. Or do we want something simple that just ensures all "this needs to go to the client or in the edit" playblasts are quick to do and consistent in any production.
Currently there's no setting that just captures (or snaps) the current frame.
Implement a Current Frame option in the time widget.
The capture UI time settings automatically try to adjust so that the end frame is higher than the start frame, and vice versa.
As such when retyping the end frame, e.g. going 1... -> 12... -> 125
then The start frame will automatically be resetted to frame 1
since for a moment there the lowest set end frame was frame 1
.
Instead of this behavior it should only update that check on leaving the text field, on enter and/or after a delay (possibly 2 seconds or so?). So that one can at least type without interfering with the other setting.
Currently it's impossible to specify a dynamic path (relative under the current workspace) like the images or movies file rule defined in the workspace.
Implement render tokens like <Images>
and <Movies>
respectively to capture to the workspace's image or movies folder.
When trying to open the Preview Widget after the first time open and closing it, the hitbox moves to the right. The rest of the widgets can be expanded when clicking the title, the preview widget does not.
Currently the render tokens are supported in the filename (and I believe they also work in the directory field) but they do not show up under right-mouse-button for the directory field.
Implement RMB functionality for the directory field
Currently the ScaleWidget only returns the render settings and the actually specified settings are ignored.
Implement it. :)
When using custom frames the user should be able to use a sequential frame number in the file names (0001, 0002, 0003 etc) or the actual frame numbers (0001, 0030, 0060).
This functionality can be toggled in capture
with the raw_frame_numbers
argument.
Because preview refresh is currently outside of an undo queue (to avoid spamming tons of undos into the queue) it seems to behave unexpectedly on undo where it would revert to frame zero.
We'll need to find a good way to avoid having the undo queue filling up whilst leaving the scene the way it was.
Currently playblast only uses default lighting, artist should be able to playblast with custom lighting
Currently the option to display textures or not cannot be set in the Capture UI. These options should somehow become editable to ensure the playblasting is consistent.
Like #34 more viewport options are currently lacking support. There are no ways to customize them through the capture gui.
Note: whilst #31 remains unfixed this also means there's no way to playblast with custom settings. Once that's implemented one could disable "override viewport settings" and just directly use the settings from a viewport to workaround missing UI widgets for options
Implement the options for these features, like:
As a note, there are many viewport settings! ;)
When playblasting to the image
codec the resulting playblast is not opened for previewing because the name is returned as e.g. playblast.####.png
with the ####
being the problematic argument for viewers.
Resolve the ####
with the frame number (an existing file) and pass it as correct argument to image viewers.
When the GUI remains open for some time and a camera has been deleted or scene has changed and the camera list was not refreshed then it might try to playblast with an invalid camera, resulting in an error:
# Traceback (most recent call last):
# File "P:\pipeline\dev\git\maya-capture-gui\capture_gui\app.py", line 239, in apply
# options['filename'] = lib._capture(options)
# File "P:\pipeline\dev\git\maya-capture-gui\capture_gui\lib.py", line 177, in _capture
# path = capture.capture(**options)
# File "P:\pipeline\dev\git\maya-capture\capture.py", line 116, in capture
# raise RuntimeError("Camera does not exist: {0}".format(camera))
# RuntimeError: Camera does not exist: |persp1
Though this error is not shown visually to the artist, yet is only present in the script editor.
Highlight that something went wrong that describes to the artist what specifically is a wrong setting.
Maybe the Widgets could implement a Validation check that would return False if it was invalid and would have a highlighting feature to identify the settings in the widget that are invalid.
Hi,
When I try to open the gui on centos 7.6 / maya 2019.1, the console return this errors
RuntimeWarning: libshiboken: Overflow: Value -9223372036854775807 exceeds limits of type [signed] "i" (4bytes)., at line 102, in "/mnt/Pipeline/Maya/scripts/capture_gui/plugins/timeplugin.py" OverflowError RuntimeWarning: libshiboken: Overflow: Value 9223372036854775807 exceeds limits of type [signed] "i" (4bytes)., at line 102, in "/mnt/Pipeline/Maya/scripts/capture_gui/plugins/timeplugin.py"
on windows it's works normally
With the version from #15 saving with an empty filename (when save is True and use default is False) in the IoPlugin
will result in the following error:
# Traceback (most recent call last):
# File "D:\git_pipeline\maya-capture-gui\capture_gui\app.py", line 372, in apply
# options["filename"] = lib.capture_scene(options)
# File "D:\git_pipeline\maya-capture-gui\capture_gui\lib.py", line 197, in capture_scene
# path = capture.capture(**options)
# File "P:\pipeline\dev\git\maya-capture\capture.py", line 176, in capture
# **playblast_kwargs)
# RuntimeError: The file exists and overwrite flag not set. Playblast aborted.
#
It should be clearer to the end user what is going on. We could raise a clearer error message.
Similar to Maya's render tokens for file name prefix in the render settings I'd like to have similar functionality to set a dynamic filename output that can be set up by the artist.
For example supplying a filename like <Scene>
would result in the exact scene name without extension. And <Scene>_<Camera>
would result in something like my_scene_persp.mov
(Here my_scene
comes from the scene name my_scene.ma
and the camera is the persp
camera that was playblasted)
Initial tokens I'm thinking of:
<Scene>
: The current scene name without extension.<Camera>
: The camera used in the playblast<Resolution>
: The resulting resolution in the playblast, e.g. "1920x1080"Potentially a system could be implemented to register custom tokens that would just call the registered function with the supplied options for the capture, but I think that's something that would only be interesting if there's a need for it.
Whenever Override viewport settings is turned off in the ViewportOptions it currently overrides the view settings to an arbitrary "default" state with basically everything turned on. Based on comments from users the expected behavior in this case is that it would grab the settings from the active viewport, as such parsing those.
With this option disabled the options should be parsed from the active view, for this capture.parse_active_view
could be used (taking only the settings that we need).
Console request:
from capture import capture
import capture_gui
capture_gui.main()
capture_gui.main()
Currently the capture gui has no way to customize the viewport background mode or colors; or allowing to take them from the active viewport (as described in #31)
It should allow to set the background mode (gradient or solid) and respectively the colors (top/bottom or single solid color).
When the preview widget was previously opened (thus initialized) for the current open capture gui, then closed and then reopened the thumbnail is not automatically updated; this means the preview doesn't correspond with the current settings which might be unclear to artist.
Projects or pipelines often require predefined settings that can be applied and reused throughout a project. Allowing to save and share these options in the form of presets would be a great effort in that direction.
The presets would apply things like "visibilities" of specific objects, or background color. To keep the general UI as minimalistic as possible (saving on screen space) I'd opt for a solution that implements the specific settings (configuring a preset) in a separate pop-up when clicking on the options (cogwheel) icon.
A quick mockup to showcase how this would look in the UI:
The preset could then also house the aspects configurations of Codec and Options and other settings that are often left alone during production. The idea is to keep only the most frequently used options in the base UI. The above could then, as example, become something like:
Example : When clicking "browse" and creating a folder called "test" and insert "TEST" as filename returns the wrong directory while the filename is correct.
The preview widget aids the artist to give an idea of the playblast outcome, nevertheless for very large and complex scenes it's unnecessarily slow because it will try to update on each option change that results in different output. Instead it would be easier for those scenes to allow the artist to update the preview only manually.
Allow disabling the auto-updating feature of the thumbnail (and maybe even hide it to gain screen space?).
When playblasting with <Camera>
in the filename the camera name will resolve with the namespace in it, for example namespace:camera
which isn't a valid filename. As such the playblast will error.
Either strip the namespace or replace it with a symbol that's valid as filename, for example: name.replace(":", "_")
.
To ensure the user has the freedom to chose if the filenames contain a frame number or not we will need to remove the default behavior of the capture single frame. It should only write frame numbers when the user enables the Raw frame numbers checkbox
Current result : filename.####.extension
Proposed : filename.extension
We can enable a frame number token for the filename to ensure the user can specify the frame number the wanted fashion, for example: filename_.extension
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.