Fspy importer for Maya - Easy camera match

Поділитися
Вставка
  • Опубліковано 5 лют 2025
  • In this tutorial I am going to show you how to import a camera match directly from Fspy into Maya, using a script available online, but customizing it so it imports all the information, including the focal length and setting the correct resolution in Maya.
    Follow up tutorial:
    • HDRI projection workfl...
    Resources:
    fspy.io/
    github.com/Jus...
    Let me know if you enjoyed this video.

КОМЕНТАРІ • 49

  • @rtytyu1
    @rtytyu1 Рік тому +2

    스크립트의 일부분을 수정하는 부분을 참고하였더니 카메라 값이 더 정밀하게 읽혔습니다.
    감사합니다.

  • @tlilmiztli
    @tlilmiztli 2 роки тому +1

    Nice one! Planning to test 2023?

    • @cgside
      @cgside  2 роки тому +1

      Hey there. Should work fine in 2023, since Maya 2022.3 uses also python 3.

    • @tlilmiztli
      @tlilmiztli 2 роки тому

      @@cgside Very cool, will give it a try. I moved to Maya from Blender and I was missing Fspy functionality :)

  • @MONEYVAL9
    @MONEYVAL9 2 роки тому +2

    Also is there the updated script with your added sniippets or should we just type it in our selves. I would have not like to break the script with typos but if thats the only option will have to do.

    • @cgside
      @cgside  2 роки тому +4

      github.com/cgside/MayaFspy_update/blob/main/Maya_fspy_update

  • @20mi
    @20mi 2 роки тому

    my view camera is match but render camera not, which is same camera and same res. idk how to fix it

    • @cgside
      @cgside  2 роки тому

      Were you able to solve it? It's been a while since I used this script honestly.

  • @ishikaa_budhiraja
    @ishikaa_budhiraja Рік тому

    hey, im not able find version 2.0 and not able to download pymel s well. kindly help me. i need to work this urgently

    • @cgside
      @cgside  Рік тому

      If you're in a rush try this: ua-cam.com/video/OvsDfgMkljA/v-deo.html . Honestly it's been a while since I used Maya so haven't used this script lately. Couldn't find version 2.0 either for some reason, if you really want to use this script search on how to install pymel in Maya.

    • @cgside
      @cgside  Рік тому

      help.autodesk.com/view/MAYAUL/2024/ENU/?guid=GUID-2AA5EFCE-53B1-46A0-8E43-4CD0B2C72FB4

  • @MONEYVAL9
    @MONEYVAL9 2 роки тому

    I cant seem to get the default script download to work. Keeps spitting out this error
    # Error: ModuleNotFoundError: file C:\Program Files\Autodesk\Maya2022\Python37\lib\site-packages\shiboken2\files.dir\shibokensupport\__feature__.py line 142: No module named 'pymel' #

    • @MONEYVAL9
      @MONEYVAL9 2 роки тому

      Im using maya 2022, and i got the fSpy download from the github page.

    • @cgside
      @cgside  2 роки тому +1

      Hey, try to use version 2.0 of the script which doesnt use pymel (the module you're missing). github.com/JustinPedersen/maya_fspy/tree/v2.0.0
      Another workaround is to install pymel for maya. Cheers.

    • @MONEYVAL9
      @MONEYVAL9 2 роки тому

      @@cgside I got it to work by installing pymel throught the command line. Thanks

  • @ellobo.design
    @ellobo.design 2 роки тому +2

    Could you put the edited code available ?

    • @cgside
      @cgside  2 роки тому +4

      Sure, here you go: github.com/cgside/MayaFspy_update/blob/main/Maya_fspy_update
      Let me know if this works ;)

    • @ellobo.design
      @ellobo.design 2 роки тому +1

      You have just begun, but the content is already awesome. Thanks. Keep going.

    • @navinkumararya
      @navinkumararya 2 роки тому

      @@cgside Not working- Image not imported

  • @mdmiguel2007
    @mdmiguel2007 10 місяців тому

    hello I'm editing the core.py and adding this code, with notepad, as seen in the video but when I add it stops working. As much as I check I can't find the error. Can anyone see what I can be doing wrong? thank you hfa = pm.camera(camera_shape, q=True, hfa=True)
    mm = hfa*25.4
    fl = data['relativeFocalLength']*mm/2
    pm.camera(camera_shape, e=True, fl=fl)
    renderWidth = data['imageWidth']
    renderHeight = data['imageHeight']

    pm.setAttr('defaultResolution.width', renderWidth)
    pm.setAttr('defaultResolution.height', renderHeight)
    aspRatio = float(pm.getAttr('defaultResolution.width'))/float(pm.getAttr('defaultResolution.height'))
    pm.setAttr('defaultResolution.deviceAspectRatio', aspRatio)

    • @cgside
      @cgside  10 місяців тому

      Hey, it's been a while since I touched Maya. Here's a more up to date script : ua-cam.com/video/DOETNKpM2Ls/v-deo.htmlsi=SQ6Ff9HU4ce8jaN8

    • @mdmiguel2007
      @mdmiguel2007 10 місяців тому

      @@cgsidethank you very much

  • @agroprom9751
    @agroprom9751 2 роки тому

    Maya 2018. It doesn't work for me, the camera is in the center of the coordinate grid. And there is no image plane.

    • @cgside
      @cgside  2 роки тому +1

      I am not sure if the original script supports Maya 2018, that might be the issue. Also there was a big change to python 3 in recent versions of Maya.

    • @agroprom9751
      @agroprom9751 2 роки тому

      @@cgside It helped deleting the old "maya" folder C:\Users\xxx\Documents\maya

  • @chaandkhan6696
    @chaandkhan6696 10 місяців тому

    i just checked, fspy can also run un maya 2023

  • @alexsuttie16
    @alexsuttie16 Рік тому

    Any chance we can update fSpy so it will run on maya 2023?

    • @cgside
      @cgside  Рік тому

      You'll have to ask on the GitHub page for the script update, as I am not the author. The main problem is pymel as it doesn't ship by default in newer versions of Maya .

  • @johnwalker4787
    @johnwalker4787 2 роки тому

    F-spy not working on 3 point perspective images in Maya. Any solutions ?

    • @cgside
      @cgside  2 роки тому

      Hi. I can confirm that this is an issue. May be related to the fact that the ".json" file doesn't export information about the z axis (3rd vanishing point). Will check if it's possible to fix this.

    • @johnwalker4787
      @johnwalker4787 2 роки тому

      @@cgside If possible can you make a tutorial on perspective matching images in 3DS max perspective match tool and bringing that camera to Maya. I have heard that this could work but couldn't find a tutorial on this. It's shame that industry standard tool like Maya doesn't have a built-in tool for perspective matching.

    • @cgside
      @cgside  2 роки тому

      @@johnwalker4787 You can use the blender workflow and import it to Maya. Should work. No need for 3ds max, watch this: ua-cam.com/video/OvsDfgMkljA/v-deo.html&ab_channel=OnMars3D

  • @AnnabelleG96
    @AnnabelleG96 2 роки тому

    I'm not sure what I do wrong.. I imported the code and it's not matching the resolution gate and the focal length :( and the perspective is not at all accurate inside maya even though it worked in fspy. sigh.

    • @AnnabelleG96
      @AnnabelleG96 2 роки тому

      nevermind it works! Not deleting first comment to help the algorithm.

    • @TheSeeSquare
      @TheSeeSquare 2 роки тому +1

      @@AnnabelleG96 Hey I'm facing this same issue, Did you find any solution for this?

    • @MosquitoHater
      @MosquitoHater Рік тому

      @@TheSeeSquare Did any of you find a solution for this? ^^

  • @nothugo9207
    @nothugo9207 2 роки тому

    Hey don't know if you'll see this but I got an error when trying to do the import python code
    # Error: ModuleNotFoundError: file C:\Program Files\Autodesk\Maya2022\Python37\lib\site-packages\shiboken2\files.dir\shibokensupport\__feature__.py line 142: No module named 'maya_fspy'

    • @cgside
      @cgside  2 роки тому

      Hi, not sure why you have that error. Do you have pymel installed? That could be the reason. Also make sure you have the correct path: imgur.com/a/U7IReCk

    • @theapexpredator157
      @theapexpredator157 Рік тому

      @@cgside I'm getting this error " # Error: ModuleNotFoundError: file line 1: No module named 'maya_fspy' "
      I have everything on a different drive too and I don't want to change it to C.
      Any way I can workaround this?

    • @MSJDesign
      @MSJDesign Рік тому

      You've installed the script in the wrong place.

    • @MSJDesign
      @MSJDesign Рік тому

      Youve installed the script in the wrong place@@theapexpredator157

  • @野战
    @野战 2 роки тому

    GOOD😀

  • @eliassojeda4778
    @eliassojeda4778 2 роки тому

    Can you share us the core.py file?

    • @cgside
      @cgside  2 роки тому +1

      Just add the GitHub code provided here in comments in the core.py file, there is no other code I am adding besides that. Cheers

    • @eliassojeda4778
      @eliassojeda4778 2 роки тому

      @@cgside Thank you

  • @xManoloFehnx
    @xManoloFehnx Рік тому +3

    I think Maya 2024 broken this Script :(

    • @cgside
      @cgside  Рік тому +2

      Hey, I believe thats because it uses pymel and Maya 2024 doesn't ship with it. There is an updated version on the author's GitHub that doesn't use pymel. The bit that I wrote doesn't use it either. The other option is to install pymel manually. Haven't used Maya in a while. Cheers

    • @xManoloFehnx
      @xManoloFehnx Рік тому +1

      @@cgside Yup, works perfectly with the update version, thanks for ur help. :)