Integrating up through commit 90f050496

This commit is contained in:
alexpete
2021-04-07 14:03:29 -07:00
parent 8f2ed080a9
commit c2cbd430fe
2694 changed files with 285622 additions and 176874 deletions
@@ -0,0 +1,88 @@
@echo off
REM
REM All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
REM its licensors.
REM
REM For complete copyright and license terms please see the LICENSE at the root of this
REM distribution (the "License"). All use of this software is governed by the License,
REM or, if provided, by the license below or the license accompanying this file. Do not
REM remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
REM
:: Set up and run LY Python CMD prompt
:: Sets up the DccScriptingInterface_Env,
:: Puts you in the CMD within the dev environment
:: Set up window
TITLE Lumberyard DCC Scripting Interface Cmd
:: Use obvious color to prevent confusion (Grey with Yellow Text)
COLOR 8E
%~d0
cd %~dp0
:: Keep changes local
SETLOCAL enableDelayedExpansion
:: This maps up to the \Dev folder
IF "%DEV_REL_PATH%"=="" (set DEV_REL_PATH=..\..\..\..\..\..\..)
:: Change to root Lumberyard dev dir
:: Don't use the LY_DEV so we can test that ENVAR!!!
CD /d %DEV_REL_PATH%
set Rel_Dev=%CD%
echo Rel_Dev = %Rel_Dev%
:: Restore original directory
popd
set DCCSI_PYTHON_INSTALL=%Rel_Dev%\Tools\Python\3.7.5\windows
:: add to the PATH
SET PATH=%DCCSI_PYTHON_INSTALL%;%PATH%
:: dcc scripting interface gem path
set DCCSIG_PATH=%Rel_Dev%\Gems\AtomLyIntegration\TechnicalArt\DccScriptingInterface
echo DCCSIG_PATH = %DCCSIG_PATH%
:: add to the PATH
SET PATH=%DCCSIG_PATH%;%PATH%
:: Constant Vars (Global)
:: global debug (propogates)
IF "%DCCSI_GDEBUG%"=="" (set DCCSI_GDEBUG=false)
echo DCCSI_GDEBUG = %DCCSI_GDEBUG%
:: initiates debugger connection
IF "%DCCSI_DEV_MODE%"=="" (set DCCSI_DEV_MODE=false)
echo DCCSI_DEV_MODE = %DCCSI_DEV_MODE%
:: sets debugger, options: WING, PYCHARM
IF "%DCCSI_GDEBUGGER%"=="" (set DCCSI_GDEBUGGER=WING)
echo DCCSI_GDEBUGGER = %DCCSI_GDEBUGGER%
echo.
echo _____________________________________________________________________
echo.
echo ~ LY DCCsi, DCC Material Converter
echo _____________________________________________________________________
echo.
:: Change to root dir
CD /D %DCCSIG_PATH%
:: add to the PATH
SET PATH=%DCCSIG_PATH%;%PATH%
set PYTHONPATH=%DCCSIG_PATH%;%PYTHONPATH%
CALL %DCCSI_PYTHON_INSTALL%\python.exe "%DCCSIG_PATH%\SDK\PythonTools\DCC_Material_Converter\standalone.py"
ENDLOCAL
:: Return to starting directory
POPD
:END_OF_FILE
exit /b 0
@@ -41,15 +41,7 @@ Reading FBX file information (might come in handy later)
-- I couldn't get pyfbx_i42 to work, but purportedly it can extract information from binary files. You may just have
to use the specified python versions
"""
from PySide2 import QtWidgets, QtCore, QtGui
from PySide2.QtCore import Slot
from PySide2.QtWidgets import QApplication
import shiboken2
from shiboken2 import wrapInstance
from model import MaterialsModel
from drag_and_drop import DragAndDrop
import dcc_material_mapping as dcc_map
# built-ins
import collections
import logging
import subprocess
@@ -58,7 +50,19 @@ import sys
import os
import re
# should give access to Lumberyard Qt dlls and PySide2
from PySide2 import QtWidgets, QtCore, QtGui
from PySide2.QtCore import Slot
from PySide2.QtWidgets import QApplication
import shiboken2
from shiboken2 import wrapInstance
# local imports
from model import MaterialsModel
from drag_and_drop import DragAndDrop
import dcc_material_mapping as dcc_map
# global space
main_window_pointer = None
main_app_window = None
@@ -12,10 +12,10 @@
import MaxPlus
import sys
def get_material_information():
for mesh_object in MaxPlus.Core.GetRootNode().Children:
print('Object---> {}'.format(mesh_object))
get_material_information()
@@ -0,0 +1,40 @@
# coding:utf-8
#!/usr/bin/python
#
# All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
# its licensors.
#
# For complete copyright and license terms please see the LICENSE at the root of this
# distribution (the "License"). All use of this software is governed by the License,
# or, if provided, by the license below or the license accompanying this file. Do not
# remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
"""Boostraps and Starts Standalone DCC Material Converter utility"""
# built in's
import os
import site
# -------------------------------------------------------------------------
# \dev\Gems\AtomLyIntegration\TechnicalArt\DccScriptingInterface\SDK\PythonTools\DCC_Material_Converter\standalone.py
_MODULE_PATH = os.path.abspath(__file__)
_DCCSIG_REL_PATH = "../../../.."
_DCCSIG_PATH = os.path.join(_MODULE_PATH, _DCCSIG_REL_PATH)
_DCCSIG_PATH = os.path.normpath(_DCCSIG_PATH)
_DCCSIG_PATH = os.getenv('DCCSIG_PATH',
os.path.abspath(_DCCSIG_PATH))
# we don't have access yet to the DCCsi Lib\site-packages
site.addsitedir(_DCCSIG_PATH) # PYTHONPATH
# azpy bootstrapping and extensions
import azpy.config_utils
_config = azpy.config_utils.get_dccsi_config()
settings = _config.get_config_settings(setup_ly_pyside=True)
from main import launch_material_converter
launch_material_converter()