Using .atf files in textures

Software: Away3D 4.x

therauli, Newbie
Posted: 08 August 2012 10:52 AM   Total Posts: 6

Hello!

We have a big scene with lots of big textures. If we load the whole scene we run out of texture memory. We are currently investigating ways of reducing the memory consumption. One way would be to use .atf textures. Can we use them with Away3D? I tried googling the issue but came up with nothing.

Cheers,

Rauli

   

Richard Olsson, Administrator
Posted: 08 August 2012 11:40 AM   Total Posts: 1192   [ # 1 ]

ATF textures are not supported natively by Away3D at this point, but we plan to add support for them for 4.1. You can still very easily create your own texture type however, that basically mimics the behavior and structure of BitmapTexture, but that uploads an ATF texture instead of a BitmapData. After that point, the texture are treated the same by all parts of the engine, so that’s the only addition you’ll need to make (and that we will be making for 4.1 later this year.)

   

Ben, Newbie
Posted: 26 February 2013 02:54 PM   Total Posts: 5   [ # 2 ]

Hi there!
Thank you for the good job you do with Away3D!!
I have a problem with ATFTexture. I have this exception when I instanciate it :

ReferenceError: Error #1056: Cannot create property away3d.textures:TextureProxyBase::_format on global.
at away3d.textures::ATFTexture()[/Users/robbateman/Documents/Adobe Flash Builder 4.7/away3d-core-fp11/src/away3d/textures/ATFTexture.as:21]

I do it this way :

[Embed(source="../../../../../resources/app/earth/worldmap_2048.atf"mimeType="application/octet-stream")]
 
public var Map:Class;
var 
map = new Map();
bitmapMaterial = new ATFTexture(map); 

I compile it in swfVersion 17 and air 3.4

Did someone already had this problem?
Thank you!

Ben from Paris

   

Ben, Newbie
Posted: 26 February 2013 08:50 PM   Total Posts: 5   [ # 3 ]

Hi there,
Sorry it was a mistake… I had both away3D 4.0 and away3D 4.1 in different modules dependencies…
It works very well, thank you wink

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X