ios - Fragment Shader GLSL for texture, color and texture/color - i want accomplish glsl shader, can texture , color vertex objects. in fact, works me in 2 3 cases: 1) if have texture assigned (but no specific color - color "white"), textured object - works 2) if have texture , color assigned, textured object modulated color - works 3) if have color assigned no texture, black object - doesn't work my shader looks this: varying lowp vec4 colorvarying; varying mediump vec2 texcoordvarying; uniform sampler2d texture; void main(){ gl_fragcolor = texture2d(texture, texcoordvarying) * colorvarying; } i guess that, texture2d(...,...) returns 0 if no texture assigned - seems problem. there way in glsl can check, if no texture assigned (in case, want gl_fragcolor = colorvarying;) "if" isn't alternative in glsl shader, if understanded correctly - ideas accomplish this? or necessary create 2 different shaders both cases? like i'd ...
iphone - Dismissing a UIAlertView - i set in app purchase app, , when user taps button, purchase started. basically, tap button, , depending on speed on net connection, waiting 10 seconds until new alert view comes asking if purchase product. user tap button multiple times since nil came up, , multiple purchase alert views come up. additionally, maybe seen user app bug. in end, problem. i want alert view come spinning wheel says "loading..." when users taps purchase button. problem is, how dismiss when new alert view comes asking user if want purchase product? if ([uialertview alloc] says: @"whatever apple's alert view says") { //dismiss "loading..." alert view here } i uncertainty work, input appreciated. thanks! you need have access alertview. can this. create alertview instance var in app delegate , when want show loading initialize instance var assign property , when want dismiss phone call [alertviewinstance d...
java - Does anyone know the name of this "LookAndFeel"? - does know name of "lookandfeel"? or @ to the lowest degree know similar one? it's amazing , wish utilize program. http://www.axbo.com/webstart/axbo.jnlp it called syntheticawhitevision . http://www.jyloo.com/synthetica/themes/ (it 5th on page) how found this: download , save jnlp . jnlp plain text file. open , see somewhere in file this: <resources> <jar href="axbo.jar" main="true"/> <jar href="lib/absolutelayout.jar"/> <jar href="lib/rxtxcomm.jar"/> <jar href="lib/commons-beanutils.jar"/> <jar href="lib/commons-logging-1.1.jar"/> <jar href="lib/commons-digester-1.8.jar"/> <jar href="lib/infactory-utils.jar"/> <jar href="lib/jcommon-1.0.9.jar"/> <jar href="lib/jfreechart-1.0.5.jar"/> ...
Comments
Post a Comment