Quantcast
Channel: Adobe Community : All Content - AIR Development
Viewing all articles
Browse latest Browse all 2954

RectangleTexture and repeat in fragment shader

$
0
0

This sample is worked http://pastebin.com/B0eN8EGj

....

var texture:* = context3D.createTexture(bitmapData.width, bitmapData.height, Context3DTextureFormat.BGRA, false);
texture.uploadFromBitmapData(bitmapData);
context3D.setTextureAt(0, texture);

...

fragmentShader.assemble(Context3DProgramType.FRAGMENT,
   "tex ft1, v0, fs0 <2d, repeat, linear>\n"+

   "mov oc, ft1"
);

.....



If creat RectangleTexture:

var texture:* = context3D.createRectangleTexture(bitmapData.width, bitmapData.height, Context3DTextureFormat.BGRA, false);
texture.uploadFromBitmapData(bitmapData);
context3D.setTextureAt(0, texture);

app does not display anything.


How do I create a repeating RectangleTexture ?


Viewing all articles
Browse latest Browse all 2954

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>