4 Replies Latest reply on Mar 31, 2008 7:35 AM by 14thStreetStudio

    3D for 2D zoom

    14thStreetStudio
      I have a bunch of Lingo zoom code for zooming in and out large (8M pixel) bitmaps. The my zooms are deliberately slow and tricks are necessary to avoid ugly aliasing effects. The code uses ImageObjects and copyPixels all of which seem close to OpenGL primitives that don't handle anti-aliasing at all.

      It has been pointed out to me that if I treated the 2D image as a plane in 3D space I could zoom by simply moving the camera. Does the 3D renderer have good anti-aliasing properties for this kind of thing? Has anyone tried this?
        • 1. Re: 3D for 2D zoom
          Level 7
          The 3D hardware should smooth the image fine, I think the main problem will
          be the maximum texture size / ratio, especially on older 3D cards, as they
          have to be to the power of 2 pixel wise. Eg. 2 x 4 8 x 256 512 x 64
          etc. This will not be enough for a hi-res photo, and also the ratio won't
          match very cleanly so you'll have to crop or rescale your photos. You could
          tile textures across a mesh, but it would get more complicated.

          What about an imported flash surface as a director sprite? They seem to
          smooth things automatically, although I don't use Flash much myself.

          Cheers

          Richard Smith
          www.funpods.com


          • 2. Re: 3D for 2D zoom
            14thStreetStudio Level 1
            The curious thing is that 3D hardware (OpenGL) doesn't directly support anti-aliasing when scaling an image. The drivers/hardware all have fairly crude resampling schemes. An Nvidia book has a whole chapter on making convolution filters in their shading language to improve on the crude, by photographic standards, what the raw hardware does...
            • 3. Re: 3D for 2D zoom
              Level 7
              So what's your question?

              You can't code your own filters in sw3d, it only supports Dx7.

              The rest of my advice is still valid.

              Cheers

              Richard

              "14thStreetStudio" <webforumsuser@macromedia.com> wrote in message
              news:fspqn4$pe2$1@forums.macromedia.com...
              > The curious thing is that 3D hardware (OpenGL) doesn't directly support
              > anti-aliasing when scaling an image. The drivers/hardware all have fairly
              > crude
              > resampling schemes. An Nvidia book has a whole chapter on making
              > convolution
              > filters in their shading language to improve on the crude, by photographic
              > standards, what the raw hardware does...
              >


              • 4. Re: 3D for 2D zoom
                14thStreetStudio Level 1
                My question was closer to:

                "Has anybody actually used 3D facilities in Director to improve image zooming beyond what can be done using Lingo?"