another skybox thread :s


(aaa3) #1

HELLO

hmm… im having a self contained box, textured with my custom sky shader, and inside there is a skyportal entity. and i have a huge box room - the 2 stuff is far away from each other; far away enough - , with some of the walls caulked (to see the sky). when the sky shader was incorrect i had hom effects but now i cant find any more errors in it on my own; and i dont have hom neither, but orange grid. texture is 256x256 jpg. (dont accept tga i can only save in indexed not in rgb :frowning: ).
it is showing up in rad correctly. also showing up ingame correctly the same jpg if used as a texture and not as a skybox stuff.

the shader: (the 2 stuff at the bottom are just copy pasted, dont really understand it but it was told that they are making clouds. anyway i guess the problem is not wtih those)

textures/danube_a1/skybox
{
	skyparms textures/danube_a1/skybox/skybox_env/sky 256 -
	q3map_sunExt 1 1 1 50 -35 25 3 32 //red green blue intensity degrees elevation
	q3map_skylight 50 2

        nocompress
        surfaceparm sky
	surfaceparm noimpact
	surfaceparm nolightmap
	surfaceparm nodlight
	surfaceparm nomarks
	
  qer_editorimage textures/danube_a1/skybox/sky.jpg
  
 {
  map textures/skies/dimclouds.tga

  tcMod turb 0 0.001 0.5 0.001
  tcMod scale 3 3
  tcMod scroll 0.01 0.01
  blendFunc GL_ONE GL_ONE_MINUS_SRC_COLOR
  depthWrite
 }
 
 {
	map textures/skies/pjbasesky.tga
	blendfunc GL_ONE GL_ONE
	tcMod scroll -0.01 -0.01
	tcMod scale 5 5
 }
 
}

the paths: et mapping/etmain/textures/danube_a1/skybox/skybox_env/sky_up.jpg, sky_dn.jpg, et c.; the editorimage is one level upper (not in s._env dir but in s.).

compiling with q3map2build, -et; -meta -v; -fast -v, -fast -v (bsp vis light)

oh and everything else is ok, i mean at the non caulked walls i see the shadow cast by the “sun”, the map is lit as it should, i just cant see my sky but orange stuff. for comparison, when my shader was wrong (possibly it is still but not to that extent) then i had hom effects at the caulked walls, and complete darkness except in the light entites’ radii


(aaa3) #2

( btw i have another nooby question, to rayban. im having an old map made by you, foliage example. i have found no where sky boxes in it (radiant, *.map), and no sky related stuff at the shaders/scripts (pk3), and the outer hull was simply caulk(rad, *.map). still, when i compiled it to bsp myself (only for testing reasons done it), it shows up correctly the goldrush sky, as in the original. how did u done your sky?)
EDIT: i made a huge mistake. selected the hull brush and pressed s - obviously showed caulk, when selecting the inner surface only it was sd_goldrush, ofc. forget this :stuck_out_tongue: :s)

ah, and in the goldrush example map, i ve found again another style of making sky, it was simply put on the inner side of brushes at ceiling (btw never tried to compile that huge map). im confused. are there many different ways of making sky not only the “skybox” (separate self conained small box far away and with a entity inside)? and anyway, whats wrong with mine? :S


(aaa3) #3

today played at least 2 hours with mrlego’s skybox example map found at a some 3 yo thread. i ve found some things.
with props_skyportal i can use caulk hull but with _skybox i must use at least 1 surface of sd_goldrush at the map hull, else i get hom effect (answer to one of my questions).

also with _skybox if i place a brush in the actual skybox it will be present at the map. it was a huge solid block at my example. but if i use props_skyportal it is simply cast on the skybox image, unreachable (just found).

and if i used with my skyshader at 6 walls with the original skyshader at 2 walls, my was shon as orange grid while frozen (name of original) was shown up normally. this suggests that im having a path or naming error? (possible answer to my main question)
but i still cant fix it. now my paths and files are: textures/danube_a1/skybox/sky.jpg, sky_bk.jpg, sky_dn.jpg, et c.(ft lf rt up); and the shader is

textures/danube_a1/skybox
{
  qer_editorimage textures/danube_a1/skybox/sky.jpg
  nocompress
  surfaceparm noimpact
	surfaceparm nolightmap
	surfaceparm nodlight
	surfaceparm nomarks
	surfaceparm sky
	
	skyparms textures/danube_a1/skybox/sky 256 -
	q3map_sunExt 1 1 1 50 -35 25 3 32 //red green blue intensity degrees elevation
	q3map_skylight 50 2

  {... (same from here)

help plz? :frowning:

edit - i found an answer to my another question, edited the second post accordingly. still dont works my skybox-texture-shader though :S but now i have a guess that its only working with tga and not with jpg? but im having troubles saving in the proper tga variation. i will examine and try it tomorrow again.


(MrLego) #4

Try compiling with a full vis not vis -fast.

Even with my sample map I would get the HOM effect sometimes unless I performed a full vis.


(aaa3) #5

already found this some days ago in many older threads, and since then im always doing full vis. btw thx, ur the 1st one trying to help me
(fyi - im not getting hom but orange grid. hom was an earlier problem i managed to solve alone, just mentioned it. occured later again then solved second time too, then with the help of other topics. orange grid is btw a problem i cant solve no matter how im trying.)


(aaa3) #6

found it while experienting more - those freaking “clouds” were the culprits. (it was told at some tutorial that those lines are adding nice moving clouds to the sky.)


(MrLego) #7

The orange grid means that the texture is missing, check all of your file paths.

Moving clouds can also impact FPS so be careful on how you use it.

Try removing the cloud portion of your sky shader and concentrate on getting the skybox painted on all six sides of the cube and in your map.

A basic skybox shader is pretty simple to troubleshoot - look at the sample map.

Make sure that you have a working sky shader in your map also, if you are painting your skies with a texture rather than a sky shader, the props_skyportal textures will never be projected onto your maps sky.


(aaa3) #8

as i said i already fixed the problem (cant change topic title in new engine :S), and no wonder i didnt found any error in my paths no matter how much i searched - because it was correct. i already knew that orange grid means something path or naming problem thats why i put most of my efforts into this way. but as i said, the problem was with the additional “copypasted without understanding” 2 blocks from some tut, which was supposed to add clouds, but instead blocked my sky. i removed them and voila - it was working. since then i was playing a lot with my - now working - sky, searching for the best realization of my intended look, later i added working clouds on my own, and changed many things, based on stock et shaders examination, and anyway now i mastered the usage of both skyshaders and skyboxes&skyportal-boxes in the last week, and in general i understand and can use better the shaders :stuck_out_tongue:

here is my present sky, its simply a skyshader now, with remnants of a skybox. it was a skybox but textures were ugly streched and couldnt add scale, so moved to skyshader where i could use the scale. but with low skyparm value the sky was ugly and clouds were nice, and high skyparms value the sky was beautiful exactly what i need, but clouds were lol, so now i have a nice sky without any clouds. later i will try to do again a skybox for the sky (but trying to scale the image somehow else not via the shader command); with a skyshader for only the clouds.

textures/danube_a1/skybox
{
  qer_editorimage textures/danube_a1/skybox/sky.tga
  nocompress
  surfaceparm noimpact
	surfaceparm nolightmap
	surfaceparm nodlight
	surfaceparm nomarks
	surfaceparm sky
	
	sunshader textures/skies_sd/full_moon2
	skyparms textures/danube_a1/skybox/sky 4096 -
	q3map_sunExt 1 1 1 50 20 20 3 32 //r g b intens degr elev deviance sampl
	q3map_skylight 30 1
	
	{	fog off
		map textures/danube_a1/skybox/sky.tga
		tcMod scale 5 5
		rgbGen const ( 0.5 0.5 0.5 )
	}
	
  //{	fog off
		//map textures/skies_sd/wurzburg_clouds.tga
		//blendfunc add
		//tcMod scale 2 2
		//tcMod scroll 0.090 0.002
		//rgbGen const ( 0.6 0.6 0.6 )
	//}
}