You are viewing this from the perspective of a WebGL implementer. You need to pass type=FLOAT to ES because that is the external format of the data you are providing to ES.
In ES if you specified
texImage2D(GL_TEXTURE2D, 0, GL_RGBA, 256, 256, 0, GL_RGBA, GL_FLOAT, data)
where data points to unsigned byte data (which is in effect what WebGL's OES_texture_float is telling the app to do)No it's not. format and data tell it type of data you are supplying. WebGL will supply that data. If you tell it format = GL_RGBA, type = GL_FLOAT WebGL will supply GL_RGBA, GL_FLOAT (16 bytes per color).
From the perspective of a WebGL application programmer, the
external format is whatever the format of the HTML elements is
(most like RGB888 or RGBA8888) and the internal format he/she
wants is FLOAT but, according to the real meaning of the type
parameter, OES_texture_float is telling him/her to misclassify
his/her external data as FLOAT. Hence the example I gave above.
The texImage2D commands that take elements should not even have a
type parameter. It is unnecessary as the element has a known (to
the WebGL implementation) external format. internalformat should
be used to tell WebGL what internal format the application would
like used to store the resulting texture. That is its purpose in
GL and ES. See OES_required_internal_format
or the OpenGL ES 3.0 specification.
NOTE: This electronic mail message may contain confidential and privileged information from HI Corporation. If you are not the intended recipient, any disclosure, photocopying, distribution or use of the contents of the received information is prohibited. If you have received this e-mail in error, please notify the sender immediately and permanently delete this message and all related copies.