mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-02 18:03:56 -04:00
flat colors
This commit is contained in:
parent
d8b71f9395
commit
86f7689b43
@ -192,11 +192,17 @@ generate_flat_geom(const LVecBase4f &frame) {
|
||||
("PGFrame", format, qpGeomUsageHint::UH_static);
|
||||
|
||||
qpGeomVertexWriter vertex(vdata, InternalName::get_vertex());
|
||||
qpGeomVertexWriter color(vdata, InternalName::get_color());
|
||||
vertex.add_data3f(left, 0.0f, top);
|
||||
vertex.add_data3f(left, 0.0f, bottom);
|
||||
vertex.add_data3f(right, 0.0f, top);
|
||||
vertex.add_data3f(right, 0.0f, bottom);
|
||||
|
||||
color.add_data4f(_color);
|
||||
color.add_data4f(_color);
|
||||
color.add_data4f(_color);
|
||||
color.add_data4f(_color);
|
||||
|
||||
if (has_texture()) {
|
||||
// Generate UV's.
|
||||
left = uv_range[0];
|
||||
|
Loading…
x
Reference in New Issue
Block a user