AI djupkarta och 3D-foto

Förvandla ett platt foto till en 3D-effekt: En AI-modell uppskattar djupet på varje pixel, sedan verkar kameran röra sig runt scenen.

Körs i din webbläsare. Dina filer lämnar aldrig din enhet. Se hur du kontrollerar det

…

Så gör du

  1. 1
    Lägg till ett foto

    Välj en bild med tydlig fram- och bakgrund.

  2. 2
    Ladda in modellen

    Vi kan ladda ner 27 MB en gång.

  3. 3
    Kolla djupet.

    Välj grå eller färggräns.

  4. 4
    Ställ in 3D-rörelsen

    Välj väg, rörelse och zooma.

  5. 5
    Försök med porträttblur

    Välj fokusdjup och blurstyrka.

  6. 6
    Export

    Ladda ner 3D GIF, djup PNG eller suddiga foto.

Om det här verktyget

A single photo has no depth information, yet our brain easily sees which parts are near and which are far. Monocular depth estimation models learn to do the same from millions of pictures. Depth Anything V2 Small is one of the best compact models of this kind, released under the Apache-2.0 licence. This tool runs it in your browser and uses the depth map for three things: a 3D parallax animation, a depth map image for other software, and a portrait-style background blur.

The depth map

The model looks at your photo at about 518 pixels on the long side and outputs a relative depth value for each point: bright for near, dark for far. It is relative, not in metres, which is all you need for effects. You can view it in grey or in false colour, invert it (some 3D software expects white for far) and download it as a PNG at the size of your photo.

3D photo (parallax)

To fake a camera move, the tool shifts each pixel sideways by an amount that depends on its depth: near pixels move more than far ones, exactly as they would if you moved your head. The camera path can go left and right, up and down, or in a circle. A slight zoom hides the gaps that open at the edges of near objects. The GIF export renders a loop of frames at the width you choose, ready for social posts and messages.

Portrait blur

Choose the focus depth (100 percent is the nearest object) and the blur strength, and the tool blurs everything in front of or behind that depth, like a wide-aperture lens. Unlike a simple subject cut-out, it blurs gradually with distance.

The model and performance

The int8 version of the model is about 27 MB, downloaded once and cached. It runs on your processor with ONNX Runtime WebAssembly, which takes a few seconds per photo on a typical laptop and longer on phones. The photo is not uploaded.

Good subjects

Portraits, pets, products on a table, streets with clear foreground and background, landscapes with a close object. Scenes with strong depth layers look best in 3D.

Tips

Use 15 to 25 movement units for natural motion; large values stretch the edges. A circle path gives the classic "3D Facebook photo" look. For the GIF, 24 frames at about 540 px wide balance smoothness and size.

Limits

Depth is estimated, not measured. Glass, mirrors, sky and thin objects can be wrong. Large movements reveal stretched pixels behind near objects because the hidden background is not invented. Video export is not offered; use the GIF or animate the depth map in other software.

Lösta exempel

Ett 4000 x 3000 foton av en katt på en soffa: modellen tar cirka 3 sekunder, katten är ljus i djupkartan och väggen mörk; en cirkelväg med rörelse 20 och zoom 106 procent gör en 24 rums, 540 px GIF på ca 2 MB.

I korthet

Vanliga frågor

Vad är en djupkarta?

En grå bild där ljusstyrka betyder avstånd: ljus för nära, mörkt för långt. 3D-verktyg använder det för att skilja lager.

Är djupet i meter?

Modellen ger relativ djup, som räcker för effekter men inte för mätning.

Hur stor är modellen?

Omkring 27 MB, laddad ner en gång från den här webbplatsen och cachade av din webbläsare.

Varför sträcker sig kanterna i 3D-animationen?

När du flyttar det närmaste objektet visar du en bakgrund som aldrig synts på bilden.

Kan jag använda djupkartan i Blender eller Photoshop?

Ladda ner PNG och använd den som en förskjutnings- eller djupkarta; vända om din programvara förväntar sig vitt långt bort.

Har mitt foto skickats någonstans?

Modellen körs lokalt i din webbläsare.

Helt gratisIngen avgift, ingen registrering
Filer förblir privataAllt körs i din webbläsare
Enkelt på ditt språkFinns på många språk