2021-12-18 02:02:16 +01:00
|
|
|
Class {
|
|
|
|
#name : #DiyaBaseObject,
|
|
|
|
#superclass : #Object,
|
|
|
|
#category : #'Diya-Core'
|
|
|
|
}
|
2021-12-19 22:41:21 +01:00
|
|
|
|
2022-03-04 20:28:38 +01:00
|
|
|
{ #category : #accessing }
|
|
|
|
DiyaBaseObject >> checkGLError: mark [
|
|
|
|
|err|
|
|
|
|
err := OpenGL getError.
|
|
|
|
err = 0 ifFalse:[
|
|
|
|
self stderror:mark, ': return error code ', err hex.
|
|
|
|
].
|
|
|
|
]
|
|
|
|
|
|
|
|
{ #category : #accessing }
|
|
|
|
DiyaBaseObject >> logError: string [
|
|
|
|
self stderr nextPutAll: string; cr
|
|
|
|
]
|
|
|
|
|
2021-12-19 22:41:21 +01:00
|
|
|
{ #category : #accessing }
|
|
|
|
DiyaBaseObject >> stderr [
|
2022-03-04 20:28:38 +01:00
|
|
|
^VTermOutputDriver stderr
|
|
|
|
]
|
|
|
|
|
|
|
|
{ #category : #accessing }
|
|
|
|
DiyaBaseObject >> stderror: string [
|
|
|
|
self stderr nextPutAll: string; nextPutAll: Character cr asString.
|
|
|
|
]
|
|
|
|
|
|
|
|
{ #category : #accessing }
|
|
|
|
DiyaBaseObject >> stdlog: string [
|
|
|
|
self stdout nextPutAll: string;
|
|
|
|
nextPutAll: Character cr asString.
|
2021-12-19 22:41:21 +01:00
|
|
|
]
|
|
|
|
|
|
|
|
{ #category : #accessing }
|
|
|
|
DiyaBaseObject >> stdout [
|
|
|
|
^ VTermOutputDriver stdout
|
|
|
|
]
|