36 #ifndef __RE_OGLRender__
37 #define __RE_OGLRender__
104 #define RE_DRIVER_INFO_VENDOR "OpenGL Vendor"
105 #define RE_DRIVER_INFO_RENDERER "OpenGL Renderer"
106 #define RE_DRIVER_INFO_VERSION "OpenGL Version"
107 #define RE_DRIVER_INFO_SHADING_LANGUAGE "OpenGL Shading Language"
108 #define RE_DRIVER_INFO_DETECTED "Detected GPU"
117 const char *className()
const;
135 {
return reinterpret_cast<RE_Render*
>(
this); }
137 {
return reinterpret_cast<const RE_Render*
>(
this); }
147 static bool hasGL11();
148 static bool hasGL12();
149 static bool hasGL13();
150 static bool hasGL14();
151 static bool hasGL15();
152 static bool hasGL20();
153 static bool hasGL21();
155 static bool hasGL3(
int minor);
156 static bool hasGL4(
int minor);
158 static int glMajorVersion();
159 static int glMinorVersion();
162 int glslMajorVersion();
163 int glslMinorVersion();
185 static void setPerformBadDriverCheck(
bool onoff);
188 static bool hasDriverVersion();
189 static int getDriverMajorVersion();
190 static int getDriverMinorVersion();
191 static int getDriverBuildMajorVersion();
192 static int getDriverBuildMinorVersion();
195 static bool getUsingCoreProfile();
196 static void setUsingCoreProfile(
bool using_core_profile);
203 static void clearGraphicsCache();
208 int64 getFreeTextureMemoryKB(
int64 *largest_chunk =
nullptr);
209 int64 getFreeBufferMemoryKB(
int64 *largest_chunk =
nullptr);
210 int64 getFreeFramebufferMemoryKB(
int64 *largest_chunk =
nullptr);
213 static int64 getInitialFreeMemoryKB();
217 static void exitWithBadDriver();
224 static void updateScreenSize();
229 static bool areScreensUniform();
247 static float pixelsToInches(
int n);
248 static int inchesToPixels(
float i);
249 static int scaledSize(
int size);
255 void checkForSuspendResume();
256 static void addSuspendResumeCB(
void (*cb)(
void*),
void *
data);
257 static void removeSuspendResumeCB(
void (*cb)(
void*),
void *
data);
264 void enableMultisample(
bool enable);
265 bool isMultisampleEnabled()
const;
267 void enableAlphaToCoverage(
bool enable);
268 bool isAlphaToCoverage()
const;
270 void getMaxViewportSize(
int &
w,
int &
h)
const;
271 int getMaxColorSamples()
const;
272 int getMaxDepthSamples()
const;
278 void setWindow(
RE_Window *,
bool attach =
true);
280 bool makeCurrent(
bool ignore_errors =
false);
281 static void resetCurrent();
285 bool isCurrentRender()
const;
286 bool isDrawableContextValid()
const;
293 {
return theCurrentRender.get() ==
this; }
303 void popOffscreenBufferFromDrawable();
312 void popOffscreenBuffer();
321 const RE_Window *getCurrentWindow()
const;
343 void lockContextForRender();
344 void unlockContextAfterRender();
345 bool tryLockContextForRender();
346 bool isContextLocked()
const;
355 void unlockContext();
365 int getNextGLError();
366 void clearGLErrors();
367 const char *getGLErrorString(
int error );
368 void printGLError(
const char *header,
369 bool assert =
false );
370 void printAllGLErrors(
const char *header,
371 bool assert =
false );
373 void dumpNewState(
bool show_all =
false,
374 bool show_shader_blocks =
true);
375 void dumpViewportState(
bool show_all =
false);
376 void dumpTextureState()
const;
377 void dumpVertexAttributes()
const;
378 void dumpFragmentTests(
bool show_all =
false)
const;
379 void dumpRasterizeState(
bool show_all =
false)
const;
380 void dumpTextureCacheState(
int stack_level =-1)
const;
385 bool isDebugLabelSupported()
const;
388 bool isDebugging()
const;
390 int pushDebug(
bool enable);
391 void popDebug(
int *nest =
nullptr);
393 int pushDebugGroup(
const char *
name,
int id=1987);
394 void popDebugGroup(
int *nest =
nullptr);
396 void addComment(
const char *
name,
405 int pushDrawFramebuffer();
409 void popDrawFramebuffer(
int *nest =
nullptr);
411 int pushReadFramebuffer();
415 void popReadFramebuffer(
int *nest =
nullptr);
417 void updateFramebuffer();
423 void unregisterFBO(
int id);
427 void useSampleMask(
bool use);
428 bool usingSampleMask()
const;
429 int getMaxIntegerSamples()
const;
430 int getSampleMask(
int mask_number);
431 void setSampleMask(
int mask_number,
int mask);
432 static int getMatteMaskForSampleCount(
int samples);
438 void clearC(
float *
color =
nullptr);
439 void clearZ(
float z = 1.0);
440 void clearCZ(
float z = 1.0);
449 void enableColorBufferWriting();
450 void disableColorBufferWriting();
451 bool getColorBufferWriting();
452 void updateColorBufferWriting();
461 void popDrawBuffer(
int *nest = 0);
464 bool getDrawBufferIsBlendable();
467 void popReadBuffer(
int *nest = 0);
474 bool isFrontBufferDirty()
const;
475 void setFrontBufferDirty(
bool d);
477 void flush(
int wait=0);
495 void screenMask2DI(
const UT_DimRect &rect, CacheOnlyTag);
500 void disableScreenMask();
501 void intersectMask2DI(
505 void intersectMask2DI(
507 void intersectMask2DI(
519 bool getScreenMask();
520 void dirtyViewportAndScreenMask();
523 int getOGLMaxClipPlanes();
524 void enableClipDistance(
int clip_plane,
bool enable);
525 bool clipDistanceEnabled(
int clip_plane)
const;
532 int pushBackfaceCulling();
533 int pushBackfaceCulling(
bool backface);
534 void popBackfaceCulling(
int *nested = 0);
536 bool isBackface()
const;
537 void setBackface(
bool removeBackface);
538 bool getReverseWinding();
539 void setReverseWinding(
bool reverse_winding);
544 bool isPointOffset();
546 bool isPolygonOffset();
547 void pointOffset(
bool onoff );
548 void lineOffset(
bool onoff );
549 void polygonOffset(
bool onoff );
550 void setOffsetAmount(
float variable,
float constant );
551 void getOffsetAmount(
float *variable,
float *constant)
const;
565 int stream_bitfield = 0x1);
568 void endTransformFeedback();
572 int getNumFeedbackPrimitives(
int stream = 0);
576 bool hasFeedbackBufferOverflow(
int stream = 0);
579 bool isTransformFeedbackEnabled()
const;
581 bool isRasterizeEnabled()
const;
586 float getLineWidth()
const;
587 float getMaxSmoothLineWidth();
595 void setProgramPointSize(
bool enable);
596 bool getProgramPointSize()
const;
604 int pushDepthState();
605 void popDepthState(
int *nest =
nullptr);
609 void enableDepthBufferWriting();
610 void disableDepthBufferWriting();
611 bool getDepthBufferWriting();
612 void updateDepthBufferWriting();
615 void enableDepthTest();
616 void disableDepthTest();
618 void updateDepthTest();
623 void updateZFunction()
const;
627 void enableDepthClamp(
bool b);
628 bool getDepthClamp();
629 void updateDepthClamp();
631 void setDepthRange(
double nr,
double fr);
632 void getDepthRange(
double &nr,
double &fr)
const;
635 int pushStencilState();
636 void popStencilState(
int *nest =
nullptr);
638 void setStencil(
bool enable);
639 void setSClearValue(
int clearValue);
640 int getSClearValue()
const;
641 void setSWriteMask(
int writeMask);
642 int getSWriteMask()
const;
651 void updateStencilState();
652 void resetSFunction();
653 void resetSWriteMask();
654 void resetSClearValue();
655 void resetSOperation();
658 void enableLogicOp();
659 void disableLogicOp();
665 int pushBlendState();
666 void popBlendState(
int *nesting = 0);
668 bool isBlending()
const;
669 void blend(
int onoff);
684 void blendAlpha(
int onoff = 1);
685 void blendAlphaPremult(
bool onoff =
true);
687 int pushSmoothLines();
688 void popSmoothLines(
int *nesting = 0);
691 void smoothBlendLinesNoFlagChange(
bool by_smooth);
694 int getBlendSmoothLevel()
const;
696 static void allowSmoothLines(
int yn);
697 static int allowsSmoothLines();
710 RE_Shader *override_mat_shader =
nullptr,
711 bool allow_partial_render =
false);
715 RE_Shader *override_mat_shader =
nullptr,
716 bool allow_partial_render =
false);
718 void popMaterial(
int *nest =
nullptr);
734 void popShader(
int *nest =
nullptr);
738 int pushShaderTransformFeedback(
RE_Shader *sh,
741 int stream_bitfield = 0x1);
745 int stream_bitfield = 0x1);
746 void popShaderTransformFeedback(
int *nest =
nullptr);
752 void setShaderOnlyMode(
bool enable);
753 void requestFixedFunction();
765 void setPatchVertices(
int num_verts);
774 bool setShaderSampleRate(
fpreal rate);
775 fpreal getShaderSampleRate()
const;
777 bool isSampleShading()
const;
805 { popUniform(bindex); }
811 void printBuiltInUniforms(
bool bound_only);
825 {
return myBuiltInUniformSerial; }
841 bool inverse_too =
false);
842 void popObjectMatrix();
847 void setFragmentDerivativeHint(
bool nicest);
848 bool getFragmentDerivativeHint();
855 void setConstAttribF32(
int loc,
int vsize,
const fpreal32 *
data);
858 void setConstAttribF32(
int loc,
int vsize,
const fpreal64 *
data);
861 void setConstAttribF64(
int loc,
int vsize,
const fpreal64 *
data);
864 void setConstAttribI32(
int loc,
int vsize,
const int32 *
data);
867 void setConstAttribU32(
int loc,
int vsize,
const uint32 *
data);
870 void dirtyConstAttribs();
907 int bindTextureRaw(
int id,
int unit);
918 void setActiveTexture(
int textureunit);
919 int getActiveTexture()
const;
927 void popTextureState(
int *nest =
nullptr);
936 int findFirstFreeTextureUnit(
int starting_unit = 0)
const;
939 void updateTextureState()
const;
943 {
return myMaxTextureShaderUnits; }
945 {
return myMaxTextureVertexUnits; }
947 {
return myMaxTextureGeometryUnits; }
949 {
return myMaxTextureFragmentUnits; }
951 {
return myMaxTextureAnisotropy; }
956 {
return myMaxTextureSize; }
958 {
return myMaxTexture3DSize; }
960 {
return myMaxTextureRectSize; }
964 {
return myMaxColorBuffers; }
967 {
return myMaxDrawBuffers; }
970 void disableAllTextures();
974 bool bindImageTexture(
int image_unit,
979 void unbindImageTexture(
int image_unit);
985 int pushReadAlignment(
const void *
data,
int scansize);
986 void popReadAlignment(
int *nest =
nullptr);
987 int getReadAlignment()
const;
989 int pushWriteAlignment(
const void *
data,
int scansize);
990 void popWriteAlignment(
int *nest =
nullptr);
991 int getWriteAlignment()
const;
994 void useSeamlessMaps(
bool enable);
995 bool usingSeamlessMaps();
1006 int num_layers,
int size = 64 );
1012 RE_OGLTexture *getRandomSampleMaskTexture(
unsigned int seed,
int nsamples,
1019 int convert16bit = 0,
1020 bool isinteger =
false);
1021 #ifdef KARMA_OUTPUT_GPU_BUFFERS
1024 void convertLUTToTexture(
PXL_Lookup *lookup);
1029 bool is3DLUTSupported()
const;
1031 void buildRasterTextureGeometry(
1038 void displayRasterTexture(
float x,
float y,
float z,
1041 void displayRasterTexture(
float x,
float y,
float z,
1045 void displayRasterTexture(
float x,
float y,
float z,
1051 float alpha_mult=1.0
f);
1057 void saveRaster(
int x,
int y,
int w,
int h,
1061 bool use_backbuf =
true);
1070 void setViewportFontOffset(
int x,
int y);
1071 int getViewportFontOffsetX()
const;
1072 int getViewportFontOffsetY()
const;
1095 bool region_support);
1096 void endConditionalRender();
1100 void enablePrimitiveRestart(
bool enable);
1101 void setPrimitiveRestartIndex(
unsigned int index);
1105 void drawViewportPoint(
const fpreal32 p[3],
1110 void drawViewportString(
const fpreal32 p[3],
1116 void postDrawViewportString();
1119 static void destroyShaderObject(
unsigned int progid,
bool unreg,
1121 static void destroyTextureObject(
unsigned int texid,
RE_OGLTexture *tex);
1122 static void destroyRenderbufferObject(
unsigned int rb);
1123 static void destroyBufferObject(
unsigned int buf);
1124 static void destroySync(
void *sync);
1126 static void clearCachedUniformBuffer(
int id);
1129 void destroyVertexArrayObject(
unsigned int vao);
1130 void destroyQuery(
unsigned int query);
1131 void destroyFramebufferObject(
unsigned int fbo);
1134 void fetchDriverPlatformInfo(
UT_WorkBuffer &info,
bool for_gl);
1138 void unbindPipeline();
1143 void invalidateCachedState();
1154 void enableSubBufferDrawing(
bool enable);
1161 static RE_SOperation oglToREsoperation(
int oglSOperation );
1166 #define RE_FLAG_STATE(RE_NAME,GL_FLAG) \
1167 void enable##RE_NAME () { REcheckIsOpenGLPainting(); if( myState.my##RE_NAME##State != 1 ) { ::glEnable( GL_FLAG ); myState.my##RE_NAME##State = 1; } } \
1168 void disable##RE_NAME () { REcheckIsOpenGLPainting(); if( myState.my##RE_NAME##State != 0 ) { ::glDisable( GL_FLAG ); myState.my##RE_NAME##State = 0; } } \
1169 bool get##RE_NAME () { if(myState.my##RE_NAME##State == 3) update##RE_NAME(); return (myState.my##RE_NAME##State ==1); } \
1170 void update##RE_NAME () { myState.my##RE_NAME##State = ::glIsEnabled( GL_FLAG ); } \
1171 void invalidate##RE_NAME() { myState.my##RE_NAME##State = 3; }
1181 RE_OGLRender(
int do_foreground,
const char *appname = 0);
1185 #undef RE_FLAG_STATE
1187 #define RE_FLAG_11_STATE(RE_NAME,GL_FLAG) \
1188 void enable##RE_NAME () { if( (myState.my##RE_NAME##State) != 1 && hasGL11() ) {::glEnable( GLenum(GL_FLAG) ); myState.my##RE_NAME##State = 1; } } \
1189 void disable##RE_NAME () { if( myState.my##RE_NAME##State && hasGL11() ) { ::glDisable( GLenum(GL_FLAG) ); myState.my##RE_NAME##State = 0; } } \
1190 bool get##RE_NAME () { if(myState.my##RE_NAME##State == 3) update##RE_NAME(); return (myState.my##RE_NAME##State==1) ; } \
1191 void update##RE_NAME () { if( hasGL11() ) { myState.my##RE_NAME##State = ::glIsEnabled( GLenum(GL_FLAG) ); } else { myState.my##RE_NAME##State = 0; } } \
1192 void invalidate##RE_NAME() { if(hasGL11()) myState.my##RE_NAME##State=3; }
1197 #undef RE_FLAG_11_STATE
1199 void updateOffsetAmount();
1201 static bool initGLVersionInfo();
1202 virtual void initGLExtensions();
1203 virtual void updateGLState();
1204 virtual void updateStacks();
1207 static void determineTwinView();
1208 bool switchContextForRender(
bool ignore_errors);
1214 void updateBlendSmoothState();
1215 int privPushBlendSmoothState(
bool smooth_too);
1216 void privPopBlendSmoothState(
bool smooth_too,
int *idx);
1218 void setupDebugging();
1220 void freePendingObjects();
1227 void assignPushedUniforms();
1233 void updateViewport();
1235 static const char *bufferName(
GLint e);
1236 static const char *faceName(
GLint e);
1237 static const char *hintName(
GLint e);
1238 static const char *cullName(
GLint e);
1400 void suspendTestPatternRender();
1401 bool suspendTestPatternCheck();
1424 void lockContextInternal_(
bool set_current_context);
1425 void unlockContextInternal_(
bool clear_current_context);
1428 void convertToViewportLogicalSpace_(
UT_DimRect &
r);
1439 if(!myR->isContextLocked())
1441 myR->lockContextForRender();
1442 myLockedFlag =
true;
1450 myR->unlockContextAfterRender();
1466 ((majorGLVersion >= 1) &&
1467 (minorGLVersion >= 1))); };
1470 ((majorGLVersion >= 1) &&
1471 (minorGLVersion >= 2))); };
1474 ((majorGLVersion >= 1) &&
1475 (minorGLVersion >= 3))); };
1478 ((majorGLVersion >= 1) &&
1479 (minorGLVersion >= 4))); };
1482 ((majorGLVersion >= 1) &&
1483 (minorGLVersion >= 5))); };
1486 ((majorGLVersion >= 2) &&
1487 (minorGLVersion >= 0))); };
1490 ((majorGLVersion >= 2) &&
1491 (minorGLVersion >= 1))); };
1495 ((majorGLVersion == 3) &&
1496 (minorGLVersion >= minor))); };
1500 ((majorGLVersion == 4) &&
1501 (minorGLVersion >= minor))); };
1514 return !(theDriverMajor == 0
1515 && theDriverMinor == 0
1516 && theDriverBuildMajor == 0
1517 && theDriverBuildMinor == 0);
1528 return myExt->hasExtension( e );
1535 return SYSrint(theDotsPerInch * uiScale());
1540 if(theUIScale <= 0.0)
1549 return (
float)n / dpi();
1555 return (
int)
SYSrint(i*(
float)dpi());
1567 if (scaled_size < 1.0)
1570 return (
int)scaled_size;
1585 fpreal ui_scale = uiScale();
1586 if (ui_scale == 1.0)
1611 {
return myFrontBufferDirty;}
1615 { myFrontBufferDirty = d; }
1633 enablePointOffset();
1635 disablePointOffset();
1644 disableLineOffset();
1653 disableFillOffset();
1659 *variable = myState._offset_variable;
1660 *constant = myState._offset_constant;
1666 return myState.myBlendSmoothStack[myState.myBlendSmoothLevel].myBlend==1;
1671 return myState.myBlendSmoothLevel;
1679 {
return myViewportFontOffsetX; }
1683 {
return myViewportFontOffsetY; }
1689 return myTransformFeedbackEnabled;
1695 return myTransformFeedbackType;
1701 return myRasterizeEnabled;
1707 return myBuiltInUniforms[builtin_var_type];
1713 return myDebugLabelSupported;
1719 return myDebuggingSupported;
void rasterize(const PointDataTreeOrGridT &points, TransferT &transfer)
Perform potentially complex rasterization from a user defined transfer scheme. See below comments for...
int getMaxDrawBuffers() const
UT_IntArray myPendingDeleteFBOs
RE_OGLExt * getExt() const
static int scaledSize(int size)
static int getDriverMajorVersion()
GLenum GLuint GLenum GLsizei const GLchar * buf
RE_PrimType getFeedbackMode() const
bool isRasterizeEnabled() const
int myDebugGroupStackSize
RV_API RV_VKImagePtr getRandomTextureArray(RV_Render *r, unsigned int seed, bool interp, int num_layers, int size=64)
Returns an 8b RGBA size^2 2D texture array of size 'num_layers'.
bool isInitialized() const
UT_Vector2F myLineWidthRange
bool myIsGLStateInitialized
bool isFrontBufferDirty() const
void setPointSize(fpreal32 size)
OGLDrawable myPushedDrawable
static int inchesToPixels(float i)
bool isGLStateInitialized() const
#define RE_FLAG_11_STATE(RE_NAME, GL_FLAG)
int myFragmentDerivativeHint
==========================================================================
int getMaxTexture3DSize() const
static RE_GraphicsDevice theDevice
static int theDriverBuildMinor
GLsizei const GLfloat * value
RE_OGLFramebuffer * mySuspendTestFBO
RE_PrimType myTransformFeedbackType
GLdouble GLdouble GLdouble z
#define GL_POLYGON_OFFSET_POINT
bool myDebugLabelSupported
int64 myBuiltInUniformSerial
RE_WindowDrawable * myWindowDrawable
A collection of vertex arrays defining a geometry object. This class acts as a wrapper around multipl...
RE_WindowDrawable * myPushedWindowDrawable
static UT_Array< std::pair< RE_Visual *, RE_DisplayMode > > theVisuals
GLenum GLenum GLsizei void * image
static int allowsSmoothLines()
UT_IntArray myPendingDeleteQueries
void pointOffset(bool onoff)
GLdouble GLdouble GLdouble q
UT_IntArray myClipDistance
bool subBufferDrawingEnabled() const
int myMaxTextureAnisotropy
UT_RecursiveSpinLock myOpenGLLock
======================================================================
GLenum GLenum GLenum dppass
int getViewportFontOffsetX() const
static int glMinorVersion()
static RE_GraphicsDevice getGraphicsDevice()
#define GL_POLYGON_OFFSET_FILL
void lineOffset(bool onoff)
static int minorGLVersion
GLenum GLuint GLint GLint layer
std::unique_ptr< T, Deleter > UT_UniquePtr
A smart pointer for unique ownership of dynamically allocated objects.
static RE_WindowList * theWindowList
bool isCurrent() const
======================================================================
vint4 blend(const vint4 &a, const vint4 &b, const vbool4 &mask)
int myMaxDebugGroupStackSize
RE_OGLTexture * mySuspendTestTexture
void getOffsetAmount(float *variable, float *constant) const
GA_API const UT_StringHolder scale
UT_IntArray myPendingDeleteVertexArrays
int getMaxColorBuffers() const
int getOGLMaxClipPlanes()
RE_Window * currentWindow
GLint GLint GLsizei GLint GLenum GLenum type
RE_Uniform * getUniform(RE_UniformBuiltIn builtin_var_type) const
bool myDebuggingSupported
static int getDriverMinorVersion()
int myMaxTextureGeometryUnits
int getBlendSmoothLevel() const
UT_IntArray & getBoundUniformBlocks()
RE_OcclusionQuery * myActiveQuery
int getMaxShaderTextureUnits() const
int getMaxVertexTextureUnits() const
void bumpBuiltInUniformSerial()
static RE_Window * theMainContextWindow
static int theDriverMajor
RE_Geometry * mySuspendBox
unsigned int RE_TextureID
GLuint GLint GLboolean layered
UT_StopWatch * mySuspendCheckTimer
GLint GLint GLsizei GLint GLenum format
bool contextIsValid() const
GLint GLenum GLboolean GLsizei stride
bool myActiveConditionalRender
#define UT_NON_COPYABLE(CLASS)
Define deleted copy constructor and assignment operator inside a class.
static RE_Server * theServer
UT_ArrayMap< int, RE_OGLFramebuffer * > myFBOTable
int getViewportFontOffsetY() const
HUSD_API const char * raster()
static RE_Window * getMainContext()
static int getDriverBuildMinorVersion()
png_const_structrp png_const_inforp int * unit
GLfloat GLfloat GLfloat alpha
#define RE_MAX_TEXTURE_STATE_STACK
SIM_API const UT_StringHolder rotation
UT_Array< RE_FeedbackPrimitivesWrittenQuery * > myTransformFeedbackWrittenQuery
int myViewportFontOffsetY
GLuint const GLchar * name
OPENVDB_API void initialize()
Global registration of native Grid, Transform, Metadata and Point attribute types. Also initializes blosc (if enabled).
static UT_ThreadSpecificValue< RE_OGLRender * > theCurrentRender
void polygonOffset(bool onoff)
int myMaxTextureFragmentUnits
int myMaxTransformFeedbackComponents
static void allowSmoothLines(int yn)
GLboolean GLboolean GLboolean b
RE_OGLFramebuffer * mySuspendResultFBO
bool myContextInitialized
int myMaxTextureVertexUnits
#define RE_FLAG_STATE(RE_NAME, GL_FLAG)
RE_OGLTexture * mySuspendResultTexture
int getMaxTextureSize() const
RE_OGLVertexArrayList * getDefaultVAO()
bool hasGLExtension(RE_Extension e) const
int getMaxFragmentTextureUnits() const
RE_OGLContext getContext() const
static int theDotsPerInch
int myShaderOnlyModeCount
static int theDriverBuildMajor
const RE_Render * getRender() const
static int getDriverBuildMajorVersion()
static bool theSmoothLinesAllowed
GLfloat GLfloat GLfloat GLfloat h
RE_RenderAutoLock(RE_OGLRender *r)
static RE_WindowList * getWindowList()
void pushPointSize(fpreal32 size)
Point options that can change per-point.
bool isTransformFeedbackEnabled() const
SIM_API const UT_StringHolder force
UT_Array< RE_Uniform * > myPushedUniforms
int64 getBuiltInUniformSerial() const
bool myIsAllowingOtherThreads
static int theDriverMinor
const RE_Window * getCurrentWindow() const
static bool hasGL4(int minor)
bool isDebugLabelSupported() const
int myMaxTextureShaderUnits
RE_OGLContext myContext
======================================================================
fpreal myShaderSampleRate
int getTextureAnisotropyLimit() const
ut_thread_id_t myNativeThread
int myMaxTransformFeedbackBuffers
static float pixelsToInches(int n)
static bool hasDriverVersion()
fpreal32 SYSrint(const fpreal32 val)
RV_API RV_VKImagePtr getRandomTexture(RV_Render *r, unsigned int seed, bool interp, int size=64)
Returns an 8b RGBA 64x64 texture with 0-1 random values in all comps.
int64 getRenderCount() const
GLubyte GLubyte GLubyte GLubyte w
bool myTransformFeedbackEnabled
int getMaxVertexAttribs() const
static bool theUsingCoreProfile
RE_Window * mySavedMainThreadCurrentWindow
static bool hasGL3(int minor)
RE_OGLVertexArrayList * myCurrentVAO
int getMaxGeometryTextureUnits() const
void popUniformData(RE_UniformBuiltIn bindex)
void setDefaultVAO(RE_OGLVertexArrayList *vao)
static UT_ThreadSpecificValue< RE_OGLRender * > theLastRender
int getMaxTextureRectangleSize()
RE_WindowDrawable * getDrawable()
QOpenGLContext * RE_OGLContext
void setFrontBufferDirty(bool d)
UT_Array< RE_PrimitivesGeneratedQuery * > myTransformFeedbackPrimitiveQuery
UT_Array< re_ConstVertexAttrib > myConstVertexAttribs
RE_Shader * myShaderOnlyActiveShader
png_structrp int png_fixed_point red
RV_API RV_VKImagePtr getRandomTexture3D(RV_Render *r, unsigned int seed, bool interp, int size=32)
Returns an 8b RGBA size^3 3D texture with 0-1 random values.
#define RE_BUFFER_STACK_SIZE
RE_OGLVertexArrayList * myDefaultVAO
RE_OGLContext pushedGraphicsContext
bool myMultisampleAlphaToCoverage
int myOpenGLContextLockCount
static int majorGLVersion
#define GL_POLYGON_OFFSET_LINE
GA_API const UT_StringHolder area
static RE_OGLRender * getCurrentRender()
Simple interface to building a shader from a .prog file.
static int glMajorVersion()