Search Feedback

1030
votes

Async Texture2D.LoadImage and other texture operations

Assets

-

-

Hello.

I'd like to see asynchronous variant for loading external JPG and PNG textures that doesn't block the main thread and cause hiccups (especially since I'm developing for Oculus Rift), so I can just initiate the load continue rendering.

Generally I'd like to see other texture operations (like compressing, applying new pixels, changing the pixels) to be asynchronous or even allow running from another thread, so I can do heavy job like that without hogging the main thread.

Comments (20)

  1. 1ef09908cafdbc8ba06057af5b15ef30?d=mm

    npatch

    Aug 12, 2016 15:12

    Technically, you can do this. You can write your own native plugin that uses it's own DX11/GL context and create textures in gpu side that you yourself manipulates and then tells Unity to update it's own copy of the Texture object to refer to the mem space you are manipulating. There is an example in the Documentation about how to do this.

    As for the request itself, I would like to see those too. Taking custom screenshots in AR is equally frustrating in terms of perf hiccups since most texture operations are blocking.

  2. 4874042a877b73a56df5bfcf8f85e332?d=mm

    Hilm

    Nov 26, 2015 15:03

    Yep, I'd love for this to get added (ideally also to the unity 4.x cycle if possible)!

  3. 3012d69e5c7c5f2ee59d5b9158934705?d=mm

    captaincrunch80

    Nov 26, 2015 02:48

    This can't be so hard to fix, but it is totally annoying. Please!

  4. A051cafc8a1221ac0fb4c1f7ff609604?d=mm

    SLock81

    Oct 23, 2015 14:56

    Any news on this? This feels like basic functionality that should be as fast as possible, but it seems SO slow.

  5. E4a9033a1d7cea8451f09a954f8f2345?d=mm

    LennardF19892

    Aug 04, 2015 20:06

    A major component of my game is the loading of user-made mods in the form of images. However, slightly bigger images cause the main thread to noticeably hang and there is no way loading this asynchronously right now.

  6. C609b668504ab35712fbb71d96d73a99?d=mm

    Ziboo

    Apr 27, 2015 15:17

    Any news on that issue ?
    It's very frustrating when you're doing an app like, for instance loading facebook users photos without blocking the main thread

  7. D4a0d13ad1606bcbd222a01471aee065?d=mm

    cowlinator

    Mar 04, 2015 22:57

    It looks like this feedback idea http://feedback.unity3d.com/suggestions/async-image-decoding-and-resizin is similar to, or a duplicate of, this one.

  8. D4a0d13ad1606bcbd222a01471aee065?d=mm

    cowlinator

    Feb 27, 2015 03:21

    Downloading an image and setting it as a texture is not all that unique a task, but Unity exposes nothing that could help reduce severe FPS drop on mobile and/or VR when trying to create a new texture.

  9. 24da9579d0fe90fbeca27dc65665d343?d=mm

    Tmtakala

    Dec 21, 2014 00:22

    I second the need for async Texture2D.LoadImage

  10. 586a47b1ad8118b77f1ae377ffa7fbd9?d=mm

    tolstenko

    Dec 11, 2014 17:34

    Async setpixels would be awesome too

Your opinion counts

Help us make things better. Share your great idea for improving Unity or vote for other people’s.

Log in to post a new idea

Categories

All

(10883)

2D

(287)

Ads

(57)

AI & Navigation

(81)

Analytics

(130)

Animation

(406)

Asset Store

(363)

Asset Store Publisher

(19)

Assets

(551)

Audio

(185)

Cloud Build

(146)

Collaborate

(67)

Docs & Tutorials

(246)

Editor

(2545)

Everyplay

(17)

Game Performance Reporting

(21)

General

(987)

Graphics

(894)

GUI

(442)

Input

(173)

Licensing

(93)

Networking

(189)

Physics

(387)

Platforms

(445)

Profiling & Optimization

(84)

Runtime

(185)

Scripting

(1141)

Terrain

(174)

WebGL

(142)