Announcement

Collapse
No announcement yet.

Option to convert to scanlnie exrs with the vrimg convertor

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Option to convert to scanlnie exrs with the vrimg convertor

    Hi Folks,

    I've recently popped into nuke world and the issues of tiled vs scanline exrs is rearing it's head over here. I'm not a python coder yet and ideally it'd be great to not have to filter files through nuke to convert our renders for speed reasons so would it be possible to add in a scanline option in the vrimg conversion tool? I understand why for memory and speed reasons it can't be written out of vray directly but would it be possible to code in some extra flexibility to some of the support tools to achieve this? Being able to use zips compression makes a big difference over the straight exr render but the difference when turned into scanline is huge again. If it's not a biggy it'd be fantastic to have for smaller places that don't have any coders!

    Cheers,

    John

  • #2
    +1 on that.

    I think I made the same request some time ago.

    V Miller

    Comment


    • #3
      vrimg2exr always produces scanline-based OpenEXR files; you can specify the compression method with -compression option (you would probably need to use -compression zips)

      If you are looking for a way to write scanline-based multichannel OpenEXR files directly out of V-Ray, this is already implemented in our internal builds.

      Best regards,
      Vlado
      Last edited by vlado; 18-04-2011, 07:57 AM.
      I only act like I know everything, Rogers.

      Comment


      • #4
        Cheers for that vlado - I'm not sure why but for some reason nuke exr files seems quicker again - maybe it's that it's writing in auto crop info based on the alpha channel of the files. Great to know that vrimg2exr makes scanline files - they're far far quicker than writing directly to exr so it's brilliant to hear that you've got direct writing to scanline implemented. I want to get some good exr info tools to see can I figure out exactly what nuke does to a multichannel vray exr when it reads it and writes it out - it's really annoying not knowing!

        As an aside I wrote a little tool so that if we write to vrimg, you can pick a single vrimg in a folder and then it'll select all the vrimg files and write a bat file to start converting them. Not exactly ground breaking but it automates some things!

        Code:
        macroScript VRimgBat_0_04 category:"Johns bits (snigger)" tooltip:"VRimgBat_0_04: Make a bat file to convert vrimg to exr files"
        (
        	local theFileList = #()
        	local TheVrimgPath
        	local TheVrimg2exrpath
        	Local OutFile
        	
        	rollout ConvertVRimgBatFile "VRimgBat_0_04: Make a bat file to convert vrimg to exr files"
        	(
        		button ImageFileFolder "Rendered file folder" width:300 Align:#right
        		
        		on ImageFileFolder pressed do
        		(
        			TheVrimgPath = getOpenFileName types:"Vrimg(*.vrimg)" caption:"Pick the folder with your renders"
        			ImageFileFolder.text = getFilenamePath TheVrimgPath
        			theFileList = (getFiles ((getFilenamePath TheVrimgPath) + "*.vrimg"))
        			print ("the files are " + theFileList as string)
        			print ("There are " + (theFileList.count as string) + " vrimg files in the folder")
        			
        			if theFileList.count != 0 then
        			(
        				MyOutFile = "c:\\convert_vrimg_files.bat"
        				TheBatFile = CreateFile MyOutFile
        				for i in 1 to theFileList.count do
        				(
        					format ("\"" + "C:\\Program Files\\Chaos Group\\V-Ray\\3dsmax 2010 for x64\\tools\\vrimg2exr.exe" + "\"" + " " + "\"" + theFileList[i] as string + "\"" + " -compression zips" + "\n") to:TheBatfile
        					format ("\n") to:TheBatFile
        				)
        				
        				Close TheBatFile
        				ShellLaunch (MyOutFile as string) ""
        				
        				messagebox "Your bat file has been created at c:\convert_vrimg_files.bat - Happy now Vadim?"	
        			) else (
        					messagebox "There are no vrimg files in that folder"	
        			)
        		)
        	)
        	
        	CreateDialog ConvertVRimgBatFile width:450
        	
        )

        Comment


        • #5
          Ok, if you need the data window based on the alpha channel, add the -dataWindow option to vrimg2exr...

          Best regards,
          Vlado
          I only act like I know everything, Rogers.

          Comment


          • #6
            Ah that's interesting alright - I'll stick that in and do a benchmark between it and not. All these bits help a lot, otherwise we've to tie up a nuke license to convert the files.

            Much appreciated for the pointers!

            Comment


            • #7
              Yep that worked a treat vlado - the actual scanline render of the file is nearly real time now. Much appreciated for the pointer and here's the changed tool:

              Bear in mind for anyone using it if you've got a vrimg file that's over 100 megs you'll want to increase the -bufsize amount to a meg value that's bigger than any of your frames or else the data window won't work.

              macroScript VRimgBat_0_05 category:"Johns bits (snigger)" tooltip:"VRimgBat_0_05: Make a bat file to convert vrimg to exr files"
              (
              local theFileList = #()
              local TheVrimgPath
              local TheVrimg2exrpath
              Local OutFile

              rollout ConvertVRimgBatFile "VRimgBat_0_04: Make a bat file to convert vrimg to exr files"
              (
              button ImageFileFolder "Rendered file folder" width:300 Align:#right

              on ImageFileFolder pressed do
              (
              TheVrimgPath = getOpenFileName types:"Vrimg(*.vrimg)" caption:"Pick the folder with your renders"
              ImageFileFolder.text = getFilenamePath TheVrimgPath
              theFileList = (getFiles ((getFilenamePath TheVrimgPath) + "*.vrimg"))
              print ("the files are " + theFileList as string)
              print ("There are " + (theFileList.count as string) + " vrimg files in the folder")

              if theFileList.count != 0 then
              (
              MyOutFile = "c:\\convert_vrimg_files.bat"
              TheBatFile = CreateFile MyOutFile
              for i in 1 to theFileList.count do
              (
              format ("\"" + "C:\\Program Files\\Chaos Group\\V-Ray\\3dsmax 2010 for x64\\tools\\vrimg2exr.exe" + "\"" + " " + "\"" + theFileList[i] as string + "\"" + " -compression zips -datawindow -bufsize 100" + "\n") to:TheBatfile
              format ("\n") to:TheBatFile
              )

              Close TheBatFile
              ShellLaunch (MyOutFile as string) ""

              messagebox "Your bat file has been created at c:\convert_vrimg_files.bat - Happy now Vadim?"
              ) else (
              messagebox "There are no vrimg files in that folder"
              )
              )
              )

              CreateDialog ConvertVRimgBatFile width:450

              )

              Comment

              Working...
              X