Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
149e6267
Kaydet (Commit)
149e6267
authored
Haz 30, 2015
tarafından
Tomaž Vajngerl
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
opengl: draw rectangle lines with only one glDrawArrays call
Change-Id: I33e065fe6c084d0bed04ee99c447004fe573278a
üst
33d32a78
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
7 deletions
+18
-7
gdiimpl.cxx
vcl/opengl/gdiimpl.cxx
+18
-7
No files found.
vcl/opengl/gdiimpl.cxx
Dosyayı görüntüle @
149e6267
...
@@ -1195,13 +1195,24 @@ void OpenGLSalGraphicsImpl::drawRect( long nX, long nY, long nWidth, long nHeigh
...
@@ -1195,13 +1195,24 @@ void OpenGLSalGraphicsImpl::drawRect( long nX, long nY, long nWidth, long nHeigh
if
(
UseSolid
(
mnLineColor
)
)
if
(
UseSolid
(
mnLineColor
)
)
{
{
const
long
nX1
(
nX
);
GLfloat
fX1
=
OPENGL_COORD_X
(
nX
);
const
long
nY1
(
nY
);
GLfloat
fY1
=
OPENGL_COORD_Y
(
nY
);
const
long
nX2
(
nX
+
nWidth
);
GLfloat
fX2
=
OPENGL_COORD_X
(
nX
+
nWidth
);
const
long
nY2
(
nY
+
nHeight
);
GLfloat
fY2
=
OPENGL_COORD_Y
(
nY
+
nHeight
);
const
SalPoint
aPoints
[]
=
{
{
nX1
,
nY1
},
{
nX2
,
nY1
},
{
nX2
,
nY2
},
{
nX1
,
nY2
}
};
GLfloat
pPoints
[
16
];
DrawLines
(
4
,
aPoints
,
true
);
// No need for AA.
pPoints
[
0
]
=
fX1
;
pPoints
[
1
]
=
fY1
;
pPoints
[
2
]
=
fX2
;
pPoints
[
3
]
=
fY1
;
pPoints
[
4
]
=
fX2
;
pPoints
[
5
]
=
fY2
;
pPoints
[
6
]
=
fX1
;
pPoints
[
7
]
=
fY2
;
mpProgram
->
SetVertices
(
pPoints
);
glDrawArrays
(
GL_LINE_LOOP
,
0
,
4
);
}
}
PostDraw
();
PostDraw
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment