Skip to main content
z_abdulgalimov
Inspiring
December 29, 2015
Question

RectangleTexture and repeat in fragment shader

  • December 29, 2015
  • 0 replies
  • 231 views

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 ?

This topic has been closed for replies.