Hi,

I am new to using PyQTGraph but I encountered a very weird issue. 
Every time I add a ScatterPlotItem, while there is n existing LinePlotItem, 
the LinePlotItem disappears. 
Here is the sample code that I run. 

I am sure I am missing something very simple, but any help would greatly be 
appreciated. 

Thanks in advance for the help.




import matplotlib.pyplot as plt
from mpl_toolkits.mplot3d import Axes3D
import numpy as np
from pyqtgraph.Qt import QtCore, QtGui
import pyqtgraph as pg
import pyqtgraph.opengl as gl
import pyqtgraph.examples as ex
import numpy as np
import sys

app = QtGui.QApplication([])
w = gl.GLViewWidget()
w.setWindowTitle('pyqtgraph example: GLSurfacePlot')

## Add a grid to the view
g = gl.GLGridItem()
w.addItem(g)

## Add Axis
a = gl.GLAxisItem()
w.addItem(a)

# add a line
el2 = gl.GLLinePlotItem(pos=np.array([[0, 0, 1], [1, 1, 1]]), color=[1, 0.0, 
1., 1.], width=10)
w.addItem(el2)

# add scatter plots
el1 = gl.GLScatterPlotItem(pos=np.array([[0, 0, 1], [1, 1, 1]]), color=[1, 0.0, 
1., 1.], size=10)
w.addItem(el1)

w.show()

-- 
You received this message because you are subscribed to the Google Groups 
"pyqtgraph" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/pyqtgraph/d6c54eb5-8188-4267-8449-d17c6dd9e7ac%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to