MAB Posted October 24, 2015 Share Posted October 24, 2015 i am drawing this image and this image but there are 2 strange white things at its start and its end i drew 2 more couple of images like this but it don't have white things they have the same size dxDrawImageSection(x*890,y*67,50,(health/2)*-1,0,0,50,(health/2)*-1,"hi.png") dxDrawImage(x*890, y*17, 50, 50, "ho.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) Link to comment
Moderators IIYAMA Posted October 25, 2015 Moderators Share Posted October 25, 2015 When you change your image to 1 color and export(web) it as png-8. You won't have that problem any more. png-24 is kinda tricky to draw with a lot alpha blending. But check your photoshop export settings correctly! The png-8 settings from photoshop are not correct by default! Also you might want to try dxCreateTexture first. - Speeds up the render speed. - Can be compressed with dxt1,dxt3,dxt5. For using less GPU(video card) memory. I recommend dxt5. - Two ways to render the edges: wrap and clamp Difference between png-8 (left) and png-24 (right): Link to comment
MAB Posted October 26, 2015 Author Share Posted October 26, 2015 When you change your image to 1 color and export(web) it as png-8.You won't have that problem any more. png-24 is kinda tricky to draw with a lot alpha blending. But check your photoshop export settings correctly! The png-8 settings from photoshop are not correct by default! Also you might want to try dxCreateTexture first. - Speeds up the render speed. - Can be compressed with dxt1,dxt3,dxt5. For using less GPU(video card) memory. I recommend dxt5. - Two ways to render the edges: wrap and clamp Difference between png-8 (left) and png-24 (right): I still don't undeerstand how to use createTexture or how to slove my problem Link to comment
Moderators IIYAMA Posted October 26, 2015 Moderators Share Posted October 26, 2015 There are is an example on the wiki how to use textures. Link to comment
MAB Posted October 26, 2015 Author Share Posted October 26, 2015 There are is an example on the wiki how to use textures. The problem was with the position... totally strange... i replaced the 6 images with other 6 images.. and guess what? the same white things for the one that replaces the old 2 images that got that position ... i moved them 10 X and the white things gone Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now