4 Replies Latest reply on Sep 20, 2009 4:51 AM by Remko_van_Dokkum

    store list with image data to external file

    Remko_van_Dokkum

      using director 11.5

      windows xp pro

       

      how can i store a list containging image data to an external file

       

      using vlist or buddy file xtra i get an error

        • 1. Re: store list with image data to external file
          Sean_Wilson Adobe Community Professional

          vList should work. Show us some code that doesn't work, and describe why it fails (including any error codes from the xtra or script errors thrown in the IDE)

          • 2. Re: store list with image data to external file
            Remko_van_Dokkum Level 1

            a small test script in the attached movie file

             

            global vlist_xtra


            on startmovie
              list_data=member(2,1).image.duplicate()
              b=[list_data]
              file_pad=the moviepath&"image_data_list.lst"
              vlist_xtra=new xtra ("vList", file_pad)
              put "vlist_xtra "&vlist_xtra
              put "b.ilk "&b.ilk
              put "b "&b
              put "b[1].rect "&b[1].rect
              OK=vlist_xtra.write(b)
              put "vlist_xtra.write "&OK
              vlist_xtra=0
            end

             

             

             

            if i run the attached test movie my message windows shows

             

            -- "vlist_xtra <Xtra child "vList" 2 23d858>"
            -- "b.ilk list"
            -- "b [<image:1f9484>]"
            -- "b[1].rect rect(0, 0, 143, 129)"
            -- "vlist_xtra.write -2147211470"

            • 3. Re: store list with image data to external file
              Sean_Wilson Adobe Community Professional

              -- "vlist_xtra.write -2147211470"

              Which means:

              put vList_errorString(-2147211470)
              -- " kLstErr_LockVoidImage (-2147211470)"
              

              When I re-write your code a little:

              global vlist_xtra
              
              on startmovie
                tImage = duplicate( member(2, 1).image )
                tList = [tImage]
                tFile = _movie.path & "image_data_list.lst"
                vlist_xtra = new xtra ("vList", tFile)
                --  put "vlist_xtra ", vlist_xtra
                put "tList.ilk", ilk(tList)
                put "tList[1].ilk", ilk(tList[1])
                --  put "tList", tList
                --  put "tList[1].rect", tList[1].rect
                OK = vlist_xtra.write(tList)
                put "vlist_xtra.write", vList_errorString(OK)
                vlist_xtra = 0
                _movie.newMember(#bitmap).image = tImage
              end
              

              I see the following in my message window (and a new, valid, bitmap created in my cast):

               -- "tList.ilk" #list
               -- "tList[1].ilk" #image
               -- "vlist_xtra.write" " kLstErr_LockVoidImage (-2147211470)"

              You have found a bug in the xtra. Which version are you using?

              put vList_version()
               -- "2.0"
              

               

              You should contact Mauricio at Tabuleiro and report this to him so it can be fixed. Please let me know if you don't, because I will in that case - it needs to be fixed, and the fact no-one has reported it yet shows how few users have migrated to D11.5.

              FWIW: your code works properly in D10 with vList 1.8.5, 1.8.6 and 2.0.0 so this would appear to be a bug introduced with D11 or 11.5 (and probably related to unicode)

              • 4. Re: store list with image data to external file
                Remko_van_Dokkum Level 1
                Original Report:can i store a list containing image data using director 11.5 and vlist v2.01 windows xp pro
                Answer #1:Hi, Remko. There is an issue storing image data with the Director 11.5 update and vList: this will produce invalid data without a corresponding error message. We are in contact with Adobe, and apparently they changed the internal format of the image datatype with no warning, and in a way that is difficult for vList to work around it and still remain compatible with older data. We are still researching alternatives and waiting for a final decision on this. In the meantime you can store the picture of the member or the media of a member, and these will work correctly. I am going to post an update about this as soon as the situation is more clear.

                Regards,

                Mauricio Piacentini
                Tabuleiro